s3-build: Move generated config.h and config.h.in to include/autoconf
authorAndrew Bartlett <abartlet@samba.org>
Mon, 9 May 2011 08:59:15 +0000 (10:59 +0200)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 9 May 2011 09:21:09 +0000 (11:21 +0200)
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

.gitignore
source3/Makefile-smbtorture4
source3/Makefile.in
source3/configure.in
source3/include/autoconf/README [new file with mode: 0644]
source3/script/mkbuildoptions.awk

index a8eacd5..383bb1e 100644 (file)
@@ -71,8 +71,8 @@ source3/exports/libtalloc.syms
 source3/exports/libtdb.syms
 source3/exports/libwbclient.syms
 source3/include/build_env.h
-source3/include/config.h
-source3/include/config.h.in
+source3/include/autoconf/config.h
+source3/include/autoconf/config.h.in
 source3/include/includes.h.gch
 source3/include/stamp-h
 source3/include/version.h
index 355c146..0dc4706 100644 (file)
@@ -6,7 +6,7 @@ SAMBA4_BINARIES="smbtorture,ndrdump"
 samba4-configure:
        @(cd .. && \
                CFLAGS='' $(WAF) reconfigure || \
-               CFLAGS='' $(WAF) configure --enable-socket-wrapper --enable-nss-wrapper --enable-uid-wrapper --nonshared-binary=$(SAMBA4_BINARIES) --enable-auto-reconfigure --disable-s3build --enable-developer)
+               CFLAGS='' $(WAF) configure --enable-socket-wrapper --enable-nss-wrapper --enable-uid-wrapper --nonshared-binary=$(SAMBA4_BINARIES) --enable-auto-reconfigure --enable-developer)
 
 .PHONY: samba4-configure
 
index 456d4f5..55a3201 100644 (file)
@@ -1766,16 +1766,16 @@ lib/version.o: lib/version.c include/version.h
                echo "$(COMPILE_CC_PATH)" 1>&2;\
                $(COMPILE_CC_PATH) >/dev/null 2>&1
 
-smbd/build_options.o: smbd/build_options.c Makefile include/config.h include/build_env.h include/proto.h
+smbd/build_options.o: smbd/build_options.c Makefile include/autoconf/config.h include/build_env.h include/proto.h
        @echo Compiling $*.c
        @$(COMPILE_CC_PATH) && exit 0;\
                echo "The following command failed:" 1>&2;\
                echo "$(COMPILE_CC_PATH)" 1>&2;\
                $(COMPILE_CC_PATH) >/dev/null 2>&1
 
-smbd/build_options.c: include/config.h.in script/mkbuildoptions.awk
+smbd/build_options.c: include/autoconf/config.h.in script/mkbuildoptions.awk
        @echo Generating $@
-       @dir=smbd $(MAKEDIR) && $(AWK) -f $(srcdir)/script/mkbuildoptions.awk > $(builddir)/smbd/build_options.c < $(srcdir)/include/config.h.in
+       @dir=smbd $(MAKEDIR) && $(AWK) -f $(srcdir)/script/mkbuildoptions.awk > $(builddir)/smbd/build_options.c < $(srcdir)/include/autoconf/config.h.in
 
 bin/.dummy:
        @if (: >> $@ || : > $@) >/dev/null 2>&1; then :; else \
@@ -3362,12 +3362,12 @@ realclean:: clean
 
 distclean:: realclean
        -rm -f smbadduser
-       -rm -f include/config.h Makefile
+       -rm -f include/autoconf/config.h Makefile
        -rm -f config.status config.cache so_locations
        -rm -rf .deps TAGS
 
 realdistclean:: distclean
-       -rm -f include/config.h.in
+       -rm -f include/autoconf/config.h.in
        -rm -f include/version.h
        -rm -f configure
 
index 11dbc28..82cd664 100644 (file)
@@ -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"
diff --git a/source3/include/autoconf/README b/source3/include/autoconf/README
new file mode 100644 (file)
index 0000000..21afbc7
--- /dev/null
@@ -0,0 +1,5 @@
+This directory added so that the autoconf build can generate a
+config.h in a location that the recursive waf build for smbtorture
+won't find.
+
+Andrew Bartlett
\ No newline at end of file
index 3cd0dac..0b1b2ef 100644 (file)
@@ -235,7 +235,7 @@ function output(ARRAY, ELEMENTS, TITLE) {
 END {
        ##################################################
        # add code to show various options
-       print "/* Output various other options (as gleaned from include/config.h.in) */";
+       print "/* Output various other options (as gleaned from include/autoconf/config.h.in) */";
        output(sys_ary,     sys_i,     "System Headers");
        output(headers_ary, headers_i, "Headers");
        output(utmp_ary,    utmp_i,    "UTMP Options");