summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorBjörn Jacke <bj@sernet.de>2009-10-16 23:40:34 +0200
committerBjörn Jacke <bj@sernet.de>2009-10-16 23:46:52 +0200
commit7655282ede0375a0de4102c2b8f27cf8985bd71c (patch)
treee4dad00195657dd0997cf5c05f874da01132e6d5 /source3
parent64e8aa1b145cd440776cf2c4162c842c9b258409 (diff)
downloadsamba-7655282ede0375a0de4102c2b8f27cf8985bd71c.tar.gz
samba-7655282ede0375a0de4102c2b8f27cf8985bd71c.tar.bz2
samba-7655282ede0375a0de4102c2b8f27cf8985bd71c.zip
s3: build pam_smbpass when possible
Diffstat (limited to 'source3')
-rw-r--r--source3/configure.in54
1 files changed, 34 insertions, 20 deletions
diff --git a/source3/configure.in b/source3/configure.in
index ad43624f2e..36c89efe2b 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -4271,31 +4271,45 @@ fi # try_pam != no
PAM_MODULES=""
INSTALL_PAM_MODULES=""
UNINSTALL_PAM_MODULES=""
+
+try_pam_smbpass=auto
AC_MSG_CHECKING(whether to use pam_smbpass)
AC_ARG_WITH(pam_smbpass,
-[AS_HELP_STRING([--with-pam_smbpass], [Build PAM module for authenticating against passdb backends (default=no)])],
+[AS_HELP_STRING([--with-pam_smbpass], [Build PAM module for authenticating against passdb backends (default=auto)])],
[ case "$withval" in
- yes)
- AC_MSG_RESULT(yes)
+ yes|no|auto)
+ try_pam_smbpass=$withval
+ ;;
+ *)
+ AC_MSG_ERROR([valid options are yes,no,auto])
+ ;;
+ esac
+])
- # Conditions under which pam_smbpass should not be built.
+if test x"${try_pam_smbpass}" = xno ; then
+ use_pam_smbpass=no
+else
+ use_pam_smbpass=yes
+ # Conditions under which pam_smbpass can't be built.
+ if test x"$BLDSHARED" != xtrue ; then
+ if test x"${try_pam_smbpass}" = xyes ; then
+ AC_MSG_ERROR([No support for shared modules])
+ fi
+ use_pam_smbpass=no
+ elif test x"$create_pam_modules" != xyes ; then
+ if test x"${try_pam_smbpass}" = xyes ; then
+ AC_MSG_ERROR([No support for PAM MODULES])
+ fi
+ use_pam_smbpass=no
+ fi
- if test x"$BLDSHARED" != x"true"; then
- AC_MSG_ERROR([No support for shared modules])
- elif test x"$create_pam_modules" != x"yes"; then
- AC_MSG_ERROR([No support for PAM MODULES])
- else
- PAM_MODULES="pam_smbpass"
- INSTALL_PAM_MODULES="installpammodules"
- UNINSTALL_PAM_MODULES="uninstallpammodules"
- fi
- ;;
- *)
- AC_MSG_RESULT(no)
- ;;
- esac ],
- AC_MSG_RESULT(no)
-)
+ if test x"${use_pam_smbpass}" = xyes ; then
+ PAM_MODULES="pam_smbpass"
+ INSTALL_PAM_MODULES="installpammodules"
+ UNINSTALL_PAM_MODULES="uninstallpammodules"
+ fi
+fi
+AC_MSG_RESULT([$use_pam_smbpass])
##