Properly respect the PKG_CONFIG environment variable.

This will in turn be used in the future to have a sysroot-aware pkg-config
wrapper. For now if the variable is unset, simply fall back to good old
'pkg-config'.

BUG=none
TEST=build without modified ebuild.

Change-Id: I73174857337a4cf67d4061e9fe87110d896a4f34
Reviewed-on: http://gerrit.chromium.org/gerrit/908
Reviewed-by: David James <davidjames@chromium.org>
Reviewed-by: Darin Petkov <petkov@chromium.org>
Tested-by: David James <davidjames@chromium.org>
diff --git a/SConstruct b/SConstruct
index c6d357d..10c8654 100644
--- a/SConstruct
+++ b/SConstruct
@@ -220,7 +220,9 @@
   if os.environ.has_key(key):
     env['ENV'][key] = os.environ[key]
 
-env.ParseConfig('pkg-config --cflags --libs '
+pkgconfig = os.environ.get('PKG_CONFIG', 'pkg-config')
+
+env.ParseConfig(pkgconfig + ' --cflags --libs '
                 'dbus-1 dbus-glib-1 gio-2.0 gio-unix-2.0 glib-2.0')
 env.ProtocolBuffer('update_metadata.pb.cc', 'update_metadata.proto')
 env.PublicKey('unittest_key.pub.pem', 'unittest_key.pem')