diff mbox series

[meta-security,kirkstone,4/5] sssd: fix shipping python script and modules

Message ID 20240626133913.790145-5-gael.portay@rtone.fr
State New
Headers show
Series sssd: fix python3 support | expand

Commit Message

Gaël PORTAY June 26, 2024, 1:39 p.m. UTC
The project installs the python script sss_obfuscate to the /usr/sbin
directory and the modules to the /usr/lib/python3.X directory.

The recipe does not ship the python modules to the package sssd, and
thus, it raises the QA issue attached below.

This adds the python artifacts (sss_obfuscate script and module files)
to the dedicated package sssd-python.

Fixes:

	NOTE: Executing Tasks
	ERROR: sssd-2.5.2-r0 do_package: QA Issue: sssd: Files/directories were installed but not shipped in any package:
	  /usr/lib/python3.10
	  /usr/lib/python3.10/site-packages
	  /usr/lib/python3.10/site-packages/SSSDConfig-2.5.2-py3.10.egg-info
	  /usr/lib/python3.10/site-packages/pysss_nss_idmap.so
	  /usr/lib/python3.10/site-packages/pyhbac.so
	  /usr/lib/python3.10/site-packages/pysss.so
	  /usr/lib/python3.10/site-packages/pysss_murmur.so
	  /usr/lib/python3.10/site-packages/SSSDConfig
	  /usr/lib/python3.10/site-packages/SSSDConfig/sssdoptions.py
	  /usr/lib/python3.10/site-packages/SSSDConfig/ipachangeconf.py
	  /usr/lib/python3.10/site-packages/SSSDConfig/__init__.py
	  /usr/lib/python3.10/site-packages/SSSDConfig/__pycache__
	  /usr/lib/python3.10/site-packages/SSSDConfig/__pycache__/ipachangeconf.cpython-310.pyc
	  /usr/lib/python3.10/site-packages/SSSDConfig/__pycache__/__init__.cpython-310.pyc
	  /usr/lib/python3.10/site-packages/SSSDConfig/__pycache__/sssdoptions.cpython-310.pyc
	Please set FILES such that these items are packaged. Alternatively if they are unneeded, avoid installing them or delete them within do_install.
	sssd: 15 installed and not shipped files. [installed-vs-shipped]
	ERROR: sssd-2.5.2-r0 do_package: Fatal QA errors were found, failing task.

Signed-off-by: Gaël PORTAY <gael.portay@rtone.fr>
---
 recipes-security/sssd/sssd_2.5.2.bb | 5 +++++
 1 file changed, 5 insertions(+)
diff mbox series

Patch

diff --git a/recipes-security/sssd/sssd_2.5.2.bb b/recipes-security/sssd/sssd_2.5.2.bb
index 9991667..4084d07 100644
--- a/recipes-security/sssd/sssd_2.5.2.bb
+++ b/recipes-security/sssd/sssd_2.5.2.bb
@@ -143,6 +143,7 @@  SYSTEMD_SERVICE:${PN} = " \
 "
 SYSTEMD_AUTO_ENABLE = "disable"
 
+PACKAGE_BEFORE_PN =+ "${PN}-python"
 PACKAGES =+ "libsss-sudo"
 ALLOW_EMPTY:libsss-sudo = "1"
 
@@ -151,6 +152,10 @@  FILES:${PN} += "${base_libdir}/security/pam_sss*.so  \
                 ${libdir}/krb5/* \
                 ${libdir}/ldb/* \
                 "
+FILES:${PN}-python = "${sbindir}/sss_obfuscate \
+                      ${PYTHON_SITEPACKAGES_DIR} \
+                      "
 FILES:libsss-sudo = "${libdir}/libsss_sudo.so"
 
 RDEPENDS:${PN} = "bind bind-utils dbus libldb libpam libsss-sudo"
+RDEPENDS:${PN}-python = "python3-core"