diff options
Diffstat (limited to 'meta')
-rw-r--r-- | meta/recipes-devtools/perl/perl-native_5.12.3.bb | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/meta/recipes-devtools/perl/perl-native_5.12.3.bb b/meta/recipes-devtools/perl/perl-native_5.12.3.bb index 63f7e13e01..945ebd4ba1 100644 --- a/meta/recipes-devtools/perl/perl-native_5.12.3.bb +++ b/meta/recipes-devtools/perl/perl-native_5.12.3.bb | |||
@@ -4,7 +4,7 @@ SECTION = "libs" | |||
4 | LICENSE = "Artistic|GPL" | 4 | LICENSE = "Artistic|GPL" |
5 | LIC_FILES_CHKSUM = "file://Copying;md5=2b4c6ffbcfcbdee469f02565f253d81a \ | 5 | LIC_FILES_CHKSUM = "file://Copying;md5=2b4c6ffbcfcbdee469f02565f253d81a \ |
6 | file://Artistic;md5=f921793d03cc6d63ec4b15e9be8fd3f8" | 6 | file://Artistic;md5=f921793d03cc6d63ec4b15e9be8fd3f8" |
7 | PR = "r3" | 7 | PR = "r4" |
8 | 8 | ||
9 | LIC_FILES_CHKSUM = "file://Copying;md5=2b4c6ffbcfcbdee469f02565f253d81a \ | 9 | LIC_FILES_CHKSUM = "file://Copying;md5=2b4c6ffbcfcbdee469f02565f253d81a \ |
10 | file://Artistic;md5=f921793d03cc6d63ec4b15e9be8fd3f8" | 10 | file://Artistic;md5=f921793d03cc6d63ec4b15e9be8fd3f8" |
@@ -102,3 +102,18 @@ do_install () { | |||
102 | create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/' | 102 | create_wrapper ${D}${bindir}/perl PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/' |
103 | create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/' | 103 | create_wrapper ${D}${bindir}/perl${PV} PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl/${PV}:${STAGING_LIBDIR}/perl/' |
104 | } | 104 | } |
105 | |||
106 | SYSROOT_PREPROCESS_FUNCS += "perl_sysroot_create_wrapper" | ||
107 | |||
108 | perl_sysroot_create_wrapper () { | ||
109 | mkdir -p ${SYSROOT_DESTDIR}${bindir} | ||
110 | # Create a wrapper that /usr/bin/env perl will use to get perl-native. | ||
111 | # This MUST live in the normal bindir. | ||
112 | cat > ${SYSROOT_DESTDIR}${bindir}/../nativeperl << EOF | ||
113 | #!/bin/sh | ||
114 | realpath=\`readlink -fn \$0\` | ||
115 | exec \`dirname \$realpath\`/perl-native/perl "\$@" | ||
116 | EOF | ||
117 | chmod 0755 ${SYSROOT_DESTDIR}${bindir}/../nativeperl | ||
118 | cat ${SYSROOT_DESTDIR}${bindir}/../nativeperl | ||
119 | } | ||