summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoshua Lock <josh@linux.intel.com>2010-06-22 13:20:08 +0100
committerJoshua Lock <josh@linux.intel.com>2010-06-25 14:58:43 +0100
commite2c567f51e2d1bf769c8e2ea3abd738ce6fa7c0a (patch)
tree8ca4e5b4f1895e4181b633f2d6df78a1ca7cfa45
parent7646f333e14ed2e4f34552544e1428218fd08f3b (diff)
downloadpoky-e2c567f51e2d1bf769c8e2ea3abd738ce6fa7c0a.tar.gz
pkgconfig: add patch to disable legacy scripts such as glib-config
On an F13 host with glib-config installed pkgconfig-native can get into a horrible state with recursive calls between pkg-config and glib-config. The patch adds a configure time option to disable legacy script support in pkgconfig and makes use of the option for Poky. Signed-off-by: Joshua Lock <josh@linux.intel.com>
-rw-r--r--meta/packages/pkgconfig/pkgconfig.inc15
-rw-r--r--meta/packages/pkgconfig/pkgconfig/disable-legacy.patch42
2 files changed, 50 insertions, 7 deletions
diff --git a/meta/packages/pkgconfig/pkgconfig.inc b/meta/packages/pkgconfig/pkgconfig.inc
index 463faf3fad..c64037299e 100644
--- a/meta/packages/pkgconfig/pkgconfig.inc
+++ b/meta/packages/pkgconfig/pkgconfig.inc
@@ -5,19 +5,20 @@ It replaces the ubiquitous *-config scripts you may have \
5seen with a single tool." 5seen with a single tool."
6HOMEPAGE = "http://pkg-config.freedesktop.org/wiki/" 6HOMEPAGE = "http://pkg-config.freedesktop.org/wiki/"
7LICENSE = "GPL" 7LICENSE = "GPL"
8PR = "r7" 8PR = "r8"
9 9
10DEPENDS = "glib-2.0" 10DEPENDS = "glib-2.0"
11DEPENDS_virtclass-native = "" 11DEPENDS_virtclass-native = ""
12DEPENDS_virtclass-nativesdk = "" 12DEPENDS_virtclass-nativesdk = ""
13EXTRA_OECONF = "--with-installed-glib" 13EXTRA_OECONF = "--with-installed-glib --disable-legacy-scripts"
14EXTRA_OECONF_virtclass-native = "" 14EXTRA_OECONF_virtclass-native = "--disable-legacy-scripts"
15EXTRA_OECONF_virtclass-nativesdk = "" 15EXTRA_OECONF_virtclass-nativesdk = "--disable-legacy-scripts"
16 16
17SRC_URI = "http://pkgconfig.freedesktop.org/releases/pkg-config-${PV}.tar.gz \ 17SRC_URI = "http://pkgconfig.freedesktop.org/releases/pkg-config-${PV}.tar.gz \
18 file://autofoo.patch;patch=1 \ 18 file://autofoo.patch \
19 file://sysrootfix.patch;patch=1 \ 19 file://sysrootfix.patch \
20 file://glibconfig-sysdefs.h" 20 file://glibconfig-sysdefs.h \
21 file://disable-legacy.patch"
21 22
22S = "${WORKDIR}/pkg-config-${PV}/" 23S = "${WORKDIR}/pkg-config-${PV}/"
23 24
diff --git a/meta/packages/pkgconfig/pkgconfig/disable-legacy.patch b/meta/packages/pkgconfig/pkgconfig/disable-legacy.patch
new file mode 100644
index 0000000000..fea2d3d501
--- /dev/null
+++ b/meta/packages/pkgconfig/pkgconfig/disable-legacy.patch
@@ -0,0 +1,42 @@
1On an Fedora host with glib-config installed pkgconfig-native can get into a
2horrible state with recursive calls between pkg-config and glib-config.
3The patch adds a configure time option to disable legacy script support in
4pkgconfig with the --disable-legacy-scripts option, to maintain compatibility
5the default is to leave the scripts enabled.
6
7JL - 22/06/10
8Index: pkg-config-0.23/configure.in
9===================================================================
10--- pkg-config-0.23.orig/configure.in 2008-01-16 22:48:07.000000000 +0000
11+++ pkg-config-0.23/configure.in 2010-06-22 13:05:58.951984140 +0100
12@@ -125,6 +125,14 @@
13 AC_CONFIG_SUBDIRS(glib-1.2.10)
14 fi # !native_win32
15
16+# legacy *-configure scripts can cause headaches, add option to disable
17+AC_ARG_ENABLE(legacy-scripts,
18+ [AC_HELP_STRING([--enable-legacy-scripts=@<:@no/yes@:>@],
19+ [Whether pkg-config will try and use legacy scripts such as glib-config and gnome-config @<:@default=yes@:>@])],
20+ [],
21+ [enable_legacy=yes])
22+AM_CONDITIONAL([LEGACY_SCRIPTS], [test x$enable_legacy = xyes])
23+
24 AC_FUNC_ALLOCA
25
26 AC_CHECK_FUNCS(setresuid setreuid,break)
27Index: pkg-config-0.23/parse.c
28===================================================================
29--- pkg-config-0.23.orig/parse.c 2008-01-16 20:42:49.000000000 +0000
30+++ pkg-config-0.23/parse.c 2010-06-22 13:09:10.410129471 +0100
31@@ -1195,6 +1195,11 @@
32 * messages.
33 */
34 return NULL;
35+#elif defined(LEGACY_SCRIPTS)
36+ /* There are scenarios where we might not want to use these legacy
37+ * scripts even if they are available.
38+ */
39+ return NULL;
40 #else
41
42 Package *pkg;