build: Remove more of the s3 special cases in waf: only pidfile.c needs -DCONFIGFILE
authorAndrew Bartlett <abartlet@samba.org>
Tue, 17 Apr 2012 01:25:40 +0000 (11:25 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 18 Apr 2012 02:04:59 +0000 (12:04 +1000)
buildtools/wafsamba/samba3.py
source3/wscript_build

index fef81523c467e286b4f17f2a844cf0665f561cc9..369285c395ae3735d5b501b53945dfced2432a50 100644 (file)
@@ -100,12 +100,6 @@ def s3_fix_kwargs(bld, kwargs):
         includes += TO_LIST(kwargs['includes'])
     kwargs['includes'] = includes
 
-    # some S3 code assumes that CONFIGFILE is set
-    cflags = ['-DCONFIGFILE="%s"' % bld.env['CONFIGFILE']]
-    if 'cflags' in kwargs:
-        cflags += TO_LIST(kwargs['cflags'])
-    kwargs['cflags'] = cflags
-
 # these wrappers allow for mixing of S3 and S4 build rules in the one build
 
 def SAMBA3_LIBRARY(bld, name, *args, **kwargs):
index bd9241476c9b28d558f795f4d47cd4ca9ab10c95..1781bace42f87eb5af57727616329fef8b7601ff 100755 (executable)
@@ -50,7 +50,7 @@ LIB_SRC = '''
           ${TDB_LIB_SRC}
           ../lib/util/debug_s3.c
           lib/dumpcore.c
-          lib/interface.c lib/pidfile.c
+          lib/interface.c
           lib/username.c
           lib/access.c lib/smbrun.c
           lib/wins_srv.c
@@ -789,9 +789,15 @@ bld.SAMBA3_SUBSYSTEM('samba3util',
                    deps='ndr security NDR_SECURITY samba-util UTIL_TDB ccan',
                    vars=locals())
 
+bld.SAMBA3_SUBSYSTEM('pidfile',
+                     source='lib/pidfile.c',
+                     # only pidfile.c assumes that CONFIGFILE is set
+                     cflags = ['-DCONFIGFILE="%s"' % bld.env['CONFIGFILE']])
+
 bld.SAMBA3_SUBSYSTEM('samba3core',
                    source=LIB_SRC,
                    deps='''
+                        pidfile
                         samba3util
                         LIBTSOCKET
                         NDR_MESSAGING