]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
cups: check PACKAGECONFIG for pam feature
authorTrevor Woerner <twoerner@gmail.com>
Wed, 8 Mar 2023 22:44:41 +0000 (17:44 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 11 Mar 2023 00:08:38 +0000 (00:08 +0000)
The cups' PACKAGECONFIG is populated based on DISTRO_FEATURES, but a user
is free to enable or disable PACKAGECONFIGs at will. In theory it is
possible that pam is enabled globally in DISTRO_FEATURES but disabled in
cups' PACKAGECONFIG. Checking the PACKAGECONFIG to determine whether or not
pam is enabled would be a safer check rather than relying on DISTRO_FEATURES.

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
meta/recipes-extended/cups/cups.inc

index b8b655a4fb85097fee147eaf0bca5d5bb636502d..1b522d7d85357288f440902bf39ac4a53cf679ef 100644 (file)
@@ -74,7 +74,7 @@ do_install () {
        rmdir ${D}/${libexecdir}/${BPN}/driver
 
        # Fix the pam configuration file permissions
-       if ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'true', 'false', d)}; then
+       if ${@bb.utils.contains('PACKAGECONFIG', 'pam', 'true', 'false', d)}; then
            chmod 0644 ${D}${sysconfdir}/pam.d/cups
        fi