Bug 1191212 - Force a value for PKG_CONFIG when building on automation. r=mshal
authorMike Hommey <mh+mozilla@glandium.org>
Wed, 05 Aug 2015 18:25:31 +0900
changeset 288361 efd7ad55b0dfec368217b5707732e3c04b43268b
parent 288360 d13429f4a69bdd3f57314d03314831d83176722e
child 288362 34a546e5ebe2da6c5b51f393d0fd722ac8add5dd
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmshal
bugs1191212
milestone42.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 1191212 - Force a value for PKG_CONFIG when building on automation. r=mshal When switching between Gtk+3 and Gtk+2, config.cache will contain a PKG_CONFIG that may not be suitable for the build: - after a Gtk+2 build, config.cache will point to the system pkg-config, which doesn't like the pkg-config files in the Gtk+3 tooltool package. - after a Gtk+3 build, config.cache will point to the Gtk+3 tooltool package's pkg-config, which is likely not there in a Gtk+2 build. Setting PKG_CONFIG avoids all config.cache considerations altogether, so set it appropriately for both cases.
build/unix/mozconfig.gtk
--- a/build/unix/mozconfig.gtk
+++ b/build/unix/mozconfig.gtk
@@ -3,26 +3,28 @@ TOOLTOOL_DIR=${TOOLTOOL_DIR:-$topsrcdir}
 # $TOOLTOOL_DIR/gtk3 comes from tooltool, when the tooltool manifest contains it.
 if [ -d "$TOOLTOOL_DIR/gtk3" ]; then
   if [ -z "$PKG_CONFIG_LIBDIR" ]; then
     echo PKG_CONFIG_LIBDIR must be set >&2
     exit 1
   fi
   export PKG_CONFIG_SYSROOT_DIR="$TOOLTOOL_DIR/gtk3"
   export PKG_CONFIG_PATH="$TOOLTOOL_DIR/gtk3/usr/local/lib/pkgconfig"
+  PKG_CONFIG="$TOOLTOOL_DIR/gtk3/usr/local/bin/pkg-config"
   export PATH="$TOOLTOOL_DIR/gtk3/usr/local/bin:${PATH}"
   # Ensure cairo, gdk-pixbuf, etc. are not taken from the system installed packages.
   LDFLAGS="-L$TOOLTOOL_DIR/gtk3/usr/local/lib ${LDFLAGS}"
   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=$TOOLTOOL_DIR/gtk3/usr/local/etc/fonts"
   mk_add_options "export PANGO_SYSCONFDIR=$TOOLTOOL_DIR/gtk3/usr/local/etc"
   mk_add_options "export PANGO_LIBDIR=$TOOLTOOL_DIR/gtk3/usr/local/lib"
   mk_add_options "export GDK_PIXBUF_MODULE_FILE=$TOOLTOOL_DIR/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders.cache"
   mk_add_options "export GDK_PIXBUF_MODULEDIR=$TOOLTOOL_DIR/gtk3/usr/local/lib/gdk-pixbuf-2.0/2.10.0/loaders"
   mk_add_options "export LD_LIBRARY_PATH=$TOOLTOOL_DIR/gtk3/usr/local/lib"
 
   # Until a tooltool with bug 1188571 landed is available everywhere
   $TOOLTOOL_DIR/gtk3/setup.sh
 else
+  PKG_CONFIG=pkg-config
   ac_add_options --enable-default-toolkit=cairo-gtk2
 fi