Bug 969164 - Replace most BUILDING_JS uses with JS_STANDALONE. r=gps
authorMike Hommey <mh+mozilla@glandium.org>
Tue, 11 Feb 2014 10:37:47 +0900
changeset 185201 4e3b435b7d39
parent 185200 2f0f52f627d7
child 185202 504b9759d15c
push id3503
push userraliiev@mozilla.com
push dateMon, 28 Apr 2014 18:51:11 +0000
treeherdermozilla-beta@c95ac01e332e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgps
bugs969164
milestone30.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 969164 - Replace most BUILDING_JS uses with JS_STANDALONE. r=gps Before making top-level traverse js/src moz.build files, there was a need to distinguish between top-level traversing e.g. top-level moz.build or config/moz.build and js/src traversing them. With a single traversal of both moz.build sets, we now only need to distinguish between js standalone builds and gecko builds. There is still, however, a need to distinguish between top-level vs. js/src configure runs on gecko builds to make them subconfigure icu and libffi from top-level instead of js/src in js standalone builds, or when choosing to make js/src's config.status do something when run or not.
Makefile.in
config/Makefile.in
config/recurse.mk
config/rules.mk
config/static-checking-config.mk
js/src/configure.in
--- a/Makefile.in
+++ b/Makefile.in
@@ -40,17 +40,17 @@ ifndef MOZ_PROFILE_USE
 # We need to explicitly put backend.RecursiveMakeBackend here
 # otherwise the rule in rules.mk doesn't run early enough.
 libs binaries export tools:: CLOBBER $(configure_dir)/configure config.status backend.RecursiveMakeBackend
 ifndef JS_STANDALONE
 libs binaries export tools:: $(topsrcdir)/js/src/configure js/src/config.status
 endif
 endif
 
-ifdef BUILDING_JS
+ifdef JS_STANDALONE
 .PHONY: CLOBBER
 CLOBBER:
 else
 CLOBBER: $(topsrcdir)/CLOBBER
 	@echo 'STOP!  The CLOBBER file has changed.'
 	@echo 'Please run the build through a sanctioned build wrapper, such as'
 	@echo '"mach build" or client.mk.'
 	@exit 1
@@ -110,17 +110,17 @@ endif
 .PHONY: install-manifests
 install-manifests: $(addprefix install-dist-,$(install_manifests))
 
 # process_install_manifest needs to be invoked with --no-remove when building
 # js as standalone because automated builds are building nspr separately and
 # that would remove the resulting files.
 # Eventually, a standalone js build would just be able to build nspr itself,
 # removing the need for the former.
-ifdef BUILDING_JS
+ifdef JS_STANDALONE
 NO_REMOVE=1
 endif
 
 .PHONY: $(addprefix install-dist-,$(install_manifests))
 $(addprefix install-dist-,$(install_manifests)): install-dist-%: $(install_manifest_depends)
 	$(call py_action,process_install_manifest,$(if $(NO_REMOVE),--no-remove )$(DIST)/$* _build_manifests/install/dist_$*)
 
 .PHONY: install-tests
@@ -151,17 +151,17 @@ export:: install-manifests
 binaries::
 	@$(MAKE) install-manifests NO_REMOVE=1
 endif
 
 # For historical reasons that are unknown, $(DIST)/sdk is always blown away
 # with no regard for PGO passes. This decision could probably be revisited.
 export:: install-dist-sdk
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 ifdef ENABLE_TESTS
 # Additional makefile targets to call automated test suites
 include $(topsrcdir)/testing/testsuite-targets.mk
 endif
 endif
 
 default all::
 	$(call BUILDSTATUS,TIERS export $(if $(COMPILE_ENVIRONMENT),$(if $(MOZ_PSEUDO_DERECURSE),compile ))libs tools)
@@ -195,17 +195,17 @@ endif
 ifeq (,$(filter-out Linux SunOS,$(OS_ARCH)))
 MAKE_SYM_STORE_ARGS := -c --vcs-info
 DUMP_SYMS_BIN ?= $(DIST)/host/bin/dump_syms
 MAKE_SYM_STORE_PATH := $(DIST)/bin
 endif
 
 SYM_STORE_SOURCE_DIRS := $(topsrcdir)
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 include $(topsrcdir)/toolkit/mozapps/installer/package-name.mk
 
 ifdef MOZ_SYMBOLS_EXTRA_BUILDID
 EXTRA_BUILDID := -$(MOZ_SYMBOLS_EXTRA_BUILDID)
 endif
 
 SYMBOL_INDEX_NAME = \
   $(MOZ_APP_NAME)-$(MOZ_APP_VERSION)-$(OS_TARGET)-$(BUILDID)-$(CPU_ARCH)$(EXTRA_BUILDID)-symbols.txt
@@ -266,17 +266,17 @@ endif
 
 # Look for R_386_PC32 relocations in shared libs, these
 # break x86_64 builds and SELinux users.
 ifeq ($(OS_TARGET)_$(TARGET_XPCOM_ABI),Linux_x86-gcc3)
 check::
 	@relcount=`find $(DIST)/bin -name '*.so' | xargs objdump -R | grep R_386_PC32 | wc -l` && if test $$relcount -gt 0; then echo 'FAILED: R_386_PC32 relocations detected in a shared library.  Did you use a system header without adding it to config/system-headers?'; exit 1; else echo 'PASSED'; fi
 endif
 
-ifdef BUILDING_JS
+ifdef JS_STANDALONE
 # Delegate js-specific rules to js
 check-%:
 	$(MAKE) -C js/src $@
 
 source-package install:
 	$(MAKE) -C js/src $@
 
 # Every export rule depends on config/export, but the rule for config/export
--- a/config/Makefile.in
+++ b/config/Makefile.in
@@ -29,32 +29,32 @@ nsinstall$(HOST_BIN_SUFFIX): $(HOST_PROG
 
 NSINSTALL_EXECUTABLES := nsinstall$(HOST_BIN_SUFFIX)
 NSINSTALL_DEST := $(DIST)/bin
 NSINSTALL_TARGET := export
 INSTALL_TARGETS += NSINSTALL
 endif
 endif
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 HEADERS_FILES = \
 	$(DEPTH)/mozilla-config.h \
 	$(NULL)
 HEADERS_DEST := $(DIST)/include
 HEADERS_TARGET := export
 INSTALL_TARGETS += HEADERS
 endif
 
 PYTHON_UNIT_TESTS := $(wildcard $(srcdir)/tests/unit-*.py)
 
 include $(topsrcdir)/config/rules.mk
 
 HOST_CFLAGS += -DUNICODE -D_UNICODE
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 # Generate a new buildid every time we "export" in config... that's only
 # supposed to be once per-build!
 export::
 ifdef MOZ_BUILD_DATE
 	printf '%s' $(MOZ_BUILD_DATE) > buildid
 else
 	$(PYTHON) $(topsrcdir)/toolkit/xre/make-platformini.py --print-buildid > buildid
 endif
@@ -107,17 +107,17 @@ GARBAGE += $(STL_WRAPPERS_SENTINEL)
 GARBAGE_DIRS += stl_wrappers
 endif
 
 GARBAGE += \
   $(FINAL_LINK_COMPS) $(FINAL_LINK_LIBS) $(FINAL_LINK_COMP_NAMES) buildid $(srcdir)/*.pyc *.pyc
 
 FORCE:
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 check-preqs += check-jar-mn
 endif
 check-preqs += check-makefiles
 
 check:: $(check-preqs)
 
 check-jar-mn::
 	$(MAKE) -C tests/src-simple check-jar
--- a/config/recurse.mk
+++ b/config/recurse.mk
@@ -195,25 +195,23 @@ endif # ifdef TIERS
 
 endif # ifeq ($(NO_RECURSE_MAKELEVEL),$(MAKELEVEL))
 
 endif # ifeq (1_.,$(MOZ_PSEUDO_DERECURSE)_$(DEPTH))
 
 ifdef MOZ_PSEUDO_DERECURSE
 ifeq (.,$(DEPTH))
 # top-level directories
-ifdef BUILDING_JS
 ifndef JS_STANDALONE
 # Only define recurse_targets for js, when it is built as part of gecko.
 recurse_targets := $(addsuffix /binaries,$(call TIER_DIRS,binaries))
 # we want to adjust paths for js/src.
 want_abspaths = 1
 endif
 endif
-endif
 
 ifdef COMPILE_ENVIRONMENT
 
 # Aggregate all dependency files relevant to a binaries build except in
 # the mozilla top-level directory.
 ifneq (_.,$(recurse_targets)_$(DEPTH))
 ALL_DEP_FILES := \
   $(BINARIES_PP) \
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -354,20 +354,16 @@ endif
 
 ifdef MOZ_UPDATE_XTERM
 # Its good not to have a newline at the end of the titlebar string because it
 # makes the make -s output easier to read.  Echo -n does not work on all
 # platforms, but we can trick printf into doing it.
 UPDATE_TITLE = printf '\033]0;%s in %s\007' $(1) $(relativesrcdir)/$(2) ;
 endif
 
-ifdef BUILDING_JS
-NO_BUILDSTATUS_MESSAGES=1
-endif
-
 ifdef MACH
 ifndef NO_BUILDSTATUS_MESSAGES
 define BUILDSTATUS
 @echo 'BUILDSTATUS $1'
 
 endef
 endif
 endif
--- a/config/static-checking-config.mk
+++ b/config/static-checking-config.mk
@@ -2,17 +2,17 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 # The entire tree should be subject to static analysis using the XPCOM
 # script. Additional scripts may be added by specific subdirectories.
 
 DEHYDRA_SCRIPT = $(topsrcdir)/config/static-checking.js
 
-ifndef BUILDING_JS
+ifndef JS_STANDALONE
 DEHYDRA_MODULES = \
   $(topsrcdir)/xpcom/analysis/final.js \
   $(topsrcdir)/xpcom/analysis/must-override.js \
   $(NULL)
 
 TREEHYDRA_MODULES = \
   $(topsrcdir)/xpcom/analysis/outparams.js \
   $(topsrcdir)/xpcom/analysis/stack.js \
--- a/js/src/configure.in
+++ b/js/src/configure.in
@@ -162,17 +162,16 @@ if test "$JS_STANDALONE" = no; then
   autoconfmk=autoconf-js.mk
   JS_STANDALONE=
 else
   JS_STANDALONE=1
   AC_DEFINE(JS_STANDALONE)
 fi
 AC_SUBST(JS_STANDALONE)
 BUILDING_JS=1
-AC_SUBST(BUILDING_JS)
 AC_SUBST(autoconfmk)
 
 MOZ_ARG_WITH_STRING(gonk,
 [  --with-gonk=DIR
                location of gonk dir],
     gonkdir=$withval)
 
 MOZ_ARG_WITH_STRING(gonk-toolchain-prefix,