summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2016-07-19 12:04:12 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-07-20 10:28:53 +0100
commita61eb1f844814daf525d1db250194ea186c35e71 (patch)
tree034fb5992cc6ff70001b0198b6838eb6bbab8eb0 /meta
parentae39c3a0f687b6e23d2726defa8287eacb6f8a79 (diff)
downloadpoky-a61eb1f844814daf525d1db250194ea186c35e71.tar.gz
intltool: remove broken XML::Parser detection
intltool.m4 has a chunk of code that runs during configure which probes for a perl binary and verifies that it has the XML::Parser module. However in builds using intltool-native the perl binary that it finds is likely to not be the one that the intltool scripts will be using as the scripts hardcode nativeperl yet the m4 fragment searches for "perl" in $PATH. If the host perl doesn't have XML::Parser the configure will fail, despite the fact that the scripts will work. Solve this by taking an old patch from the upstream bug system to simply remove the check in intltool.m4 as it's generally useless, and remove existing patches that almost but not quite solved this issue. (From OE-Core rev: 9900000d404b09a701d5368d529eb515e054e3f0) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/intltool/intltool/remove-perl-check.patch42
-rw-r--r--meta/recipes-devtools/intltool/intltool/remove-xml-check.patch33
-rw-r--r--meta/recipes-devtools/intltool/intltool/use-nativeperl.patch20
-rw-r--r--meta/recipes-devtools/intltool/intltool_0.51.0.bb21
4 files changed, 50 insertions, 66 deletions
diff --git a/meta/recipes-devtools/intltool/intltool/remove-perl-check.patch b/meta/recipes-devtools/intltool/intltool/remove-perl-check.patch
new file mode 100644
index 0000000000..bea0895748
--- /dev/null
+++ b/meta/recipes-devtools/intltool/intltool/remove-perl-check.patch
@@ -0,0 +1,42 @@
1Remove the perl checks in intltool.m4. This can find a different perl binary to
2the one that the intltool scripts will actually be using (as they hard-code a
3specific binary), for example in the intltool-native case they'll be using
4nativeperl yet this fragment can find and test the host perl.
5
6This can result in recipes failing in do_configure as intltool.m4 finds a host
7perl which doesn't have XML::Parser installed, despite the fact that intltool
8will work fine as nativeperl has XML::Parser.
9
10Upstream-Status: Submitted (https://bugs.launchpad.net/intltool/+bug/1197875)
11Signed-off-by: Ross Burton <ross.burton@intel.com>
12
13--- a/intltool.m4.orig 2013-07-02 11:22:23.000000000 -0700
14+++ b/intltool.m4 2013-07-02 11:22:32.000000000 -0700
15@@ -131,27 +131,6 @@ if test -z "$xgversion" -o -z "$mmversio
16 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
17 fi
18
19-AC_PATH_PROG(INTLTOOL_PERL, perl)
20-if test -z "$INTLTOOL_PERL"; then
21- AC_MSG_ERROR([perl not found])
22-fi
23-AC_MSG_CHECKING([for perl >= 5.8.1])
24-$INTLTOOL_PERL -e "use 5.8.1;" > /dev/null 2>&1
25-if test $? -ne 0; then
26- AC_MSG_ERROR([perl 5.8.1 is required for intltool])
27-else
28- IT_PERL_VERSION=`$INTLTOOL_PERL -e "printf '%vd', $^V"`
29- AC_MSG_RESULT([$IT_PERL_VERSION])
30-fi
31-if test "x$2" != "xno-xml"; then
32- AC_MSG_CHECKING([for XML::Parser])
33- if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
34- AC_MSG_RESULT([ok])
35- else
36- AC_MSG_ERROR([XML::Parser perl module is required for intltool])
37- fi
38-fi
39-
40 # Substitute ALL_LINGUAS so we can use it in po/Makefile
41 AC_SUBST(ALL_LINGUAS)
42
diff --git a/meta/recipes-devtools/intltool/intltool/remove-xml-check.patch b/meta/recipes-devtools/intltool/intltool/remove-xml-check.patch
deleted file mode 100644
index fc69e37b45..0000000000
--- a/meta/recipes-devtools/intltool/intltool/remove-xml-check.patch
+++ /dev/null
@@ -1,33 +0,0 @@
1Signed-off-by: Florin Sarbu <florin.sarbu@windriver.com>
2
3Upstream-Status: Inappropriate [OE specific]
4
5Index: intltool-0.40.6/intltool.m4
6===================================================================
7--- intltool-0.40.6.orig/intltool.m4 2009-02-14 14:12:28.000000000 -0800
8+++ intltool-0.40.6/intltool.m4 2011-11-23 15:39:34.689561872 -0800
9@@ -122,14 +122,16 @@
10 IT_PERL_VERSION="`$INTLTOOL_PERL -e \"printf '%vd', $^V\"`"
11 AC_MSG_RESULT([$IT_PERL_VERSION])
12 fi
13-if test "x$2" != "xno-xml"; then
14- AC_MSG_CHECKING([for XML::Parser])
15- if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
16- AC_MSG_RESULT([ok])
17- else
18- AC_MSG_ERROR([XML::Parser perl module is required for intltool])
19- fi
20-fi
21+
22+# Disable this check since we know XML::Parser is installed
23+#if test "x$2" != "xno-xml"; then
24+# AC_MSG_CHECKING([for XML::Parser])
25+# if `$INTLTOOL_PERL -e "require XML::Parser" 2>/dev/null`; then
26+# AC_MSG_RESULT([ok])
27+# else
28+# AC_MSG_ERROR([XML::Parser perl module is required for intltool])
29+# fi
30+#fi
31
32 # Substitute ALL_LINGUAS so we can use it in po/Makefile
33 AC_SUBST(ALL_LINGUAS)
diff --git a/meta/recipes-devtools/intltool/intltool/use-nativeperl.patch b/meta/recipes-devtools/intltool/intltool/use-nativeperl.patch
deleted file mode 100644
index 5f5fed3853..0000000000
--- a/meta/recipes-devtools/intltool/intltool/use-nativeperl.patch
+++ /dev/null
@@ -1,20 +0,0 @@
1OE has perl binary as 'nativeperl' in native sysroot so we look for it
2in order to avoid intltool searching and finding perl from /usr/bin
3on build system which may not have all the modules that it needs.
4
5Signed-off-by: Khem Raj <raj.khem@gmail.com>
6
7Upstream-Status: Inappropriate [OE specific]
8Index: intltool-0.40.6/intltool.m4
9===================================================================
10--- intltool-0.40.6.orig/intltool.m4 2009-02-14 14:12:28.000000000 -0800
11+++ intltool-0.40.6/intltool.m4 2011-08-09 08:07:16.427347846 -0700
12@@ -110,7 +110,7 @@
13 AC_MSG_ERROR([GNU gettext tools not found; required for intltool])
14 fi
15
16-AC_PATH_PROG(INTLTOOL_PERL, perl)
17+AC_PATH_PROG(INTLTOOL_PERL, nativeperl)
18 if test -z "$INTLTOOL_PERL"; then
19 AC_MSG_ERROR([perl not found])
20 fi
diff --git a/meta/recipes-devtools/intltool/intltool_0.51.0.bb b/meta/recipes-devtools/intltool/intltool_0.51.0.bb
index 0a610a31f9..a7ea3b727d 100644
--- a/meta/recipes-devtools/intltool/intltool_0.51.0.bb
+++ b/meta/recipes-devtools/intltool/intltool_0.51.0.bb
@@ -6,23 +6,23 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
6SRC_URI = "http://launchpad.net/${BPN}/trunk/${PV}/+download/${BP}.tar.gz \ 6SRC_URI = "http://launchpad.net/${BPN}/trunk/${PV}/+download/${BP}.tar.gz \
7 file://intltool-nowarn.patch \ 7 file://intltool-nowarn.patch \
8 file://perl-522-deprecations.patch \ 8 file://perl-522-deprecations.patch \
9 ${NATIVEPATCHES} \ 9 file://remove-perl-check.patch \
10 file://noperlcheck.patch \
10 " 11 "
11SRC_URI[md5sum] = "12e517cac2b57a0121cda351570f1e63" 12SRC_URI[md5sum] = "12e517cac2b57a0121cda351570f1e63"
12SRC_URI[sha256sum] = "67c74d94196b153b774ab9f89b2fa6c6ba79352407037c8c14d5aeb334e959cd" 13SRC_URI[sha256sum] = "67c74d94196b153b774ab9f89b2fa6c6ba79352407037c8c14d5aeb334e959cd"
13 14
14# All of the intltool scripts have the correct paths to perl already
15# embedded into them and can find perl fine, so we add the remove xml-check
16# in the intltool.m4 via the remove-xml-check.patch
17NATIVEPATCHES = "file://noperlcheck.patch \
18 file://remove-xml-check.patch"
19NATIVEPATCHES_class-native = "file://use-nativeperl.patch"
20
21UPSTREAM_CHECK_URI = "https://launchpad.net/intltool/trunk/" 15UPSTREAM_CHECK_URI = "https://launchpad.net/intltool/trunk/"
22 16
23DEPENDS = "libxml-parser-perl-native" 17DEPENDS = "libxml-parser-perl-native"
24RDEPENDS_${PN} = "gettext-dev libxml-parser-perl" 18RDEPENDS_${PN} = "gettext-dev libxml-parser-perl"
25DEPENDS_class-native = "libxml-parser-perl-native" 19DEPENDS_class-native = "libxml-parser-perl-native"
20
21inherit autotools pkgconfig perlnative
22
23export PERL = "${bindir}/env perl"
24PERL_class-native = "/usr/bin/env nativeperl"
25
26# gettext is assumed to exist on the host 26# gettext is assumed to exist on the host
27RDEPENDS_${PN}_class-native = "libxml-parser-perl-native" 27RDEPENDS_${PN}_class-native = "libxml-parser-perl-native"
28RRECOMMENDS_${PN} = "perl-modules" 28RRECOMMENDS_${PN} = "perl-modules"
@@ -33,9 +33,4 @@ FILES_${PN} += "${datadir}/aclocal"
33 33
34INSANE_SKIP_${PN} += "dev-deps" 34INSANE_SKIP_${PN} += "dev-deps"
35 35
36inherit autotools pkgconfig perlnative
37
38export PERL = "${bindir}/env perl"
39PERL_class-native = "/usr/bin/env nativeperl"
40
41BBCLASSEXTEND = "native" 36BBCLASSEXTEND = "native"