Bug 1235676 - Add a global ABS_DIST variable for a non-relative version of DIST, based on topobjdir. r=mshal
authorMike Hommey <mh+mozilla@glandium.org>
Wed, 30 Dec 2015 09:31:29 +0900
changeset 315037 63a73122425a7d7c65c2046b5d4192208bdd1c58
parent 315036 241e21132790a680412ae780900c029571c2878f
child 315038 74f9a758dbc29d460db53d78e6bc67eb396bda69
push id1079
push userjlund@mozilla.com
push dateFri, 15 Apr 2016 21:02:33 +0000
treeherdermozilla-release@575fbf6786d5 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmshal
bugs1235676
milestone46.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 1235676 - Add a global ABS_DIST variable for a non-relative version of DIST, based on topobjdir. r=mshal This replaces multiple local definitions of ABS_DIST.
config/baseconfig.mk
config/external/nspr/Makefile.in
config/external/nss/Makefile.in
toolkit/mozapps/installer/upload-files.mk
--- a/config/baseconfig.mk
+++ b/config/baseconfig.mk
@@ -6,16 +6,17 @@ includedir := $(includedir)/$(MOZ_APP_NA
 idldir = $(datadir)/idl/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
 installdir = $(libdir)/$(MOZ_APP_NAME)-$(MOZ_APP_VERSION)
 sdkdir = $(libdir)/$(MOZ_APP_NAME)-devel-$(MOZ_APP_VERSION)
 ifeq (.,$(DEPTH))
 DIST = dist
 else
 DIST = $(DEPTH)/dist
 endif
+ABS_DIST = $(topobjdir)/dist
 
 # We do magic with OBJ_SUFFIX in config.mk, the following ensures we don't
 # manually use it before config.mk inclusion
 _OBJ_SUFFIX := $(OBJ_SUFFIX)
 OBJ_SUFFIX = $(error config/config.mk needs to be included before using OBJ_SUFFIX)
 
 ifeq ($(HOST_OS_ARCH),WINNT)
 # We only support building with a non-msys gnu make version
--- a/config/external/nspr/Makefile.in
+++ b/config/external/nspr/Makefile.in
@@ -3,17 +3,16 @@
 # 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/.
 
 include $(topsrcdir)/config/rules.mk
 
 ifdef MOZ_BUILD_NSPR
 
 # Copy NSPR to the SDK
-ABS_DIST = $(abspath $(DIST))
 
 ifdef MOZ_FOLD_LIBS
 # Trick the nspr build system into not building shared libraries.
 # bug #851869.
 EXTRA_MAKE_FLAGS := SHARED_LIBRARY= IMPORT_LIBRARY= SHARED_LIB_PDB=
 
 # Work around libVersionPoint conflict between all three libraries.
 # See bug #838566.
--- a/config/external/nss/Makefile.in
+++ b/config/external/nss/Makefile.in
@@ -80,25 +80,16 @@ endif
 ifdef HAVE_FREEBL_LIBS_32INT64
 NSS_EXTRA_DLLS += freebl_32int64_3
 endif
 ifdef HAVE_FREEBL_LIBS_64
 NSS_EXTRA_DLLS += freebl_64int_3
 NSS_EXTRA_DLLS += freebl_64fpu_3
 endif
 
-ABS_DIST := $(abspath $(DIST))
-ifeq ($(HOST_OS_ARCH),WINNT)
-ifdef CYGDRIVE_MOUNT
-ABS_DIST := $(shell cygpath -w $(ABS_DIST) | sed -e 's|\\|/|g')
-endif
-ifneq (,$(filter mingw%,$(host_os)))
-ABS_DIST := $(shell cd $(DIST) && pwd -W)
-endif
-endif
 # For all variables such as DLLFLAGS, that may contain $(DIST)
 DIST := $(ABS_DIST)
 NSPR_INCLUDE_DIR = $(firstword $(filter -I%,$(NSPR_CFLAGS)))
 ifneq (,$(strip $(NSPR_INCLUDE_DIR)))
 NSPR_INCLUDE_DIR := $(subst -I,,$(subst -I$(DIST),-I$(ABS_DIST),$(NSPR_INCLUDE_DIR)))
 else
 NSPR_INCLUDE_DIR = $(ABS_DIST)/include/nspr
 endif
--- a/toolkit/mozapps/installer/upload-files.mk
+++ b/toolkit/mozapps/installer/upload-files.mk
@@ -111,17 +111,17 @@ JSSHELL_BINS += \
   libicui18n.so.$(MOZ_ICU_VERSION) \
   libicuuc.so.$(MOZ_ICU_VERSION) \
   $(NULL)
 endif # Darwin
 endif # WINNT
 endif # MOZ_STATIC_JS
 MAKE_JSSHELL  = $(call py_action,zip,-C $(DIST)/bin $(abspath $(PKG_JSSHELL)) $(JSSHELL_BINS))
 
-_ABS_DIST = $(abspath $(DIST))
+_ABS_DIST = $(ABS_DIST)
 JARLOG_DIR = $(abspath $(DEPTH)/jarlog/)
 JARLOG_FILE_AB_CD = $(JARLOG_DIR)/$(AB_CD).log
 
 TAR_CREATE_FLAGS := --exclude=.mkdir.done $(TAR_CREATE_FLAGS)
 CREATE_FINAL_TAR = $(TAR) -c --owner=0 --group=0 --numeric-owner \
   --mode=go-w --exclude=.mkdir.done -f
 UNPACK_TAR       = tar -xf-