diff mbox series

libpam: add packageconfig for selinux

Message ID 20241208145602.633452-1-yi.zhao@windriver.com
State Accepted, archived
Commit 15d0cb7c4b1278e869f440f949f5e9af2d305429
Headers show
Series libpam: add packageconfig for selinux | expand

Commit Message

Yi Zhao Dec. 8, 2024, 2:56 p.m. UTC
Add PACKAGECONFIG[selinux] to support build with selinux.

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
---
 meta/recipes-extended/pam/libpam_1.7.0.bb | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/meta/recipes-extended/pam/libpam_1.7.0.bb b/meta/recipes-extended/pam/libpam_1.7.0.bb
index ec1c868d21..53839e8cd3 100644
--- a/meta/recipes-extended/pam/libpam_1.7.0.bb
+++ b/meta/recipes-extended/pam/libpam_1.7.0.bb
@@ -38,6 +38,7 @@  inherit meson gettext pkgconfig systemd ptest github-releases
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[audit] = "-Daudit=enabled,-Daudit=disabled,audit,"
 PACKAGECONFIG[userdb] = "-Dpam_userdb=enabled -Ddb=gdbm,-Dpam_userdb=disabled,gdbm,"
+PACKAGECONFIG[selinux] = "-Dselinux=enabled,-Dselinux=disabled,libselinux,"
 
 PACKAGES += "${PN}-runtime ${PN}-xtests"
 FILES:${PN} = " \
@@ -69,6 +70,7 @@  RDEPENDS:${PN}-runtime = "${PN}-${libpam_suffix} \
     ${MLPREFIX}pam-plugin-permit-${libpam_suffix} \
     ${MLPREFIX}pam-plugin-warn-${libpam_suffix} \
     ${MLPREFIX}pam-plugin-unix-${libpam_suffix} \
+    ${@bb.utils.contains('PACKAGECONFIG', 'selinux', '${MLPREFIX}pam-plugin-selinux-${libpam_suffix}', '', d)} \
     "
 RDEPENDS:${PN}-xtests = "${PN}-${libpam_suffix} \
     ${MLPREFIX}pam-plugin-access-${libpam_suffix} \