Skip to contentSkip to conversation

libdbi-perl: fix interpreter on shebang line

PATCH New [email protected] 1 participant 4 messages Jul 4, 2022

lore
Share & tools
lore
#0 lore raw

PATCH 1/4 libdbi-perl: fix interpreter on shebang line

From: Kai Kang <[email protected]>

Update interpreter on shebang line in scripts to fix error:

ERROR: QA Issue: : /work/x86_64-linux/libdbi-perl-native/1.643-r0/sysroot-destdir/work/x86_64-linux/libdbi-perl-native/1.643-r0/recipe-sysroot-native/usr/bin/dbiproxy maximum shebang size exceeded, the maximum size is 128. [shebang-size]
ERROR: QA Issue: : /work/x86_64-linux/libdbi-perl-native/1.643-r0/sysroot-destdir/work/x86_64-linux/libdbi-perl-native/1.643-r0/recipe-sysroot-native/usr/bin/dbiprof maximum shebang size exceeded, the maximum size is 128. [shebang-size]
ERROR: QA Issue: : /work/x86_64-linux/libdbi-perl-native/1.643-r0/sysroot-destdir/work/x86_64-linux/libdbi-perl-native/1.643-r0/recipe-sysroot-native/usr/bin/dbilogstrip maximum shebang size exceeded, the maximum size is 128. [shebang-size]

---
 meta-oe/recipes-devtools/perl/libdbi-perl_1.643.bb | 5 +++++
 1 file changed, 5 insertions(+)
meta-oe/recipes-devtools/perl/libdbi-perl_1.643.bb +5 -0
index 94f98fe40..1fee83a8f 100644
@@ -29,6 +29,11 @@ do_install:prepend() {
 	rm -rf ${B}/t/z*.t
 }
 
+do_install:append() {
+	sed -i "s:^#!.*:#!/usr/bin/env perl:" ${D}${bindir}/dbiproxy \
+		${D}${bindir}/dbiprof ${D}${bindir}/dbilogstrip
+}
+
 RDEPENDS:${PN}:class-target = " \
     perl \
     perl-module-carp \
Signature · 1 line
2.17.1
#1 lore raw

PATCH 2/4 libdev-checklib-perl: fix interpreter of script use-devel-checklib

From: Kai Kang <[email protected]>

Update interpreter on shebang line in script use-devel-checklib to fix QA error:

ERROR: QA Issue: : /work/x86_64-linux/libdev-checklib-perl-native/1.14-r0/sysroot-destdir/ work/x86_64-linux/libdev-checklib-perl-native/1.14-r0/recipe-sysroot-native/usr/bin/use-devel-checklib maximum shebang size exceeded, the maximum size is 128. [shebang-size]

It also replace option '-w' on shebang line with 'use warnings;' that old version env doesn't support multiple arguments.

---
 .../recipes-devtools/perl/libdev-checklib-perl_1.14.bb    | 8 ++++++++
 1 file changed, 8 insertions(+)
meta-oe/recipes-devtools/perl/libdev-checklib-perl_1.14.bb +8 -0
index 6dfff781b..0863bb862 100644
@@ -18,4 +18,12 @@ S = "${WORKDIR}/Devel-CheckLib-${PV}"
 
 inherit cpan
 
+do_install:append() {
+    # update interpreter on shebang line
+    # since old version env doesn't support multiple arguments, replace option
+    # '-w' with 'use warnings;'
+    sed -i -e "s:^#!.*:#!/usr/bin/env perl:" \
+           -e "/use strict;/ause warnings;" ${D}${bindir}/use-devel-checklib
+}
+
 BBCLASSEXTEND="native"
Signature · 1 line
2.17.1
#2 lore raw

PATCH 3/4 libparse-yapp-perl: update interpreter of yapp

In reply to [email protected]

From: Kai Kang <[email protected]>

Update interpreter on shebang line of script yapp to fix qa error:

ERROR: QA Issue: : /work/x86_64-linux/libparse-yapp-perl-native/1.21-r0/sysroot-destdir /work/x86_64-linux/libparse-yapp-perl-native/1.21-r0/recipe-sysroot-native/usr/bin/yapp maximum shebang size exceeded, the maximum size is 128. [shebang-size]

---
 meta-oe/recipes-devtools/perl/libparse-yapp-perl_1.21.bb | 4 ++++
 1 file changed, 4 insertions(+)
meta-oe/recipes-devtools/perl/libparse-yapp-perl_1.21.bb +4 -0
index d7959df66..be9704a31 100644
@@ -18,4 +18,8 @@ S = "${WORKDIR}/Parse-Yapp-${PV}"
 
 inherit cpan
 
+do_install:append() {
+    sed -i "s:^#!.*:#!/usr/bin/env perl:" ${D}${bindir}/yapp
+}
+
 BBCLASSEXTEND = "native"
Signature · 1 line
2.17.1
#3 lore raw

PATCH 4/4 python3-flatbuffer: enable native

In reply to [email protected]

From: Kai Kang <[email protected]>

Native python module of flatbuffer exists before it is split from flatbuffers. So add it back.

---
 .../recipes-devtools/flatbuffers/python3-flatbuffers_2.0.6.bb    | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-devtools/flatbuffers/python3-flatbuffers_2.0.6.bb +1 -0
index cc453da35..7c05e76d9 100644
@@ -13,3 +13,4 @@ RDEPENDS:${PN} = "flatbuffers"
 
 inherit setuptools3
 
+BBCLASSEXTEND = "native"
Signature · 1 line
2.17.1