Bug 883339 - Enable gtest on windows TBPL non-PGO builds. r=ted
authorMike Hommey <mh+mozilla@glandium.org>
Thu, 26 Jun 2014 07:59:24 +0900
changeset 190914 87c1ed6a0ed1b598188cefc93c84721c5c3e10ed
parent 190913 df7a27d2bb7e0bf1f3bb369e14da2dd80428671b
child 190915 f4f90287d00a84337ad32878c2e7b6a2fa449b34
push id27019
push usercbook@mozilla.com
push dateThu, 26 Jun 2014 13:33:43 +0000
treeherdermozilla-central@4c9d8c885791 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted
bugs883339
milestone33.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 883339 - Enable gtest on windows TBPL non-PGO builds. r=ted
config/rules.mk
testing/gtest/Makefile.in
toolkit/library/gtest/Makefile.in
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -214,17 +214,17 @@ ifndef GNU_CC
 ifdef SIMPLE_PROGRAMS
 COMPILE_PDB_FLAG ?= -Fd$(basename $(@F)).pdb
 else
 COMPILE_PDB_FLAG ?= -Fdgenerated.pdb
 endif
 COMPILE_CFLAGS += $(COMPILE_PDB_FLAG)
 COMPILE_CXXFLAGS += $(COMPILE_PDB_FLAG)
 
-LINK_PDBFILE = $(basename $(@F)).pdb
+LINK_PDBFILE ?= $(basename $(@F)).pdb
 ifdef MOZ_DEBUG
 CODFILE=$(basename $(@F)).cod
 endif
 
 ifdef DEFFILE
 OS_LDFLAGS += -DEF:$(call normalizepath,$(DEFFILE))
 EXTRA_DEPS += $(DEFFILE)
 endif
--- a/testing/gtest/Makefile.in
+++ b/testing/gtest/Makefile.in
@@ -4,19 +4,17 @@
 
 # Avoid recursive make to avoid having to add files to the gtest/ subdirectory
 # (which is third-party code), and to make the build faster.
 
 include $(topsrcdir)/config/rules.mk
 
 # Bug 1028035: Linking xul-gtest.dll takes too long, so we disable GTest on
 # Windows PGO builds.
-# Bug 1029469: fix_stack_using_bpsyms.py doesn't know how to deal with the
-# second xul.pdb file that linking xul-gtest.dll creates.
-ifeq (WINNT,$(OS_ARCH))
+ifeq (1_WINNT,$(MOZ_PGO)_$(OS_ARCH))
 SKIP_GTEST_DURING_MAKE_CHECK ?= 1
 endif
 
 ifeq (browser,$(MOZ_BUILD_APP))
 ifdef COMPILE_ENVIRONMENT
 gtest::
 	$(MAKE) -C $(DEPTH)/toolkit/library gtestxul
 ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT))
--- a/toolkit/library/gtest/Makefile.in
+++ b/toolkit/library/gtest/Makefile.in
@@ -19,9 +19,11 @@ include $(topsrcdir)/toolkit/library/lib
 
 ifdef COMPILE_ENVIRONMENT
 libs:: $(DIST)/bin/dependentlibs.list.gtest
 endif
 
 $(DIST)/bin/dependentlibs.list.gtest: $(DIST)/bin/dependentlibs.list
 	sed -e 's|$(SHARED_LIBRARY)|gtest/$(SHARED_LIBRARY)|' $< > $@
 
+LINK_PDBFILE = xul-gtest.pdb
+
 endif