From 62689d8166b8e070f855e6910470796dd7e1b2c8 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Fri, 22 Apr 2011 11:47:11 +0200 Subject: s3: Many pthreadpool fixes In particular, this makes it fork-safe --- source3/configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index b2c1856bec..b4ac2114d4 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6647,7 +6647,7 @@ if test x"$enable_pthreadpool" = x"yes" -a x"$samba_cv_HAVE_PTHREAD" = x"yes"; t LIBS="$LIBS $PTHREAD_LDFLAGS" CFLAGS="$CFLAGS $PTHREAD_CFLAGS" AC_DEFINE(WITH_PTHREADPOOL, 1, [Whether to include pthreadpool helpers]) - AC_SUBST(PTHREADPOOL_OBJ, "lib/pthreadpool.o") + AC_SUBST(PTHREADPOOL_OBJ, "lib/pthreadpool/pthreadpool.o") fi ################################################# -- cgit From 39375de8354b676904e1fea097a68178acd987e4 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 23 Apr 2011 16:49:04 +0200 Subject: s3: Add pthreadpooltest to main build --- source3/configure.in | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index b4ac2114d4..3a2f089a29 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6648,6 +6648,8 @@ if test x"$enable_pthreadpool" = x"yes" -a x"$samba_cv_HAVE_PTHREAD" = x"yes"; t CFLAGS="$CFLAGS $PTHREAD_CFLAGS" AC_DEFINE(WITH_PTHREADPOOL, 1, [Whether to include pthreadpool helpers]) AC_SUBST(PTHREADPOOL_OBJ, "lib/pthreadpool/pthreadpool.o") + PTHREADPOOLTEST="bin/pthreadpooltest\$(EXEEXT)" + AC_SUBST(PTHREADPOOLTEST) fi ################################################# -- cgit From 4f6b1e8c81776cf1fa386574e60e54fe6b4fe82e Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 25 Apr 2011 10:55:58 +0200 Subject: s3: Check for res_ninit Autobuild-User: Volker Lendecke Autobuild-Date: Mon Apr 25 11:44:58 CEST 2011 on sn-devel-104 --- source3/configure.in | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 3a2f089a29..556b8d3aee 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -1411,6 +1411,14 @@ AC_CHECK_LIB(resolv, dn_expand) AC_CHECK_LIB(resolv, _dn_expand) AC_CHECK_LIB(resolv, __dn_expand) +AC_TRY_COMPILE([#include ], + [struct __res_state s; res_ninit(&s);], + ac_cv_have_res_ninit=yes,ac_cv_have_res_ninit=no) + +if test x"$ac_cv_have_res_ninit" = x"yes"; then + AC_DEFINE(HAVE_RES_NINIT, 1, [Whether we have res_ninit]) +fi + # # Check for the functions putprpwnam, set_auth_parameters, # getspnam, bigcrypt and getprpwnam in -lsec and -lsecurity -- cgit From 6ec4306f8c3fed7ec5b5bd164c5829b2661589b7 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 16 Apr 2011 15:41:50 +1000 Subject: auth/kerberos: Create common helper to get the verified PAC from GSSAPI This only works for Heimdal and MIT Krb5 1.8, other versions will get an ACCESS_DEINED error. We no longer manually verify any details of the PAC in Samba for GSSAPI logins, as we never had the information to do it properly, and it is better to have the GSSAPI library handle it. Andrew Bartlett --- source3/configure.in | 1 + 1 file changed, 1 insertion(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 556b8d3aee..883f0b1df0 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3869,6 +3869,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(krb5_get_host_realm, $KRB5_LIBS) AC_CHECK_FUNC_EXT(krb5_free_host_realm, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_krb5_import_cred, $KRB5_LIBS) + AC_CHECK_FUNC_EXT(gss_get_name_attribute, $KRB5_LIBS) # MIT krb5 1.8 does not expose this call (yet) AC_CHECK_DECLS(krb5_get_credentials_for_user, [], [], [#include ]) -- cgit From cd7112ba84759a677e51111e44b5f531d602c77c Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 16 Apr 2011 15:39:00 +1000 Subject: s3-gse: Don't release the mech OID from gss_accept_security_context This is constant data according to the man pages I find for this fucntion, and causes a segfault to free() when linked to Heimdal. I am advised that while it is constant for gss_mech_krb5, it may not be for other mechanisms, so an assert will ensure this is dealt with by the programmer who extends this code in future. Andrew Bartlett --- source3/configure.in | 1 + 1 file changed, 1 insertion(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 883f0b1df0..a463aa910d 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3870,6 +3870,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(krb5_free_host_realm, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_krb5_import_cred, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_get_name_attribute, $KRB5_LIBS) + AC_CHECK_FUNC_EXT(gss_oid_equal, $KRB5_LIBS) # MIT krb5 1.8 does not expose this call (yet) AC_CHECK_DECLS(krb5_get_credentials_for_user, [], [], [#include ]) -- cgit From 47e28702288f065d539baab70907d50b7d59d27e Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 27 Apr 2011 14:34:03 +1000 Subject: auth/kerberos Add check for gss_inquire_sec_context_by_oid Not all kerberos distributions have this function. Andrew Bartlett Autobuild-User: Andrew Bartlett Autobuild-Date: Wed Apr 27 07:39:08 CEST 2011 on sn-devel-104 --- source3/configure.in | 1 + 1 file changed, 1 insertion(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index a463aa910d..3624c25e62 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3871,6 +3871,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(gss_krb5_import_cred, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_get_name_attribute, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_oid_equal, $KRB5_LIBS) + AC_CHECK_FUNC_EXT(gss_inquire_sec_context_by_oid, $KRB5_LIBS) # MIT krb5 1.8 does not expose this call (yet) AC_CHECK_DECLS(krb5_get_credentials_for_user, [], [], [#include ]) -- cgit From e1eae822856c076f63874d8d3b07691b3154848d Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 30 Apr 2011 12:05:25 +1000 Subject: kerberos: Only include gssapi/gssapi_krb5.h when available --- source3/configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 3624c25e62..8164a44f00 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3791,7 +3791,7 @@ if test x"$with_ads_support" != x"no"; then # now check for gssapi headers. This is also done here to allow for # different kerberos include paths - AC_CHECK_HEADERS(gssapi.h gssapi/gssapi_generic.h gssapi/gssapi.h gssapi/gssapi_ext.h com_err.h) + AC_CHECK_HEADERS(gssapi.h gssapi/gssapi_generic.h gssapi/gssapi.h gssapi/gssapi_ext.h gssapi/gssapi_krb5.h com_err.h) ################################################################## # we might need the k5crypto and com_err libraries on some systems -- cgit From 9738f35f2cef0af11c3390162a9c2a3841d6073b Mon Sep 17 00:00:00 2001 From: Björn Jacke Date: Wed, 20 Apr 2011 23:32:12 +0200 Subject: ѕ3/configure: move out generic LDFLAGS in the solaris case here MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Stefan Metzmacher --- source3/configure.in | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 8164a44f00..443e0bdfbd 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -518,6 +518,7 @@ case "$host_os" in AC_MSG_RESULT([no large file support]) ;; 5.*) + LDFLAGS="$LDFLAGS -lthread" AC_MSG_RESULT([enabling large file support]) if test "$ac_cv_prog_gcc" = yes; then ${CC-cc} -v >conftest.c 2>&1 @@ -526,19 +527,16 @@ case "$host_os" in case "$ac_cv_gcc_compiler_version_number" in *"gcc version 2.6"*|*"gcc version 2.7"*) CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE -D_REENTRANT" - LDFLAGS="$LDFLAGS -lthread" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) ;; *) CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64" - LDFLAGS="$LDFLAGS -lthread" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) AC_DEFINE(_FILE_OFFSET_BITS, 64, [File offset bits]) ;; esac else CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64" - LDFLAGS="$LDFLAGS -lthread" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) AC_DEFINE(_FILE_OFFSET_BITS, 64, [File offset bits]) fi -- cgit From 862ff644ee564b2b3ed316da8c19df2f958aef66 Mon Sep 17 00:00:00 2001 From: Björn Jacke Date: Wed, 20 Apr 2011 23:40:30 +0200 Subject: ѕ3/configure: move out generic CPPFLAGS in the solaris case here MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Stefan Metzmacher --- source3/configure.in | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 443e0bdfbd..67c440d118 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -519,6 +519,7 @@ case "$host_os" in ;; 5.*) LDFLAGS="$LDFLAGS -lthread" + CPPFLAGS="$CPPFLAGS -D_REENTRANT" AC_MSG_RESULT([enabling large file support]) if test "$ac_cv_prog_gcc" = yes; then ${CC-cc} -v >conftest.c 2>&1 @@ -526,17 +527,17 @@ case "$host_os" in rm -fr conftest.c case "$ac_cv_gcc_compiler_version_number" in *"gcc version 2.6"*|*"gcc version 2.7"*) - CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE -D_REENTRANT" + CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) ;; *) - CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64" + CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) AC_DEFINE(_FILE_OFFSET_BITS, 64, [File offset bits]) ;; esac else - CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_REENTRANT -D_FILE_OFFSET_BITS=64" + CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64" AC_DEFINE(_LARGEFILE64_SOURCE, 1, [Whether to enable large file support]) AC_DEFINE(_FILE_OFFSET_BITS, 64, [File offset bits]) fi -- cgit From 3f68b43dd56b8f338a18074741162bf6437ae78d Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Wed, 4 May 2011 15:48:27 +0200 Subject: vfs_gpfs: Properly notify the offline->online changes This needs to be a separate module that cooperates with vfs_gpfs. If aio_fork is used early in the module chain it (correctly) does not propagate the aio ops down, so vfs_gpfs does not see them. This slim module must come early in the chain for notifies to work properly. --- source3/configure.in | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 67c440d118..f9263f6e82 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -1117,6 +1117,7 @@ AC_CHECK_HEADERS(gpfs_gpl.h) if test x"$ac_cv_header_gpfs_gpl_h" = x"yes"; then AC_DEFINE(HAVE_GPFS,1,[Whether GPFS GPL headers are available]) default_shared_modules="$default_shared_modules vfs_gpfs" + default_shared_modules="$default_shared_modules vfs_gpfs_hsm_notify" fi ############################################# @@ -6882,6 +6883,7 @@ SMB_MODULE(vfs_cacheprime, \$(VFS_CACHEPRIME_OBJ), "bin/cacheprime.$SHLIBEXT", V SMB_MODULE(vfs_prealloc, \$(VFS_PREALLOC_OBJ), "bin/prealloc.$SHLIBEXT", VFS) SMB_MODULE(vfs_commit, \$(VFS_COMMIT_OBJ), "bin/commit.$SHLIBEXT", VFS) SMB_MODULE(vfs_gpfs, \$(VFS_GPFS_OBJ), "bin/gpfs.$SHLIBEXT", VFS) +SMB_MODULE(vfs_gpfs_hsm_notify, \$(VFS_GPFS_PREFETCH_OBJ), "bin/gpfs_hsm_notify.$SHLIBEXT", VFS) SMB_MODULE(vfs_readahead, \$(VFS_READAHEAD_OBJ), "bin/readahead.$SHLIBEXT", VFS) SMB_MODULE(vfs_tsmsm, \$(VFS_TSMSM_OBJ), "bin/tsmsm.$SHLIBEXT", VFS) SMB_MODULE(vfs_fileid, \$(VFS_FILEID_OBJ), "bin/fileid.$SHLIBEXT", VFS) -- cgit From ac25835ab7b76226bd59fec9ffef46d5c5817d54 Mon Sep 17 00:00:00 2001 From: Gordon Ross Date: Fri, 6 May 2011 16:00:08 -0700 Subject: Fix Samba3 on OpenIndiana. I'd like Samba to use the native OpenLDAP and MIT Kerberos libs. Attached are some patches to do that. (relative to git master) It does not build for me without these. (OpenIndiana is an off-shoot of OpenSolaris See http://www.openindiana.org) Autobuild-User: Jeremy Allison Autobuild-Date: Sat May 7 02:20:14 CEST 2011 on sn-devel-104 --- source3/configure.in | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index f9263f6e82..11dbc2872e 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3579,16 +3579,16 @@ else # Check to see whether there is enough LDAP functionality to be able # to build AD support. -# HPUX only has ldap_init; ok, we take care of this in smbldap.c +# HPUX and Solaris only has ldap_init; ok, we take care of this in smbldap.c case "$host_os" in - *hpux*) + *hpux* | *solaris*) AC_CHECK_FUNC_EXT(ldap_init,$LDAP_LIBS) if test x"$ac_cv_func_ext_ldap_init" != x"yes"; then if test x"$with_ads_support" = x"yes"; then - AC_MSG_ERROR(Active Directory support on HPUX requires ldap_init) + AC_MSG_ERROR(Active Directory support on HPUX or Solaris requires ldap_init) elif test x"$with_ads_support" = x"auto"; then - AC_MSG_WARN(Disabling Active Directory support (requires ldap_init on HPUX)) + AC_MSG_WARN(Disabling Active Directory support (requires ldap_init on HPUX or Solaris)) with_ads_support=no fi fi @@ -3638,7 +3638,6 @@ if test x"$with_ads_support" != x"no"; then ;; yes) AC_MSG_RESULT(/usr) - FOUND_KRB5=yes ;; *) AC_MSG_RESULT($withval) @@ -3727,6 +3726,21 @@ if test x"$with_ads_support" != x"no"; then fi fi + if test x$FOUND_KRB5 = x"no"; then + ################################################# + # see if this box has Solaris MIT kerberos implementation + AC_MSG_CHECKING(for Solaris MIT kerberos) + if test -x "$KRB5CONFIG" && $KRB5CONFIG --version | grep -s Solaris | grep -s MIT > /dev/null ; then + FOUND_KRB5=yes + KRB5_LIBS="-lgss -lkrb5" + KRB5_CFLAGS="`$KRB5CONFIG --cflags`" + KRB5_CPPFLAGS="`$KRB5CONFIG --cflags`" + AC_MSG_RESULT(yes) + else + AC_MSG_RESULT(no) + fi + fi + ac_save_CFLAGS=$CFLAGS ac_save_CPPFLAGS=$CPPFLAGS ac_save_LDFLAGS=$LDFLAGS @@ -3816,6 +3830,7 @@ if test x"$with_ads_support" != x"no"; then # now see if we can find the gssapi libs in standard paths if test x"$have_gssapi" != x"yes"; then AC_CHECK_LIB_EXT(gssapi_krb5, KRB5_LIBS,gss_display_status,[],[],have_gssapi=yes) + AC_CHECK_LIB_EXT(gss, KRB5_LIBS,gss_display_status,[],[],have_gssapi=yes) AC_CHECK_FUNC_EXT(gss_wrap_iov, $KRB5_LIBS) fi @@ -3870,6 +3885,7 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(krb5_free_host_realm, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_krb5_import_cred, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_get_name_attribute, $KRB5_LIBS) + AC_CHECK_FUNC_EXT(gss_mech_krb5, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_oid_equal, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_inquire_sec_context_by_oid, $KRB5_LIBS) -- cgit From 7e8f086798c36f64581ed7444df535e85fa0b5af Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Mon, 9 May 2011 10:59:15 +0200 Subject: s3-build: Move generated config.h and config.h.in to include/autoconf This ensures that these are not found by the waf build, which causes issues when the wrong config.h is used by the recursive smbtorture build Andrew Bartlett --- source3/configure.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 11dbc2872e..82cd664165 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6,7 +6,7 @@ AC_PREREQ(2.54) AC_INIT([Samba],[3],[samba-technical@samba.org]) AC_CONFIG_SRCDIR([include/includes.h]) -AC_CONFIG_HEADER(include/config.h) +AC_CONFIG_HEADER(include/autoconf/config.h) AC_DEFINE(CONFIG_H_IS_FROM_SAMBA,1,[Marker for samba's config.h]) case "$PATH" in @@ -34,7 +34,7 @@ done AC_SUBST(LIBTEVENT_OBJ0) LIBS="${LIBS} ${TEVENT_LIBS}" -SAMBA_CPPFLAGS="-Iinclude -I${srcdir-.}/include -I. -I${srcdir-.}" +SAMBA_CPPFLAGS="-Iinclude/autoconf -Iinclude -I${srcdir-.}/include -I. -I${srcdir-.}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/../lib/replace" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} ${TEVENT_CFLAGS}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/librpc" -- cgit From f8e32980f4fab8d6cad5c9f95fab0d1828717cd2 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 18:35:06 +0200 Subject: s3:configure: add --enable-smbtorture4 switch --- source3/configure.in | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 82cd664165..24ce21a9b4 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -196,7 +196,14 @@ AC_ARG_WITH(profiling-data, ) dnl Checks for programs. -smbtorture4_possible=yes +AC_ARG_ENABLE(smbtorture4, + [AS_HELP_STRING([--enable-smbtorture4], [Enable building smbtorture4 (default=auto)])]) + +if test x$enable_smbtorture4 != xno; then + smbtorture4_possible=yes +else + smbtorture4_possible=no +fi AC_PROG_INSTALL AC_PROG_AWK -- cgit From adb3fc2f1d85f7621043d087ed2afb0fd053a009 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 12:44:04 +0200 Subject: s3:build: add an optional full version argument to the SMB_LIBRARY() macro. --- source3/configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 24ce21a9b4..1d1094c5ce 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2179,7 +2179,7 @@ fi SMB_LIBRARY(netapi, 0) SMB_LIBRARY(smbclient, 0) SMB_LIBRARY(smbsharemodes, 0) -SMB_LIBRARY(addns, 0, no, [undefined API]) +SMB_LIBRARY(addns, 0, [], no, [undefined API]) -- cgit From d5d53ba5148d57bae207ded7525a4a38fcb5836f Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:37:58 +0200 Subject: s3:build: add LIBWBCLIENT_FULLVER for consistency with SMB_LIBRARY() --- source3/configure.in | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 1d1094c5ce..f4e8620810 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -73,6 +73,7 @@ AC_SUBST(LIBWBCLIENT_SHARED) AC_SUBST(LIBWBCLIENT_STATIC_TARGET) AC_SUBST(LIBWBCLIENT_STATIC) AC_SUBST(LIBWBCLIENT_SOVER) +AC_SUBST(LIBWBCLIENT_FULLVER) AC_SUBST(LIBWBCLIENT) AC_SUBST(LIBWBCLIENT_LIBS) @@ -6398,6 +6399,7 @@ else LIBWBCLIENT_SHARED_TARGET=bin/libwbclient.$SHLIBEXT LIBWBCLIENT_STATIC_TARGET=bin/libwbclient.a LIBWBCLIENT_SOVER=0 + LIBWBCLIENT_FULLVER=0 if test $BLDSHARED = true -a x"$HAVE_WINBIND" = x"yes" -a x"$BUILD_LIBWBCLIENT_SHARED" = x"yes"; then NSS_MODULES="${WINBIND_NSS} ${WINBIND_WINS_NSS}" ## Only worry about libwbclient if we have shared -- cgit From abef191fb9fa9edbdb68d7cbbf017e1fa74583f2 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:38:38 +0200 Subject: s3:build: reformat AC_ARG_ENABLE(external_libtalloc...) --- source3/configure.in | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index f4e8620810..1c39f358fc 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2088,8 +2088,11 @@ LINK_LIBSMBCLIENT=STATIC # TODO: for talloc and tdb (at least), these should # be extracted from their respective source directories # -AC_ARG_ENABLE(external_libtalloc, [AS_HELP_STRING([--enable-external-libtalloc], [Enable external talloc [default=auto]])], -[ enable_external_libtalloc=$enableval ], [ enable_external_libtalloc=auto ]) +AC_ARG_ENABLE(external_libtalloc, + [AS_HELP_STRING([--enable-external-libtalloc], + [Enable external talloc [default=auto]])], + [ enable_external_libtalloc=$enableval ], + [ enable_external_libtalloc=auto ]) if test "x$enable_external_libtalloc" != xno then -- cgit From b731b6e032d9ba1469c349d6c46bd7bb52b18c28 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:39:03 +0200 Subject: s3:build: fix typo in definition of --enable-external-libtdb --- source3/configure.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 1c39f358fc..2e47cf2e64 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2127,8 +2127,8 @@ fi AC_ARG_ENABLE(external_libtdb, [AS_HELP_STRING([--enable-external-libtdb], [Enable external tdb [default=auto]])], - [ enable_external_libtalloc=$enableval ], - [ enable_external_libtalloc=auto ]) + [ enable_external_libtdb=$enableval ], + [ enable_external_libtdb=auto ]) if test "x$enable_external_libtdb" != xno then -- cgit From 472cabbdea3d5def7e7a36b19c5851a0cf0d8d83 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:40:59 +0200 Subject: s3:build: determine full version of libtalloc for the samba build --- source3/configure.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 2e47cf2e64..4edd818e87 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2110,7 +2110,8 @@ if test "x$enable_external_libtalloc" = xno then m4_include(../lib/talloc/libtalloc.m4) LINK_LIBTALLOC=STATIC - SMB_LIBRARY(talloc, 2) + LIBTALLOCVERSION=`grep ^VERSION ${tallocdir}/wscript | sed -e "s/'//g" -e 's/.* //'` + SMB_LIBRARY(talloc, 2, ${LIBTALLOCVERSION}) LIBTALLOC_OBJ0="" for obj in ${TALLOC_OBJ}; do LIBTALLOC_OBJ0="${LIBTALLOC_OBJ0} ${tallocdir}/${obj}" -- cgit From 6c300ec4b51bfd57837d193f0b17b60cb152fc27 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:42:07 +0200 Subject: s3:build: link libtalloc as shared lib if using shared libs at all --- source3/configure.in | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 4edd818e87..34be4fe761 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2109,7 +2109,9 @@ fi if test "x$enable_external_libtalloc" = xno then m4_include(../lib/talloc/libtalloc.m4) - LINK_LIBTALLOC=STATIC + if test x"$USESHARED" == x"no" ; then + LINK_LIBTALLOC=STATIC + fi LIBTALLOCVERSION=`grep ^VERSION ${tallocdir}/wscript | sed -e "s/'//g" -e 's/.* //'` SMB_LIBRARY(talloc, 2, ${LIBTALLOCVERSION}) LIBTALLOC_OBJ0="" -- cgit From 23637b5789a43fe75bb4eadabd33fb321272b42b Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:42:53 +0200 Subject: s3:build: determine full version of libtdb for the samba build --- source3/configure.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 34be4fe761..11bea9d7ae 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2151,7 +2151,8 @@ if test "x$enable_external_libtdb" = xno then m4_include(../lib/tdb/libtdb.m4) LINK_LIBTDB=STATIC - SMB_LIBRARY(tdb, 1) + LIBTDBVERSION=`grep ^VERSION ${tdbdir}/wscript | sed -e "s/'//g" -e 's/.* //'` + SMB_LIBRARY(tdb, 1, ${LIBTDBVERSION}) LIBTDB_OBJ0="" LIBTDB_LIBS="$LIBTDB_LIBS $TDB_DEPS" for obj in ${TDB_OBJ}; do -- cgit From 3f222513cc99b7ce048bcdaa8cc10f7b91616904 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Fri, 6 May 2011 16:43:31 +0200 Subject: s3:build: link libtdb as shared lib if using shared libs at all --- source3/configure.in | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 11bea9d7ae..e1e2d39acd 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2150,7 +2150,9 @@ AC_SUBST(LIBTDB_OBJ0) if test "x$enable_external_libtdb" = xno then m4_include(../lib/tdb/libtdb.m4) - LINK_LIBTDB=STATIC + if test x"$USESHARED" == x"no" ; then + LINK_LIBTDB=STATIC + fi LIBTDBVERSION=`grep ^VERSION ${tdbdir}/wscript | sed -e "s/'//g" -e 's/.* //'` SMB_LIBRARY(tdb, 1, ${LIBTDBVERSION}) LIBTDB_OBJ0="" -- cgit From 5abab13851ff2fc3a5792d08cc753c9b479c8cc1 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 31 May 2011 15:38:55 -0700 Subject: Add check for the getcwd function being able to take NULL,0 arguments. --- source3/configure.in | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index e1e2d39acd..12d083b468 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2602,6 +2602,17 @@ if test x"$samba_cv_HAVE_LINUX_FALLOCATE64" = x"yes" && test x"$ac_cv_func_fallo AC_DEFINE(HAVE_LINUX_FALLOCATE64,1,[Whether the Linux 'fallocate64' function is available]) fi +AC_CACHE_CHECK([for getcwd takes NULL],samba_cv_GETCWD_TAKES_NULL,[ +AC_TRY_RUN([ +#if defined(HAVE_UNISTD_H) +#include +#endif +main() { char *s = getcwd(NULL,0); if (s) exit(0); exit(1); }], +samba_cv_GETCWD_TAKES_NULL=yes,samba_cv_GETCWD_TAKES_NULL=no,samba_cv_GETCWD_TAKES_NULL=cross)]) +if test x"$samba_cv_GETCWD_TAKES_NULL" = x"yes"; then + AC_DEFINE(GETCWD_TAKES_NULL,1,[Whether the getcwd function takes NULL as an argument]) +fi + ICONV_LOOK_DIRS="/usr /usr/local /sw /opt" AC_ARG_WITH(libiconv, [AS_HELP_STRING([--with-libiconv=BASEDIR], [Use libiconv in BASEDIR/lib and BASEDIR/include (default=auto)])], -- cgit From e28df27f2a6744e20e6413cee0f48c66c920e080 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 4 Jun 2011 14:18:31 +0200 Subject: s3: Fix the build on FreeBSD 8 This is probably not the last word on gss_mech_krb5, but for now it fixes the build on FreeBSD --- source3/configure.in | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 12d083b468..324ada4c54 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -3917,6 +3917,11 @@ if test x"$with_ads_support" != x"no"; then AC_CHECK_FUNC_EXT(gss_oid_equal, $KRB5_LIBS) AC_CHECK_FUNC_EXT(gss_inquire_sec_context_by_oid, $KRB5_LIBS) + # This is for FreeBSD (and possibly others). gss_mech_krb5 is a + # #define to GSS_KRB5_MECHANISM, which is defined in -lgssapi_krb5 + AC_CHECK_LIB_EXT(gssapi_krb5, KRB5_LIBS, GSS_KRB5_MECHANISM, + [KRB5_LIBS="$KRB5_LIBS -lgssapi_krb5"]) + # MIT krb5 1.8 does not expose this call (yet) AC_CHECK_DECLS(krb5_get_credentials_for_user, [], [], [#include ]) -- cgit From 754c677b0bbf3ea6c7d2a73c93848f1b0d68c91e Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Mon, 20 Jun 2011 16:54:15 +0930 Subject: lib: import ccan modules for tdb2 Imported from git://git.ozlabs.org/~ccan/ccan init-1161-g661d41f Signed-off-by: Rusty Russell --- source3/configure.in | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 324ada4c54..2d248cc4a5 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -26,6 +26,7 @@ AC_LIBREPLACE_CC_CHECKS AC_LIBREPLACE_RUNTIME_LIB_PATH_VAR m4_include(../lib/tevent/libtevent.m4) +m4_include(../lib/ccan/libccan.m4) LIBTEVENT_OBJ0="" for obj in ${TEVENT_OBJ}; do @@ -37,6 +38,7 @@ LIBS="${LIBS} ${TEVENT_LIBS}" SAMBA_CPPFLAGS="-Iinclude/autoconf -Iinclude -I${srcdir-.}/include -I. -I${srcdir-.}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/../lib/replace" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} ${TEVENT_CFLAGS}" +SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} ${CCAN_CFLAGS}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/librpc" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/.." -- cgit From 0e4c358e2710580d5aeb439d767c87aaf4c0f2f3 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Mon, 20 Jun 2011 18:40:25 +0930 Subject: tdb_compat.h: divert every tdb build and includes to tdb_compat We change all the headers and wscript files to use tdb_compat; this means we have one place to decide whether to use TDB1 or TDB2. Signed-off-by: Rusty Russell --- source3/configure.in | 1 + 1 file changed, 1 insertion(+) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index 2d248cc4a5..e8662da0e7 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -41,6 +41,7 @@ SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} ${TEVENT_CFLAGS}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} ${CCAN_CFLAGS}" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/librpc" SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/.." +SAMBA_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/../lib/tdb_compat" SAMBA_CONFIGURE_CPPFLAGS="${SAMBA_CPPFLAGS} -I${srcdir-.}/../lib/popt" -- cgit From 125a2ff262aa312df20eec68802fd5f8a47f492f Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 22 Jun 2011 09:52:31 +1000 Subject: lib/util/charset: Remove 'display charset' As discussed in 'CH_DISPLAY and gettext' on the samba-technical list: http://lists.samba.org/archive/samba-technical/2011-June/078190.html Setting this to a value other than 'unix charset' does not make sense, as any system where the filesytem charset does not equal the terminal charset will already have problems with programs as simple as 'ls'. It also means that our output could not be pasted as our input in interactive programs or onto our command line, as we never did translate in the DISPLAY -> UNIX direction. The d_printf() calls are retained in case we need to revisit this, and to support display_set_stderr(). Andrew Bartlett --- source3/configure.in | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index e8662da0e7..e85d9f1f47 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -2693,7 +2693,6 @@ for i in $ICONV_LOOK_DIRS ; do export LDFLAGS LIBS CPPFLAGS default_dos_charset=no - default_display_charset=no default_unix_charset=no # check for default dos charset name @@ -2705,15 +2704,6 @@ for i in $ICONV_LOOK_DIRS ; do fi done - # check for default display charset name - for j in ASCII 646 ; do - rjs_CHARSET($j) - default_display_charset="$ICONV_CHARSET" - if test x"$default_display_charset" = x"$j"; then - break - fi - done - # check for default unix charset name for j in UTF-8 UTF8 ; do rjs_CHARSET($j) @@ -2725,15 +2715,12 @@ for i in $ICONV_LOOK_DIRS ; do if test "$default_dos_charset" != "no" -a \ "$default_dos_charset" != "cross" -a \ - "$default_display_charset" != "no" -a \ - "$default_display_charset" != "cross" -a \ "$default_unix_charset" != "no" -a \ "$default_unix_charset" != "cross" then samba_cv_HAVE_NATIVE_ICONV=yes else if test "$default_dos_charset" = "cross" -o \ - "$default_display_charset" = "cross" -o \ "$default_unix_charset" = "cross" then samba_cv_HAVE_NATIVE_ICONV=cross @@ -2750,11 +2737,10 @@ for i in $ICONV_LOOK_DIRS ; do # match the results we get at runtime anyway. if test x"$samba_cv_HAVE_NATIVE_ICONV" = x"cross" ; then default_dos_charset="CP850" - default_display_charset="ASCII" default_unix_charset="UTF-8" samba_cv_HAVE_NATIVE_ICONV=yes AC_MSG_WARN(assuming the libiconv in $iconv_current_LDFLAGS can convert) - AC_MSG_WARN([$default_dos_charset, $default_display_charset and $default_unix_charset to UCS-16LE]) + AC_MSG_WARN([$default_dos_charset and $default_unix_charset to UCS-16LE]) fi if test x"$samba_cv_HAVE_NATIVE_ICONV" = x"yes" ; then @@ -2773,12 +2759,10 @@ for i in $ICONV_LOOK_DIRS ; do # Turn the #defines into string literals default_dos_charset="\"$default_dos_charset\"" - default_display_charset="\"$default_display_charset\"" default_unix_charset="\"$default_unix_charset\"" AC_DEFINE(HAVE_NATIVE_ICONV,1,[Whether to use native iconv]) AC_DEFINE_UNQUOTED(DEFAULT_DOS_CHARSET,$default_dos_charset,[Default dos charset name]) - AC_DEFINE_UNQUOTED(DEFAULT_DISPLAY_CHARSET,$default_display_charset,[Default display charset name]) AC_DEFINE_UNQUOTED(DEFAULT_UNIX_CHARSET,$default_unix_charset,[Default unix charset name]) break @@ -2800,7 +2784,6 @@ if test x"$ICONV_FOUND" = x"no" -o x"$samba_cv_HAVE_NATIVE_ICONV" != x"yes" ; th AC_MSG_WARN([Sufficient support for iconv function was not found. Install libiconv from http://freshmeat.net/projects/libiconv/ for better charset compatibility!]) AC_DEFINE_UNQUOTED(DEFAULT_DOS_CHARSET,"ASCII",[Default dos charset name]) - AC_DEFINE_UNQUOTED(DEFAULT_DISPLAY_CHARSET,"ASCII",[Default display charset name]) AC_DEFINE_UNQUOTED(DEFAULT_UNIX_CHARSET,"UTF8",[Default unix charset name]) fi -- cgit From de0e0119447060c64f4531c031e5509de3afc1b5 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 22 Jun 2011 09:58:59 +1000 Subject: lib/util/charset: Remove autodetection of charset from LOCALE In the past, our LOCALE would set the display charset of Samba. The display charset has now been removed. This patch removes the support code that detected the locale from the environment. We cannot safely have 'unix charset' follow the locale (at it creates files on disk and entries in databases that must not vary), so this code is unused. As an example, imagine a database is manipulated in the administrator's locale, and then read by smbd starting up in the system default locale. Or smbd restarted by the administrator rather than a startup script. Both of these situations could corrupt databases or filenames on disk. Andrew Bartlett --- source3/configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index e85d9f1f47..d0f841f017 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -1091,7 +1091,7 @@ AC_CHECK_FUNCS(getpwent_r) AC_CHECK_FUNCS(getdents64) AC_CHECK_FUNCS(setenv strcasecmp fcvt fcvtl) AC_CHECK_FUNCS(syslog vsyslog timegm) -AC_CHECK_FUNCS(setlocale nl_langinfo) +AC_CHECK_FUNCS(setlocale) AC_CHECK_FUNCS(nanosleep,,[AC_CHECK_LIB_EXT(rt, LIBS, nanosleep)]) AC_CHECK_FUNCS(lutimes futimes utimensat futimens) AC_CHECK_FUNCS(mlock munlock mlockall munlockall) -- cgit From 4d2c56c4b1a4f846b44f24c6f73e1b95fdf3a9bb Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Wed, 22 Jun 2011 10:40:26 +1000 Subject: s3-net: Bind our gettext results to 'unix charset' This ensures that the translations and any embedded strings are in the same charset. It won't be the one from the user's locale (we no longer auto-detect that), but it will be self-consistent. Thanks to Steve Langasek for pointing this function out! Andrew Bartlett --- source3/configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/configure.in') diff --git a/source3/configure.in b/source3/configure.in index d0f841f017..814c7356d2 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -1100,7 +1100,7 @@ AC_CHECK_HEADERS(sys/mman.h) # setbuffer, shmget, shm_open are needed for smbtorture AC_CHECK_FUNCS(shmget shm_open) AC_CHECK_FUNCS(gettext dgettext) -AC_CHECK_FUNCS(bindtextdomain textdomain) +AC_CHECK_FUNCS(bindtextdomain textdomain bind_textdomain_codeset) AC_CHECK_FUNCS(strupr) # Find a method of generating a stack trace -- cgit