package/polkit: support different authentication frameworks
authorAdam Duskett <Aduskett@gmail.com>
Fri, 6 Dec 2019 23:46:45 +0000 (15:46 -0800)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Sun, 8 Dec 2019 14:56:58 +0000 (15:56 +0100)
Use pam if available, otherwise use shadow.

Signed-off-by: Adam Duskett <Aduskett@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/polkit/polkit.mk

index 507d1865fa7c7a781a948b024d6a7e5ee0c4d55d..7791d23d194c95cdfcb3e3cc1cf3c139cc67b0f9 100644 (file)
@@ -13,13 +13,17 @@ POLKIT_INSTALL_STAGING = YES
 
 POLKIT_DEPENDENCIES = libglib2 host-intltool expat spidermonkey
 
-# We could also support --with-authfw=pam
 POLKIT_CONF_OPTS = \
-       --with-authfw=shadow \
        --with-os-type=unknown \
        --disable-man-pages \
        --disable-examples \
        --disable-libelogind \
        --disable-libsystemd-login
 
+ifeq ($(BR2_PACKAGE_LINUX_PAM),y)
+POLKIT_CONF_OPTS += --with-authfw=pam
+else
+POLKIT_CONF_OPTS += --with-authfw=shadow
+endif
+
 $(eval $(autotools-package))