test a static build of smbtorture and smbd

Stefan Metzmacher metze at samba.org
Mon Aug 24 12:05:31 UTC 2015


Hi Herb,

does the following (completely untested) patch help?

metze

Am 17.08.2015 um 23:57 schrieb Herb Lewis:
> Thanks for this fix. I built smbtorture static and am now trying to get rid
> of things I don't need. For instance I tried to configure with
> --without-pam
> and --without-pam_smbpass but smbtorture still shows libpam.so.0 in
> the ldd output. Why is that?
> 
> On 08/17/2015 01:57 PM, Stefan Metzmacher wrote:
>> Hi,
>>
>> while
>> https://git.samba.org/?p=samba.git;a=commitdiff;h=e8c602dfa2f08a9ea43c84a7e7ae9fe17e007d60
>>
>> fixed the build using --nonshared-binary=smbtorture
>>
>> Here're a patchset to test this in autobuild.
>>
>> At the same time I improved our --with-{static,shared}-modules handling.
>>
>> Please review and push.
>>
>> Thanks!
>> metze
>>
> 
> 
-------------- next part --------------
From d1736ea77ce603eba86adbfaa8677c22d5e2034e Mon Sep 17 00:00:00 2001
From: Stefan Metzmacher <metze at samba.org>
Date: Mon, 24 Aug 2015 14:04:00 +0200
Subject: [PATCH] TODO: don't use pam when using --without-pam...

---
 source4/auth/ntlm/auth_unix.c   | 2 +-
 source4/auth/ntlm/wscript_build | 1 +
 source4/auth/wscript_configure  | 4 ----
 wscript                         | 1 -
 4 files changed, 2 insertions(+), 6 deletions(-)
 delete mode 100644 source4/auth/wscript_configure

diff --git a/source4/auth/ntlm/auth_unix.c b/source4/auth/ntlm/auth_unix.c
index 526b655..c8e5829 100644
--- a/source4/auth/ntlm/auth_unix.c
+++ b/source4/auth/ntlm/auth_unix.c
@@ -144,7 +144,7 @@ static NTSTATUS talloc_getpwnam(TALLOC_CTX *ctx, const char *username, struct pa
 }
 
 
-#ifdef HAVE_SECURITY_PAM_APPL_H
+#ifdef WITH_PAM
 #include <security/pam_appl.h>
 
 struct smb_pam_user_info {
diff --git a/source4/auth/ntlm/wscript_build b/source4/auth/ntlm/wscript_build
index 50d301d..6917185 100644
--- a/source4/auth/ntlm/wscript_build
+++ b/source4/auth/ntlm/wscript_build
@@ -37,6 +37,7 @@ bld.SAMBA_MODULE('auth4_unix',
 	subsystem='auth4',
 	init_function='auth4_unix_init',
 	deps='pam PAM_ERRORS LIBTSOCKET'
+    enabled=bld.CONFIG_SET('WITH_PAM')
 	)
 
 
diff --git a/source4/auth/wscript_configure b/source4/auth/wscript_configure
deleted file mode 100644
index d25cc0b..0000000
--- a/source4/auth/wscript_configure
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/usr/bin/env python
-
-conf.CHECK_HEADERS('security/pam_appl.h')
-conf.CHECK_FUNCS_IN('pam_start', 'pam', checklibc=True)
diff --git a/wscript b/wscript
index a84e5d5..19dc468 100644
--- a/wscript
+++ b/wscript
@@ -143,7 +143,6 @@ def configure(conf):
     conf.RECURSE('source4/ntvfs/sysdep')
     conf.RECURSE('lib/util')
     conf.RECURSE('lib/util/charset')
-    conf.RECURSE('source4/auth')
     conf.RECURSE('nsswitch')
     conf.RECURSE('libcli/smbreadline')
     conf.RECURSE('lib/crypto')
-- 
1.9.1

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150824/e6198d9b/signature.sig>


More information about the samba-technical mailing list