Skip to contentSkip to conversation

perl: fix installation failure because of shell issue

PATCH New Dmitry Baryshkov 1 participant 1 message Dec 18, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 perl: fix installation failure because of shell issue

From: Dmitry Baryshkov <[email protected]>

On one of my buildservers I noticed perl do_install failing with the following message:

| rm: cannot remove '<OEROOT>/tmp-rpb-glibc/work/armv8-2a-linaro-linux/perl/5.32.0-r0/image//usr/lib/perl5/5.32.0/*/CORE/libperl.so': No such file or directory

I tracked this down to shell being dash rather than bash not being able to expand this glob in the middle of the filename. So replace the glob expansion with the simpler one which works in all cases.

---
 meta/recipes-devtools/perl/perl_5.30.1.bb | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
meta/recipes-devtools/perl/perl_5.30.1.bb +3 -2
index b53aff12160e..ee6eb6ef0f01 100644
@@ -146,8 +146,9 @@ do_install() {
     install lib/ExtUtils/typemap ${D}${libdir}/perl5/${PV}/ExtUtils/
 
     # Fix up shared library
-    rm ${D}/${libdir}/perl5/${PV}/*/CORE/libperl.so
-    ln -sf ../../../../libperl.so.${PERL_LIB_VER} $(echo ${D}/${libdir}/perl5/${PV}/*/CORE)/libperl.so
+    dir=$(echo ${D}/${libdir}/perl5/${PV}/*/CORE)
+    rm $dir/libperl.so
+    ln -sf ../../../../libperl.so.${PERL_LIB_VER} $dir/libperl.so
 }
 
 do_install_append_class-target() {
Signature · 1 line
2.29.2