[oe-commits] Tom Rini : perl-native: Mangle scripts to use /usr/bin/env perl
git version control
git at git.openembedded.org
Sun Nov 21 14:56:17 UTC 2010
Module: openembedded.git
Branch: release-2010.12
Commit: 4aad95f081fb53182616dcb3cb3b6514de08e452
URL: http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=4aad95f081fb53182616dcb3cb3b6514de08e452
Author: Tom Rini <tom_rini at mentor.com>
Date: Sun Nov 21 07:46:44 2010 -0700
perl-native: Mangle scripts to use /usr/bin/env perl
Signed-off-by: Tom Rini <tom_rini at mentor.com>
---
recipes/perl/perl-native_5.10.1.bb | 8 +++++++-
recipes/perl/perl-native_5.8.8.bb | 7 ++++++-
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/recipes/perl/perl-native_5.10.1.bb b/recipes/perl/perl-native_5.10.1.bb
index b5e8bf4..61d57f4 100644
--- a/recipes/perl/perl-native_5.10.1.bb
+++ b/recipes/perl/perl-native_5.10.1.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "http://www.perl.org/"
SECTION = "libs"
LICENSE = "Artistic|GPLv1+"
DEPENDS = "virtual/db-native gdbm-native"
-PR = "r5"
+PR = "r6"
NATIVE_INSTALL_WORKS = "1"
# Not tested enough
@@ -103,7 +103,13 @@ do_install() {
# Fix Errno.pm for target builds
sed -i -r "s,^\tdie\ (\"Errno\ architecture.+)$,\twarn\ \1," ${D}${libdir}/perl/${PV}/Errno.pm
+
+ # Make sure we use /usr/bin/env perl
+ for PERLSCRIPT in `grep -rIl ${bindir}/perl ${D}${bindir}`; do
+ sed -i -e 's|^#!${bindir}/perl|#!/usr/bin/env perl|' $PERLSCRIPT
+ done
}
+
do_install_append_nylon() {
# get rid of definitions not supported by the gcc version we use for nylon...
for i in ${D}${libdir}/perl/${PV}/Config_heavy.pl ${D}${libdir}/perl/config.sh; do
diff --git a/recipes/perl/perl-native_5.8.8.bb b/recipes/perl/perl-native_5.8.8.bb
index b265e58..dbff4c5 100644
--- a/recipes/perl/perl-native_5.8.8.bb
+++ b/recipes/perl/perl-native_5.8.8.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "http://www.perl.org/"
SECTION = "libs"
LICENSE = "Artistic|GPLv1+"
DEPENDS = "virtual/db-native gdbm-native"
-PR = "r20"
+PR = "r21"
NATIVE_INSTALL_WORKS = "1"
FILESDIR = "${@os.path.dirname(bb.data.getVar('FILE',d,1))}/perl-${PV}"
@@ -94,6 +94,11 @@ do_install() {
# Make sure CPAN is configured
sed -e "s, at SYSROOTBASE@,${base_prefix}," ${WORKDIR}/CPAN-Config.pm > \
${D}${libdir}/perl/${PV}/CPAN/Config.pm
+
+ # Make sure we use /usr/bin/env perl
+ for PERLSCRIPT in `grep -rIl ${bindir}/perl ${D}${bindir}`; do
+ sed -i -e 's|^#!${bindir}/perl|#!/usr/bin/env perl|' $PERLSCRIPT
+ done
}
do_install_append_nylon() {
More information about the Openembedded-commits
mailing list