Title: [259867] trunk/Tools
Revision
259867
Author
ab...@igalia.com
Date
2020-04-10 06:17:56 -0700 (Fri, 10 Apr 2020)

Log Message

[Tools] jhbuild should respect PKG_CONFIG_PATH
https://bugs.webkit.org/show_bug.cgi?id=210280

Reviewed by Carlos Alberto Lopez Perez.

Our jhbuildrc adds the system paths to PKG_CONFIG_PATH. This is not
necessary, as they are included implicitly by pkg-config, e.g.

$ mkdir /tmp/empty
$ PKG_CONFIG_PATH=/tmp/empty pkg-config --cflags glib-2.0
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include

Apart from not being necessary, it is problematic because it makes
impossible to override system libraries in jhbuild-wrapper.

$ PKG_CONFIG_PATH=/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig/ jhbuild-wrapper --gtk run bash
/webkit/WebKitBuild/DependenciesGTK/Root/lib64/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/lib/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/share/pkgconfig:/usr/share/pkgconfig:/usr/lib64/pkgconfig:/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig

Note /usr/share/pkgconfig and /usr/lib64/pkgconfig are taking priority
over the user environment.

This patch removes that code, so that the user PKG_CONFIG_PATH takes
priority over the system default paths, while these keep having effect
too as explained before.

$ PKG_CONFIG_PATH=/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig jhbuild-wrapper --gtk run bash
/webkit/WebKitBuild/DependenciesGTK/Root/lib64/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/lib/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/share/pkgconfig:/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig

* jhbuild/jhbuildrc_common.py:
(init):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (259866 => 259867)


--- trunk/Tools/ChangeLog	2020-04-10 12:19:40 UTC (rev 259866)
+++ trunk/Tools/ChangeLog	2020-04-10 13:17:56 UTC (rev 259867)
@@ -1,3 +1,36 @@
+2020-04-10  Alicia Boya GarcĂ­a  <ab...@igalia.com>
+
+        [Tools] jhbuild should respect PKG_CONFIG_PATH
+        https://bugs.webkit.org/show_bug.cgi?id=210280
+
+        Reviewed by Carlos Alberto Lopez Perez.
+
+        Our jhbuildrc adds the system paths to PKG_CONFIG_PATH. This is not
+        necessary, as they are included implicitly by pkg-config, e.g.
+
+        $ mkdir /tmp/empty
+        $ PKG_CONFIG_PATH=/tmp/empty pkg-config --cflags glib-2.0
+        -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include
+
+        Apart from not being necessary, it is problematic because it makes
+        impossible to override system libraries in jhbuild-wrapper.
+
+        $ PKG_CONFIG_PATH=/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig/ jhbuild-wrapper --gtk run bash
+        /webkit/WebKitBuild/DependenciesGTK/Root/lib64/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/lib/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/share/pkgconfig:/usr/share/pkgconfig:/usr/lib64/pkgconfig:/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig
+
+        Note /usr/share/pkgconfig and /usr/lib64/pkgconfig are taking priority
+        over the user environment.
+
+        This patch removes that code, so that the user PKG_CONFIG_PATH takes
+        priority over the system default paths, while these keep having effect
+        too as explained before.
+
+        $ PKG_CONFIG_PATH=/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig jhbuild-wrapper --gtk run bash
+        /webkit/WebKitBuild/DependenciesGTK/Root/lib64/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/lib/pkgconfig:/webkit/WebKitBuild/DependenciesGTK/Root/share/pkgconfig:/home/ntrrgc/Apps/gst-1.10-prefix/lib/pkgconfig
+
+        * jhbuild/jhbuildrc_common.py:
+        (init):
+
 2020-04-10  Philippe Normand  <pnorm...@igalia.com>
 
         [Flatpak SDK] Flatpak build broken when using 'git config core.webkitbranchbuild=true'

Modified: trunk/Tools/jhbuild/jhbuildrc_common.py (259866 => 259867)


--- trunk/Tools/jhbuild/jhbuildrc_common.py	2020-04-10 12:19:40 UTC (rev 259866)
+++ trunk/Tools/jhbuild/jhbuildrc_common.py	2020-04-10 13:17:56 UTC (rev 259867)
@@ -71,12 +71,7 @@
     # to use only the plugins we build in JHBuild.
     os.environ['GST_PLUGIN_SYSTEM_PATH'] = ''
 
-    # Use system libraries while building.
     addpath = jhbuildrc_globals['addpath']
-    system_libdirs = jhbuildrc_globals['system_libdirs']
-    for libdir in system_libdirs:
-        addpath('PKG_CONFIG_PATH', os.path.join(libdir, 'pkgconfig'))
-    addpath('PKG_CONFIG_PATH', os.path.join(os.sep, 'usr', 'share', 'pkgconfig'))
 
     prefix = jhbuildrc_globals['prefix']
     addpath('CMAKE_PREFIX_PATH', prefix)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to