aboutsummaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure15
1 files changed, 15 insertions, 0 deletions
diff --git a/configure b/configure
index 8089d1a2..4c08b034 100755
--- a/configure
+++ b/configure
@@ -51,6 +51,8 @@ skype=0
events=glib
ssl=auto
+pam=0
+
pie=1
arch=$(uname -s)
@@ -133,6 +135,8 @@ Option Description Default
--purple=0/1 Disable/enable libpurple support $purple
(automatically disables other protocol modules)
+--pam=0/1 Disable/enable PAM authentication $pam
+
--doc=0/1 Disable/enable help.txt generation $doc
--debug=0/1 Disable/enable debugging $debug
--strip=0/1 Disable/enable binary stripping $strip
@@ -630,6 +634,17 @@ echo "STORAGE_OBJS="$STORAGE_OBJS >> Makefile.settings
authobjs=
authlibs=
+if [ "$pam" = 0 ]; then
+ echo '#undef WITH_PAM' >> config.h
+else
+ if ! echo '#include <security/pam_appl.h>' | $CC -E - >/dev/null 2>/dev/null; then
+ echo 'Cannot find libpam development libraries, aborting. (Install libpam0g-dev?)'
+ exit 1
+ fi
+ echo '#define WITH_PAM' >> config.h
+ authobjs=$authobjs'auth_pam.o '
+ authlibs=$authlibs'-lpam '
+fi
echo AUTH_OBJS=$authobjs >> Makefile.settings
echo EFLAGS+=$authlibs >> Makefile.settings