From 1fc14a6543bfc5f087ed0ddf02bc7ce28a4d9ed4 Mon Sep 17 00:00:00 2001 From: Günther Deschner Date: Thu, 10 Feb 2011 21:10:53 +0100 Subject: s3-waf: do not make pam support mandatory. Guenther --- source3/wscript | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'source3/wscript') diff --git a/source3/wscript b/source3/wscript index cb10fd5699..ca7acf212c 100644 --- a/source3/wscript +++ b/source3/wscript @@ -942,13 +942,16 @@ return krb5_kt_resolve(context, "WRFILE:api", &keytab); conf.DEFINE('HAVE_ICONV', 1) if Options.options.with_pam: + use_pam=True conf.CHECK_HEADERS('security/pam_appl.h pam/pam_appl.h') if not conf.CONFIG_SET('HAVE_SECURITY_PAM_APPL_H') and not conf.CONFIG_SET('HAVE_PAM_PAM_APPL_H'): print "--with-pam=yes but pam_appl.h not found" - conf.CHECK_FUNCS_IN('pam_get_data', 'pam', mandatory=True) - conf.CHECK_HEADERS('security/pam_modules.h pam/pam_modules.h') - if not conf.CONFIG_SET('HAVE_SECURITY_PAM_MODULES_H') and not conf.CONFIG_SET('HAVE_PAM_PAM_MODULES_H'): + use_pam=False + conf.CHECK_FUNCS_IN('pam_get_data', 'pam') + conf.CHECK_HEADERS('security/pam_modules.h pam/pam_modules.h') + if not conf.CONFIG_SET('HAVE_SECURITY_PAM_MODULES_H') and not conf.CONFIG_SET('HAVE_PAM_PAM_MODULES_H'): print "--with-pam=yes but pam_modules.h not found" + use_pam=False conf.CHECK_HEADERS('security/pam_ext.h security/_pam_macros.h') conf.CHECK_HEADERS('pam/pam_ext.h pam/_pam_macros.h') conf.CHECK_FUNCS_IN('pam_vsyslog', 'pam') @@ -1007,8 +1010,11 @@ int i; i = PAM_RADIO_TYPE; 'HAVE_PAM_RADIO_TYPE', lib='pam', msg="Checking whether PAM_RADIO_TYPE is available"); - conf.DEFINE('WITH_PAM', 1) - conf.DEFINE('WITH_PAM_MODULES', 1) + if use_pam: + conf.DEFINE('WITH_PAM', 1) + conf.DEFINE('WITH_PAM_MODULES', 1) + else: + conf.SET_TARGET_TYPE('pam', 'EMPTY') seteuid = False if not seteuid: -- cgit