Fix undesired tinderbox rebuilds due to system header wrapper timestamps changing. Bug 273336, r=dbaron. NSPRPUB_PRE_4_2_CLIENT_BRANCH
authorbryner%brianryner.com
Thu, 16 Dec 2004 05:13:45 +0000
branchNSPRPUB_PRE_4_2_CLIENT_BRANCH
changeset 3234 d019998d07b7de381b6a360ece587a21d4ceda09
parent 3233 30b06497ad5ec88f65d973baef7b757fc6bd2eab
child 3235 d557f4ebfe1db91c44860d4b0e9eb8ce4cdb3478
push idunknown
push userunknown
push dateunknown
reviewersdbaron
bugs273336
Fix undesired tinderbox rebuilds due to system header wrapper timestamps changing. Bug 273336, r=dbaron.
config/Makefile.in
--- a/config/Makefile.in
+++ b/config/Makefile.in
@@ -41,16 +41,20 @@ topsrcdir	= @top_srcdir@
 srcdir		= @srcdir@
 VPATH		= @srcdir@
 
 include $(MOD_DEPTH)/config/autoconf.mk
 
 # Indicate that this directory builds build tools.
 INTERNAL_TOOLS	= 1
 
+# For sanity's sake, we compile nsinstall without the wrapped system
+# headers, so that we can use it to set up the wrapped system headers.
+VISIBILITY_FLAGS =
+
 # autoconf.mk must be deleted last (from the top-level directory)
 # because it is included by every makefile.
 DIST_GARBAGE	= nsprincl.mk nsprincl.sh nspr-config
 
 RELEASE_BINS	= nspr-config
 
 include $(topsrcdir)/config/config.mk
 
@@ -128,25 +132,26 @@ OUTOPTION = /Fe
 endif
 endif
 
 # Redefine MAKE_OBJDIR for just this directory
 define MAKE_OBJDIR
 if test ! -d $(@D); then rm -rf $(@D); mkdir $(@D); else true; fi
 endef
 
+export:: $(TARGETS)
+	rm -f $(dist_bindir)/nspr-config
+
 ifdef WRAP_SYSTEM_INCLUDES
 export::
-	mkdir -p $(dist_includedir)/system_wrappers
-	$(PERL) $(srcdir)/make-system-wrappers.pl $(dist_includedir)/system_wrappers < $(srcdir)/system-headers
+	if test ! -d system_wrappers; then mkdir system_wrappers; fi
+	$(PERL) $(srcdir)/make-system-wrappers.pl system_wrappers < $(srcdir)/system-headers
+	$(INSTALL) system_wrappers $(dist_includedir)
 endif
 
-export:: $(TARGETS)
-	rm -f $(dist_bindir)/nspr-config
-
 $(OBJDIR)/%$(PROG_SUFFIX): $(OBJDIR)/%.$(OBJ_SUFFIX)
 	@$(MAKE_OBJDIR)
 ifeq ($(MOZ_OS2_TOOLS),VACPP)
 	$(LD) $(EXEFLAGS) $<
 else
 	$(CC) $(XCFLAGS) $< $(LDFLAGS) $(XLDOPTS) $(OUTOPTION)$@
 endif