summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/autoconf/autoconf.inc
diff options
context:
space:
mode:
authorSerhii Popovych <spopovyc@cisco.com>2017-03-31 11:46:57 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-04-01 23:28:20 +0100
commite44946bff10e04cc52c3871a65830e83ff4a2c41 (patch)
tree29b894573b6baeff6759ddb14000ab1bd998aefd /meta/recipes-devtools/autoconf/autoconf.inc
parent034702f52070c495415db83e18e77fbe6632e54e (diff)
downloadpoky-e44946bff10e04cc52c3871a65830e83ff4a2c41.tar.gz
autoconf: Adjust shebang lines to remove interpreter path hardcode
If build host perl (and other tools) is old and we use some kind of toolchain to provide recent perl/python/etc to the OE build we still locked to use build host perl due to hardcoded shebang lines in autoconf scripts. Behaviour was observed with Enterprise Linux 6 and devtoolset toolchain from SCL (Software Collections) used to provide recent version of perl (not provided with default buildtools-tarball). Pass /usr/bin/env perl in ac_cv_path_PERL configuration variables for class-native and class-nativesdk. Use patch to autoconf to replace -w option in shebang line with modern way to enable warnings on perl (i.e. "use warnings"). Also add nativesdk-m4 and nativesdk-gnu-config to RDEPENDS to bring runtime dependencies inline with other targets. Note that ac_cv_path_PERL must be valid perl interpreter path since configure will check perl version and Flock implementation. It is not possible currently to use nativeperl from native sysroot because autoconf does not DEPENDS on perl-native (and doing so fails due to circular dependencies). Only possible solution is to overwrite shebangs with nativeperl somewhere at do_install() and update RDEPENDS for class-native. Or add perl symlinks to nativeperl in sysroot. For now it seems good to use perl found by /usr/bin/env from autoconf-native. Cc: XE-Linux <xe-linux-external@cisco.com> (From OE-Core rev: 443d2d31732fa5700aa00ff020a0d79ab245c114) Signed-off-by: Serhii Popovych <spopovyc@cisco.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/autoconf/autoconf.inc')
-rw-r--r--meta/recipes-devtools/autoconf/autoconf.inc7
1 files changed, 6 insertions, 1 deletions
diff --git a/meta/recipes-devtools/autoconf/autoconf.inc b/meta/recipes-devtools/autoconf/autoconf.inc
index b4e33569a6..f1b2dfca7a 100644
--- a/meta/recipes-devtools/autoconf/autoconf.inc
+++ b/meta/recipes-devtools/autoconf/autoconf.inc
@@ -27,13 +27,18 @@ RDEPENDS_${PN} = "m4 gnu-config \
27 perl-module-data-dumper \ 27 perl-module-data-dumper \
28 " 28 "
29RDEPENDS_${PN}_class-native = "m4-native gnu-config-native" 29RDEPENDS_${PN}_class-native = "m4-native gnu-config-native"
30RDEPENDS_${PN}_class-nativesdk = "nativesdk-m4 nativesdk-gnu-config"
30 31
31SRC_URI = "${GNU_MIRROR}/autoconf/autoconf-${PV}.tar.gz \ 32SRC_URI = "${GNU_MIRROR}/autoconf/autoconf-${PV}.tar.gz \
32 file://program_prefix.patch" 33 file://program_prefix.patch"
33 34
34inherit autotools texinfo 35inherit autotools texinfo
35 36
36CACHED_CONFIGUREVARS += "ac_cv_path_PERL=${USRBINPATH}/perl" 37PERL = "${USRBINPATH}/perl"
38PERL_class-native = "/usr/bin/env perl"
39PERL_class-nativesdk = "/usr/bin/env perl"
40
41CACHED_CONFIGUREVARS += "ac_cv_path_PERL='${PERL}'"
37 42
38do_configure() { 43do_configure() {
39 oe_runconf 44 oe_runconf