Unlike vanilla Perl "Configure" script, perl-cross "configure" does not
derive "startperl" from "bin". It instead derives from "perlpath".

This patch aims to fix "startperl" configuration option for perl-native by
correctly setting "perlpath" on perl-cross "configure" script.

It also changes do_install_append_class-native task to comply with
cpan_do_install task.

Signed-off-by: Paulo Cesar Zaneti <paulo.zan...@gmail.com>
---
 meta/recipes-devtools/perl/perl_5.32.1.bb | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-devtools/perl/perl_5.32.1.bb 
b/meta/recipes-devtools/perl/perl_5.32.1.bb
index b28040c7fb..73d66f6656 100644
--- a/meta/recipes-devtools/perl/perl_5.32.1.bb
+++ b/meta/recipes-devtools/perl/perl_5.32.1.bb
@@ -95,6 +95,7 @@ do_configure_class-nativesdk() {
 do_configure_class-native() {
     ./configure --prefix=${prefix} \
     -Dbin=${bindir}/perl-native \
+    -Dperlpath=${bindir}/perl-native/perl \
     -Duseshrplib \
     -Dsoname=libperl.so.5 \
     -Dvendorprefix=${prefix} \
@@ -171,8 +172,8 @@ do_install_append_class-native () {
     create_wrapper ${D}${bindir}/perl-native/perl 
PERL5LIB='$PERL5LIB:${STAGING_LIBDIR}/perl5/site_perl/${PV}:${STAGING_LIBDIR}/perl5/vendor_perl/${PV}:${STAGING_LIBDIR}/perl5/${PV}'
 
     # Use /usr/bin/env nativeperl for the perl script.
-    for f in `grep -Il '#! *${bindir}/perl' ${D}/${bindir}/*`; do
-            sed -i -e 's|${bindir}/perl|/usr/bin/env nativeperl|' $f
+    for f in `grep -Il '#! *${bindir}/perl-native.*/perl' ${D}/${bindir}/*`; do
+            sed -i -e 's|${bindir}/perl-native.*/perl|/usr/bin/env 
nativeperl|' $f
     done
 }
 
-- 
2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#150676): 
https://lists.openembedded.org/g/openembedded-core/message/150676
Mute This Topic: https://lists.openembedded.org/mt/82209004/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to