Bug 1187222 - Support building GTK3 in suite/ (mozconfig change) - add TOOL_DIR, r=bustage (post-land-review) a=ewong in a CLOSED TREE
authorEdmund Wong <ewong@pw-wspx.org>
Thu, 30 Jul 2015 21:36:00 +0800
changeset 23004 1e33571d13dcec58c9542193a8d8ca62a277ad87
parent 23003 05239713490311a9af5b722ae6c4aba593d7b89d
child 23005 39abec6d3018de58e1757c88b8d9bcacd27bbb34
push idunknown
push userunknown
push dateunknown
reviewersbustage, ewong
bugs1187222
Bug 1187222 - Support building GTK3 in suite/ (mozconfig change) - add TOOL_DIR, r=bustage (post-land-review) a=ewong in a CLOSED TREE
suite/config/mozconfigs/linux32/debug
suite/config/mozconfigs/linux32/nightly
suite/config/mozconfigs/linux64/nightly
suite/config/mozconfigs/mozconfig.gtk
suite/config/mozconfigs/mozconfig.linux.common
--- a/suite/config/mozconfigs/linux32/debug
+++ b/suite/config/mozconfigs/linux32/debug
@@ -16,10 +16,12 @@ ac_add_options --enable-debug-symbols="-
 mk_add_options PROFILE_GEN_SCRIPT='$(PYTHON) @MOZ_OBJDIR@/_profile/pgo/profileserver.py'
 
 # Needed to enable breakpad in application.ini
 export MOZILLA_OFFICIAL=1
 
 #Use ccache
 ac_add_options --with-ccache=/usr/bin/ccache
 
+. "$topsrcdir/suite/config/mozconfigs/mozconfig.linux.common"
+
 export PKG_CONFIG_LIBDIR=/usr/lib/pkgconfig:/usr/share/pkgconfig
 . "$topsrcdir/mozilla/build/unix/mozconfig.gtk"
--- a/suite/config/mozconfigs/linux32/nightly
+++ b/suite/config/mozconfigs/linux32/nightly
@@ -23,10 +23,12 @@ ac_add_options --enable-debug-symbols="-
 mk_add_options PROFILE_GEN_SCRIPT='$(PYTHON) @MOZ_OBJDIR@/_profile/pgo/profileserver.py'
 
 # Needed to enable breakpad in application.ini
 export MOZILLA_OFFICIAL=1
 
 #Use ccache
 ac_add_options --with-ccache=/usr/bin/ccache
 
+. "$topsrcdir/suite/config/mozconfigs/mozconfig.linux.common"
+
 export PKG_CONFIG_LIBDIR=/usr/lib/pkgconfig:/usr/share/pkgconfig
 . "$topsrcdir/mozilla/build/unix/mozconfig.gtk"
--- a/suite/config/mozconfigs/linux64/nightly
+++ b/suite/config/mozconfigs/linux64/nightly
@@ -24,10 +24,12 @@ ac_add_options --enable-debug-symbols="-
 mk_add_options PROFILE_GEN_SCRIPT='$(PYTHON) @MOZ_OBJDIR@/_profile/pgo/profileserver.py'
 
 # Needed to enable breakpad in application.ini
 export MOZILLA_OFFICIAL=1
 
 #Use ccache
 ac_add_options --with-ccache=/usr/bin/ccache
 
+. "$topsrcdir/suite/config/mozconfigs/mozconfig.linux.common"
+
 export PKG_CONFIG_LIBDIR=/usr/lib64/pkgconfig:/usr/share/pkgconfig
 . "$topsrcdir/mozilla/build/unix/mozconfig.gtk"
deleted file mode 100644
--- a/suite/config/mozconfigs/mozconfig.gtk
+++ /dev/null
@@ -1,48 +0,0 @@
-# $topsrcdir/gtk3 comes from tooltool, when the tooltool manifest contains it.
-if [ -d "$topsrcdir/gtk3" ]; then
-  if [ -z "$PKG_CONFIG_LIBDIR" ]; then
-    echo PKG_CONFIG_LIBDIR must be set >&2
-    exit 1
-  fi
-  export PKG_CONFIG_SYSROOT_DIR="$topsrcdir/gtk3"
-  export PKG_CONFIG_PATH="$topsrcdir/gtk3/usr/local/lib/pkgconfig"
-  export PATH="$topsrcdir/gtk3/usr/local/bin:${PATH}"
-  # Ensure cairo, gdk-pixbuf, etc. are not taken from the system installed packages.
-  LDFLAGS="-L$topsrcdir/gtk3/usr/local/lib ${LDFLAGS}"
-  mk_add_options "export LD_LIBRARY_PATH=$topsrcdir/gtk3/usr/local/lib"
-  ac_add_options --enable-default-toolkit=cairo-gtk3
-
-  # Set things up to use Gtk+3 from the tooltool package
-  mk_add_options "export FONTCONFIG_PATH=$topsrcdir/gtk3/usr/local/etc/fonts"
-  mk_add_options "export PANGO_SYSCONFDIR=$topsrcdir/gtk3/usr/local/etc"
-  mk_add_options "export PANGO_LIBDIR=$topsrcdir/gtk3/usr/local/lib"
-  mk_add_options "export GDK_PIXBUF_MODULE_FILE=$topsrcdir/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache"
-  mk_add_options "export GDK_PIXBUF_MODULEDIR=$topsrcdir/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders"
-  mk_add_options "export LD_LIBRARY_PATH=$topsrcdir/gtk3/usr/local/lib"
-
-  # pango expects absolute paths in pango.modules, and topsrcdir may vary...
-  LD_LIBRARY_PATH=$topsrcdir/gtk3/usr/local/lib \
-  PANGO_SYSCONFDIR=$topsrcdir/gtk3/usr/local/etc \
-  PANGO_LIBDIR=$topsrcdir/gtk3/usr/local/lib \
-  $topsrcdir/gtk3/usr/local/bin/pango-querymodules > $topsrcdir/gtk3/usr/local/etc/pango/pango.modules
-
-  # same with gdb-pixbuf and loaders.cache
-  LD_LIBRARY_PATH=$topsrcdir/gtk3/usr/local/lib \
-  GDK_PIXBUF_MODULE_FILE=$topsrcdir/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache \
-  GDK_PIXBUF_MODULEDIR=$topsrcdir/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders \
-  $topsrcdir/gtk3/usr/local/bin/gdk-pixbuf-query-loaders > $topsrcdir/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache
-
-  # mock build environment doesn't have fonts in /usr/share/fonts, but
-  # has some in /usr/share/X11/fonts. Add this directory to the
-  # fontconfig configuration without changing the gtk3 tooltool package.
-  cat << EOF > $topsrcdir/gtk3/usr/local/etc/fonts/local.conf
-<?xml version="1.0"?>
-<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
-<fontconfig>
-  <dir>/usr/share/X11/fonts</dir>
-</fontconfig>
-EOF
-
-else
-  ac_add_options --enable-default-toolkit=cairo-gtk2
-fi
new file mode 100644
--- /dev/null
+++ b/suite/config/mozconfigs/mozconfig.linux.common
@@ -0,0 +1,3 @@
+# Common statements that are applicable to both Linux32 and Linux64
+
+TOOLTOOL_DIR=${topsrcdir}