[SCM] Samba Shared Repository - branch master updated

Andrew Bartlett abartlet at samba.org
Sat Sep 29 00:52:02 MDT 2012


The branch, master has been updated
       via  f0f310c build: Remove duplicate check for struct getquota_rslt member getquota_rslt_u
       via  006bdc0 build: Fix quota tests, including move of sysquotas.c to the top level
       via  931ed25 lib/replace: Add test for what flag we need for -Werror behaviour
      from  837f47d s3-winbindd: Adjust error code loop logic in rpc_trusted_domains().

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


- Log -----------------------------------------------------------------
commit f0f310c21d0d3863323a7759be104ee3d2d6c23d
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Sat Sep 29 14:31:28 2012 +1000

    build: Remove duplicate check for struct getquota_rslt member getquota_rslt_u
    
    Autobuild-User(master): Andrew Bartlett <abartlet at samba.org>
    Autobuild-Date(master): Sat Sep 29 08:51:03 CEST 2012 on sn-devel-104

commit 006bdc0be0bf2ef70b3eb24d679bd49f6d8079fd
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Sat Sep 29 14:28:57 2012 +1000

    build: Fix quota tests, including move of sysquotas.c to the top level
    
    This correctly detects quotas on FreeBSD
    
    Andrew Bartlett

commit 931ed2509d93110b525f763ffb15ee3feff87fa0
Author: Andrew Bartlett <abartlet at samba.org>
Date:   Sat Sep 29 14:36:41 2012 +1000

    lib/replace: Add test for what flag we need for -Werror behaviour

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

Summary of changes:
 lib/replace/wscript                  |    9 +++++++++
 source3/configure.in                 |    4 ++--
 source3/wscript                      |   18 +++++++-----------
 {source3/tests => tests}/sysquotas.c |    4 ++--
 4 files changed, 20 insertions(+), 15 deletions(-)
 rename {source3/tests => tests}/sysquotas.c (99%)


Changeset truncated at 500 lines:

diff --git a/lib/replace/wscript b/lib/replace/wscript
index f1f1cef..732c664 100644
--- a/lib/replace/wscript
+++ b/lib/replace/wscript
@@ -53,6 +53,15 @@ struct foo bar = { .y = 'X', .x = 1 };
                 conf.ADD_CFLAGS(f)
             break
 
+    # Try to find the right extra flags for -Werror behaviour
+    for f in ["-Werror", "-w2", "-errwarn"]:
+        if conf.CHECK_CFLAGS([f], '''
+'''):
+            if not 'WERROR_CFLAGS' in conf.env:
+                conf.env['WERROR_CFLAGS'] = []
+            conf.env['WERROR_CFLAGS'].extend([f])
+            break
+
     conf.CHECK_HEADERS('linux/types.h crypt.h locale.h acl/libacl.h compat.h')
     conf.CHECK_HEADERS('acl/libacl.h attr/xattr.h compat.h ctype.h dustat.h')
     conf.CHECK_HEADERS('fcntl.h fnmatch.h glob.h history.h krb5.h langinfo.h')
diff --git a/source3/configure.in b/source3/configure.in
index 5045742..d47f08a 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -4617,7 +4617,7 @@ AC_TRY_RUN_STRICT([
 #define HAVE_QUOTACTL_4A 1
 #define AUTOCONF_TEST 1
 #include "confdefs.h"
-#include "${srcdir-.}/../tests/sysquotas.c"],[$CFLAGS $Werror_FLAGS],[$CPPFLAGS],[$LDFLAGS],
+#include "${srcdir-.}/../../tests/sysquotas.c"],[$CFLAGS $Werror_FLAGS],[$CPPFLAGS],[$LDFLAGS],
            samba_cv_HAVE_QUOTACTL_4A=yes,samba_cv_HAVE_QUOTACTL_4A=no,samba_cv_HAVE_QUOTACTL_4A=cross)])
 if test x"$samba_cv_HAVE_QUOTACTL_4A" = x"yes"; then
     samba_cv_SYSQUOTA_FOUND=yes;
@@ -4631,7 +4631,7 @@ AC_TRY_RUN_STRICT([
 #define HAVE_QUOTACTL_4B 1
 #define AUTOCONF_TEST 1
 #include "confdefs.h"
-#include "${srcdir-.}/../tests/sysquotas.c"],[$CFLAGS $Werror_FLAGS],[$CPPFLAGS],[$LDFLAGS],
+#include "${srcdir-.}/../../tests/sysquotas.c"],[$CFLAGS $Werror_FLAGS],[$CPPFLAGS],[$LDFLAGS],
            samba_cv_HAVE_QUOTACTL_4B=yes,samba_cv_HAVE_QUOTACTL_4B=no,samba_cv_HAVE_QUOTACTL_4B=cross)])
 if test x"$samba_cv_HAVE_QUOTACTL_4B" = x"yes"; then
     samba_cv_SYSQUOTA_FOUND=yes;
diff --git a/source3/wscript b/source3/wscript
index 3815c7c..765f761 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -1238,23 +1238,24 @@ main() {
             if not conf.CHECK_CODE('''
                 #define HAVE_QUOTACTL_4A 1
                 #define AUTOCONF_TEST 1
-                #include "confdefs.h"
-                #include "${srcdir-.}/../tests/sysquotas.c"
+                #include "../tests/sysquotas.c"
                 ''',
+                                   cflags=conf.env['WERROR_CFLAGS'],
                                    define='HAVE_QUOTACTL_4A',
                                    msg='for QUOTACTL_4A: long quotactl(int cmd, char *special, qid_t id, caddr_t addr)',
                                    execute=True,
-                                   local_include=False):
+                                   addmain=False):
+
                 conf.CHECK_CODE('''
                 #define HAVE_QUOTACTL_4B 1
                 #define AUTOCONF_TEST 1
-                #include "confdefs.h"
-                #include "${srcdir-.}/../tests/sysquotas.c"
+                #include "../tests/sysquotas.c"
                 ''',
+                                cflags=conf.env['WERROR_CFLAGS'],
                                 define='HAVE_QUOTACTL_4B',
                                 msg='for QUOTACTL_4B:  int quotactl(const char *path, int cmd, int id, char *addr)',
                                 execute=True,
-                                local_include=False)
+                                addmain=False)
 
         conf.CHECK_CODE('''
                      clnt_create("", RQUOTAPROG, RQUOTAVERS, "udp");
@@ -1265,11 +1266,6 @@ main() {
                         execute=True,
                         local_include=False)
 
-        conf.CHECK_STRUCTURE_MEMBER('struct getquota_rslt', 
-                                    'getquota_rslt_u', 
-                                    define='HAVE_GETQUOTA_RSLT_GETQUOTA_RSLT_U',
-                                    headers='rpcsvc/rquota.h')
-
         if conf.CONFIG_SET('HAVE_QUOTACTL_LINUX') or \
            conf.CONFIG_SET('HAVE_QUOTACTL_4A') or \
            conf.CONFIG_SET('HAVE_QUOTACTL_4B') or \
diff --git a/source3/tests/sysquotas.c b/tests/sysquotas.c
similarity index 99%
rename from source3/tests/sysquotas.c
rename to tests/sysquotas.c
index 1544dca..afec3f1 100644
--- a/source3/tests/sysquotas.c
+++ b/tests/sysquotas.c
@@ -42,7 +42,7 @@ extern int quotactl(int cmd, const char *special, uid_t uid, void *addr);
 	struct SYS_DQBLK D;
 
 	ret = quotactl(Q_GETQUOTA,"/dev/hda1",0,(void *)&D);
-	
+
 	return ret;
 }
 
@@ -84,7 +84,7 @@ extern int quotactl(int cmd, const char *special, uid_t uid, void *addr);
 #endif
 
  int main(void)
-{	
+{
 	autoconf_quota();
 	return 0;
 }


-- 
Samba Shared Repository


More information about the samba-cvs mailing list