Bug 1099430, part 二: Define WIN_TOP_SRC using MOZILLA_DIR, r=glandium.
☠☠ backed out by 86a74bc04076 ☠ ☠
authorJoshua Cranmer <Pidgeot18@gmail.com>
Sat, 29 Nov 2014 18:44:14 -0600
changeset 243946 358aa39360d5cc1159d9f0a28d38e131e23d286b
parent 243945 3313e545f4f693145d1a358bb3de0c4ff5d3b0fe
child 243947 28abb8af2d6231adf68dcfd2d84ee84b31f16df3
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1099430
milestone37.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 1099430, part 二: Define WIN_TOP_SRC using MOZILLA_DIR, r=glandium. win_srcdir is used as the Windows path for the srcdir, and so it needs to use comm-central's topsrcdir to work properly. In contrast, WIN_TOP_SRC is really only used to define BUILD_TOOLS, which refers to files in mozilla-central/build, and so that can and should remain the mozilla-central topsrcdir.
config/config.mk
--- a/config/config.mk
+++ b/config/config.mk
@@ -117,21 +117,29 @@ FINAL_TARGET_FROZEN := '$(FINAL_TARGET)'
 ifdef XPI_NAME
 DEFINES += -DXPI_NAME=$(XPI_NAME)
 endif
 
 # The VERSION_NUMBER is suffixed onto the end of the DLLs we ship.
 VERSION_NUMBER		= 50
 
 ifeq ($(HOST_OS_ARCH),WINNT)
-win_srcdir	:= $(subst $(topsrcdir),$(WIN_TOP_SRC),$(srcdir))
-BUILD_TOOLS	= $(WIN_TOP_SRC)/build/unix
+  ifeq ($(MOZILLA_DIR),$(topsrcdir))
+    win_srcdir := $(subst $(topsrcdir),$(WIN_TOP_SRC),$(srcdir))
+  else
+    # This means we're in comm-central's topsrcdir, so we need to adjust
+    # WIN_TOP_SRC (which points to mozilla's topsrcdir) for the substitution
+    # to win_srcdir.
+		cc_WIN_TOP_SRC := $(WIN_TOP_SRC:%/mozilla=%)
+    win_srcdir := $(subst $(topsrcdir),$(cc_WIN_TOP_SRC),$(srcdir))
+  endif
+  BUILD_TOOLS = $(WIN_TOP_SRC)/build/unix
 else
-win_srcdir	:= $(srcdir)
-BUILD_TOOLS	= $(topsrcdir)/build/unix
+  win_srcdir := $(srcdir)
+  BUILD_TOOLS = $(MOZILLA_DIR)/build/unix
 endif
 
 CONFIG_TOOLS	= $(MOZ_BUILD_ROOT)/config
 AUTOCONF_TOOLS	= $(topsrcdir)/build/autoconf
 
 #
 # Strip off the excessively long version numbers on these platforms,
 # but save the version to allow multiple versions of the same base