[SCM] Samba Shared Repository - branch master updated - release-4-0-0alpha7-2011-gbef665b

Andrew Bartlett abartlet at samba.org
Thu Jun 4 01:14:52 GMT 2009


The branch, master has been updated
       via  bef665baadebe7ad8a9417dfccb5f210d3f01ae0 (commit)
      from  0daf9a042c76619f4be8ce38b6ee1aba6a1079a4 (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit bef665baadebe7ad8a9417dfccb5f210d3f01ae0
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Thu Jun 4 11:13:05 2009 +1000

    s4:torture Make Samba4 build on hosts with an older libnetapi
    
    For example, Samba4 would not build (for the last week) on Fedora 10,
    with samba-common 3.2.11 installed.
    
    Andrew Bartlett

-----------------------------------------------------------------------

Summary of changes:
 source4/torture/libnetapi/config.m4 |    7 ++++++-
 source4/torture/torture.c           |    4 +---
 2 files changed, 7 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/torture/libnetapi/config.m4 b/source4/torture/libnetapi/config.m4
index fadef69..402f112 100644
--- a/source4/torture/libnetapi/config.m4
+++ b/source4/torture/libnetapi/config.m4
@@ -20,7 +20,12 @@ SMB_ENABLE(TORTURE_LIBNETAPI,NO)
 if test x$use_netapi != xno; then
 	AC_CHECK_HEADERS(netapi.h)
 	AC_CHECK_LIB_EXT(netapi, NETAPI_LIBS, libnetapi_init)
-	if test x"$ac_cv_header_netapi_h" = x"yes" -a x"$ac_cv_lib_ext_netapi_libnetapi_init" = x"yes";then
+	AC_CHECK_LIB_EXT(netapi, NETAPI_LIBS, NetUserModalsGet)
+	AC_CHECK_LIB_EXT(netapi, NETAPI_LIBS, NetUserGetGroups)
+	AC_CHECK_LIB_EXT(netapi, NETAPI_LIBS, NetUserGetInfo)
+	AC_CHECK_LIB_EXT(netapi, NETAPI_LIBS, NetUserSetInfo)
+	if test x"$ac_cv_header_netapi_h" = x"yes" -a x"$ac_cv_lib_ext_netapi_libnetapi_init" = x"yes" -a x"$ac_cv_lib_ext_netapi_NetUserModalsGet" = x"yes" -a x"$ac_cv_lib_ext_netapi_NetUserGetGroups" = x"yes" -a x"$ac_cv_lib_ext_netapi_NetUserGetInfo" = x"yes" -a x"$ac_cv_lib_ext_netapi_NetUserSetInfo" = x"yes";then
+		AC_DEFINE(ENABLE_LIBNETAPI,1,[Whether we have libnetapi on the host system])
 		SMB_ENABLE(NETAPI,YES)
 		SMB_ENABLE(TORTURE_LIBNETAPI,YES)
 	else
diff --git a/source4/torture/torture.c b/source4/torture/torture.c
index d80acff..a7296e6 100644
--- a/source4/torture/torture.c
+++ b/source4/torture/torture.c
@@ -45,7 +45,7 @@ bool torture_register_suite(struct torture_suite *suite)
 	return torture_suite_add_suite(torture_root, suite);
 }
 
-#ifndef HAVE_NETAPI_H
+#ifndef ENABLE_LIBNETAPI
 NTSTATUS torture_libnetapi_init(void)
 {
 	return NT_STATUS_OK;
@@ -63,9 +63,7 @@ _PUBLIC_ int torture_init(void)
 	extern NTSTATUS torture_rpc_init(void);
 	extern NTSTATUS torture_smb2_init(void);
 	extern NTSTATUS torture_net_init(void);
-#ifdef HAVE_NETAPI_H
 	extern NTSTATUS torture_libnetapi_init(void);
-#endif
 	extern NTSTATUS torture_raw_init(void);
 	extern NTSTATUS torture_unix_init(void);
 	extern NTSTATUS torture_winbind_init(void);


-- 
Samba Shared Repository


More information about the samba-cvs mailing list