bug 750728 - move graphite from libxul to libgkmedias on windows, to help with PGO problems. r=khuey a=ehsan to land on a CLOSED TREE
authorJonathan Kew <jkew@mozilla.com>
Tue, 01 May 2012 20:00:35 +0100
changeset 92809 83ff77ce8d6c12673604d5b44fc4e9477e2a89b3
parent 92808 e1f1d4f79b2dab2f8ba438b632812b23a3f26f2f
child 92810 c3813fbb1c9ad69bfd007c0b4554cac0d912cda3
push id8885
push userjkew@mozilla.com
push dateTue, 01 May 2012 19:01:35 +0000
treeherdermozilla-inbound@83ff77ce8d6c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskhuey, ehsan
bugs750728
milestone15.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 750728 - move graphite from libxul to libgkmedias on windows, to help with PGO problems. r=khuey a=ehsan to land on a CLOSED TREE
configure.in
gfx/graphite2/src/Makefile.in
layout/media/Makefile.in
toolkit/library/Makefile.in
--- a/configure.in
+++ b/configure.in
@@ -4605,17 +4605,17 @@ NSS_DISABLE_DBM=
 NECKO_WIFI=1
 NECKO_COOKIES=1
 NECKO_PROTOCOLS_DEFAULT="about data file ftp http res viewsource websocket wyciwyg device"
 USE_ARM_KUSER=
 BUILD_CTYPES=1
 MOZ_USE_NATIVE_POPUP_WINDOWS=
 MOZ_ANDROID_HISTORY=
 MOZ_WEBSMS_BACKEND=
-MOZ_GRAPHITE=
+MOZ_GRAPHITE=1
 ACCESSIBILITY=1
 
 case "$target_os" in
     mingw*)
         NS_ENABLE_TSF=1
         AC_DEFINE(NS_ENABLE_TSF)
         ;;
 esac
--- a/gfx/graphite2/src/Makefile.in
+++ b/gfx/graphite2/src/Makefile.in
@@ -51,39 +51,49 @@ else
 _MACHINE = call
 endif
 
 # get the lists of source files and exported headers
 include $(srcdir)/files.mk
 
 MODULE         = graphite2
 LIBRARY_NAME   = mozgraphite2
+
+# on Windows, we're going to link graphite with gkmedias instead of libxul
+ifeq (WINNT,$(OS_TARGET))
+VISIBILITY_FLAGS =
+else
 LIBXUL_LIBRARY = 1
+endif
 
 # MSVC doesn't like the paths in _SOURCES, so strip off the prefix
 # and leave bare filenames
 CPPSRCS = $(subst $($(_NS)_BASE)/src/,,$(_SOURCES))
 
 EXPORTS_NAMESPACES = graphite2
 EXPORTS_graphite2 = $(_PUBLIC_HEADERS)
 
 FORCE_STATIC_LIB = 1
 FORCE_USE_PIC = 1
 
+ifeq (WINNT,$(OS_TARGET))
+DEFINES += -DGRAPHITE2_EXPORTING
+else
+# tell graphite2 not to export symbols, we'll be linking it directly with thebes
+DEFINES += -DGRAPHITE2_STATIC
+endif
+
 include $(topsrcdir)/config/rules.mk
 
 DEFINES += -DPACKAGE_VERSION="\"moz\""
 DEFINES += -DPACKAGE_BUGREPORT="\"http://bugzilla.mozilla.org/\""
 
 # disable features we don't need in the graphite2 code, to reduce code size
 DEFINES += -DGRAPHITE2_NFILEFACE -DGRAPHITE2_NTRACING -DGRAPHITE2_NSEGCACHE
 
-# tell graphite2 not to export symbols, we'll be linking it directly with thebes
-DEFINES += -DGRAPHITE2_STATIC
-
 # provide a custom header that overrides malloc() and friends,
 # to ensure safe OOM handling
 DEFINES += -DGRAPHITE2_CUSTOM_HEADER="\"MozGrMalloc.h\""
 
 # Filter out -pedantic so that direct_machine.cpp can use computed goto
 CXXFLAGS := $(filter-out -pedantic,$(CXXFLAGS))
 CFLAGS := $(filter-out -pedantic,$(CFLAGS))
 
--- a/layout/media/Makefile.in
+++ b/layout/media/Makefile.in
@@ -46,16 +46,20 @@ MODULE		= layout
 LIBRARY_NAME	= gkmedias
 EXPORT_LIBRARY	= $(DIST)/lib
 ifeq (WINNT,$(OS_TARGET))
 FORCE_SHARED_LIB = 1
 endif
 
 SHARED_LIBRARY_LIBS = $(MOZ_OTS_LIBS)
 
+ifdef MOZ_GRAPHITE
+SHARED_LIBRARY_LIBS += $(MOZ_GRAPHITE_LIBS)
+endif
+
 ifdef MOZ_VORBIS
 SHARED_LIBRARY_LIBS 	+= \
 	$(DEPTH)/media/libvorbis/lib/$(LIB_PREFIX)vorbis.$(LIB_SUFFIX) \
 	$(DEPTH)/media/libogg/src/$(LIB_PREFIX)ogg.$(LIB_SUFFIX) \
 	$(NULL)
 endif
 
 ifdef MOZ_TREMOR
--- a/toolkit/library/Makefile.in
+++ b/toolkit/library/Makefile.in
@@ -339,20 +339,16 @@ EXTRA_DSO_LDOPTS += \
   $(MOZ_JS_LIBS) \
   $(NSS_LIBS) \
   $(MOZ_CAIRO_LIBS) \
   $(MOZ_HARFBUZZ_LIBS) \
   $(MOZ_APP_EXTRA_LIBS) \
   $(SQLITE_LIBS) \
   $(NULL)
 
-ifdef MOZ_GRAPHITE
-EXTRA_DSO_LDOPTS += $(MOZ_GRAPHITE_LIBS)
-endif
-
 ifdef MOZ_NATIVE_ZLIB
 EXTRA_DSO_LDOPTS += $(ZLIB_LIBS)
 else
 EXTRA_DSO_LDOPTS += $(MOZ_ZLIB_LIBS)
 endif
 
 ifdef MOZ_NATIVE_HUNSPELL
 EXTRA_DSO_LDOPTS += $(MOZ_HUNSPELL_LIBS)