[gdm] pam_gdm: allow setting pam module dir at configure time



commit c6633b311f7ed8560a5c6847110d872d017672a6
Author: RĂ©mi Cardona <remi gentoo org>
Date:   Mon Nov 21 08:18:32 2016 +0100

    pam_gdm: allow setting pam module dir at configure time
    
    Code taken almost verbatim from gnome-keyring.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=774776

 configure.ac        |   11 ++++++++++-
 pam_gdm/Makefile.am |    2 +-
 2 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index fbf400e..0a1d32a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -477,7 +477,7 @@ dnl ---------------------------------------------------------------------------
 dnl - Check for PAM stuff
 dnl ---------------------------------------------------------------------------
 
-dnl PAM prefix
+dnl PAM prefix (configuration files)
 withval=""
 AC_ARG_WITH(pam-prefix,
             AS_HELP_STRING([--with-pam-prefix=<prefix>],
@@ -493,6 +493,14 @@ else
 fi
 AC_SUBST(PAM_PREFIX)
 
+dnl PAM dir (dynamic modules)
+AC_ARG_WITH([pam-mod-dir],
+            [AS_HELP_STRING([--with-pam-mod-dir=DIR],
+                            [directory to install pam modules in])],
+            [], [with_pam_mod_dir='${libdir}/security'])
+PAM_MOD_DIR="$with_pam_mod_dir"
+AC_SUBST(PAM_MOD_DIR)
+
 have_pam=no
 AC_CHECK_LIB(pam, pam_start, have_pam=yes)
 
@@ -1582,6 +1590,7 @@ echo "
 
         dbus-1 system.d dir:      ${DBUS_SYS_DIR}
         PAM prefix:               ${PAM_PREFIX}
+        PAM module dir:           ${PAM_MOD_DIR}
         PAM config:               ${with_default_pam_config}
         X server:                 ${X_SERVER}
 "
diff --git a/pam_gdm/Makefile.am b/pam_gdm/Makefile.am
index 61d672b..6b92cfc 100644
--- a/pam_gdm/Makefile.am
+++ b/pam_gdm/Makefile.am
@@ -36,4 +36,4 @@ pam_gdm_LTLIBRARIES = \
        pam_gdm.la \
        $(END_OF_LIST)
 
-pam_gdmdir = $(libdir)/security
+pam_gdmdir = $(PAM_MOD_DIR)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]