Bug 1048993 - Use nsinstall from $(topobjdir)/config instead of $(DIST)/bin to avoid races when make wants to reinstall it for some reason. r=mshal
authorMike Hommey <mh+mozilla@glandium.org>
Thu, 07 Aug 2014 02:58:50 +0900
changeset 198220 b5abd8d46814c064db71a22a1bc9020e7ce0f940
parent 198219 5bdf577bf6e0b1e7d60abc01f306dfeca26c7505
child 198221 5bf969f77c3de125f00c3d64d62c1adc16a8501a
push id27264
push usernigelbabu@gmail.com
push dateThu, 07 Aug 2014 03:31:37 +0000
treeherdermozilla-central@afcb3af79d09 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmshal
bugs1048993
milestone34.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 1048993 - Use nsinstall from $(topobjdir)/config instead of $(DIST)/bin to avoid races when make wants to reinstall it for some reason. r=mshal
config/config.mk
config/rules.mk
security/build/Makefile.in
--- a/config/config.mk
+++ b/config/config.mk
@@ -662,17 +662,17 @@ NSINSTALL_PY := $(PYTHON) $(abspath $(to
 NSINSTALL_NATIVECMD := %nsinstall nsinstall
 
 ifdef NSINSTALL_BIN
 NSINSTALL = $(NSINSTALL_BIN)
 else
 ifeq ($(HOST_OS_ARCH),WINNT)
 NSINSTALL = $(NSINSTALL_PY)
 else
-NSINSTALL = $(DIST)/bin/nsinstall$(HOST_BIN_SUFFIX)
+NSINSTALL = $(DEPTH)/config/nsinstall$(HOST_BIN_SUFFIX)
 endif # WINNT
 endif # NSINSTALL_BIN
 
 
 ifeq (,$(CROSS_COMPILE)$(filter-out WINNT, $(OS_ARCH)))
 INSTALL = $(NSINSTALL) -t
 
 else
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -1428,19 +1428,19 @@ endif
 # which the files and executables are installed. Default is "libs".
 #
 # Finally, a FOO_KEEP_PATH variable may be set to 1 to indicate the paths given
 # in FOO_FILES/FOO_EXECUTABLES are to be kept at the destination. That is,
 # if FOO_FILES is bar/baz/qux.h, and FOO_DEST is $(DIST)/include, the installed
 # file would be $(DIST)/include/bar/baz/qux.h instead of $(DIST)/include/qux.h
 
 # If we're using binary nsinstall and it's not built yet, fallback to python nsinstall.
-ifneq (,$(filter $(DIST)/bin/nsinstall$(HOST_BIN_SUFFIX),$(install_cmd)))
-ifeq (,$(wildcard $(DIST)/bin/nsinstall$(HOST_BIN_SUFFIX)))
-nsinstall_is_usable = $(if $(wildcard $(DIST)/bin/nsinstall$(HOST_BIN_SUFFIX)),yes)
+ifneq (,$(filter $(DEPTH)/config/nsinstall$(HOST_BIN_SUFFIX),$(install_cmd)))
+ifeq (,$(wildcard $(DEPTH)/config/nsinstall$(HOST_BIN_SUFFIX)))
+nsinstall_is_usable = $(if $(wildcard $(DEPTH)/config/nsinstall$(HOST_BIN_SUFFIX)),yes)
 
 define install_cmd_override
 $(1): install_cmd = $$(if $$(nsinstall_is_usable),$$(INSTALL),$$(NSINSTALL_PY) -t) $$(1)
 endef
 endif
 endif
 
 install_target_tier = $(or $($(1)_TARGET),libs)
--- a/security/build/Makefile.in
+++ b/security/build/Makefile.in
@@ -422,17 +422,17 @@ else
 $(NSS_DIST_DLL_FILES) $(NSS_SDK_LIB_FILES): libs-nss/lib
 endif # MOZ_FOLD_LIBS
 
 ifeq ($(NSINSTALL_PY),$(NSINSTALL))
 DEFAULT_GMAKE_FLAGS += PYTHON='$(PYTHON)'
 DEFAULT_GMAKE_FLAGS += NSINSTALL_PY='$(abspath $(topsrcdir)/config/nsinstall.py)'
 DEFAULT_GMAKE_FLAGS += NSINSTALL='$$(PYTHON) $$(NSINSTALL_PY)'
 else
-DEFAULT_GMAKE_FLAGS += NSINSTALL='$(NSINSTALL)'
+DEFAULT_GMAKE_FLAGS += NSINSTALL='$(abspath $(NSINSTALL))'
 endif
 ifeq ($(OS_ARCH),WINNT)
 DEFAULT_GMAKE_FLAGS += INSTALL='$$(NSINSTALL) -t'
 endif
 DEFAULT_GMAKE_FLAGS += $(EXTRA_GMAKE_FLAGS)
 
 $(addprefix libs-,$(NSS_DIRS)): libs-%:
 # Work around NSS's export rule being racy when recursing for private_export