libcamera: Avoid build break in signature recalculation
PATCH 1/1 libcamera: Avoid build break in signature recalculation
The signature recalculation task can fail:
``` /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/temp/run.do_recalculate_ipa_signatures_package.937421: line 154: /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/git/src/ipa/ipa-sign-install.sh: No such file or directory ```
This happens whenever ${S} is removed and packages are retrieved from sstate cache.
Instead of trying to fix the task, avoid the issue altogether by performing the signature recalculation directly in do_package.
--- .../recipes-multimedia/libcamera/libcamera_0.1.0.bb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +5 -2
@@ -50,8 +50,11 @@ do_install:append() { chrpath -d ${D}${libexecdir}/libcamera/v4l2-compat.so } -addtask do_recalculate_ipa_signatures_package after do_package before do_packagedata -do_recalculate_ipa_signatures_package() { +do_package:append() { + bb.build.exec_func("do_package_recalculate_ipa_signatures", d) +} + +do_package_recalculate_ipa_signatures() { local modules for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do module="${module%.sign}"
Signature · 1 line
2.25.1
Quoting Tom Hochstein (2023-10-02 18:36:44)
Quoted 10 lines
The signature recalculation task can fail:
``` /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/temp/run.do_recalculate_ipa_signatures_package.937421: line 154: /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/git/src/ipa/ipa-sign-install.sh: No such file or directory ```This happens whenever ${S} is removed and packages are retrieved from sstate cache.
Instead of trying to fix the task, avoid the issue altogether by performing the signature recalculation directly in
do_package.
Will this still happen after any calls to strip? (i.e. the binaries will not be modified after this step?)
--
Kieran
Quoted 28 lines
Signed-off-by Tom Hochstein <[email protected]>--- .../recipes-multimedia/libcamera/libcamera_0.1.0.bb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +5
-2@@ -50,8 +50,11 @@ do_install:append() { chrpath -d ${D}${libexecdir}/libcamera/v4l2-compat.so } -addtask do_recalculate_ipa_signatures_package after do_package before do_packagedata -do_recalculate_ipa_signatures_package() { +do_package:append() { + bb.build.exec_func("do_package_recalculate_ipa_signatures", d) +} + +do_package_recalculate_ipa_signatures() { local modules for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do module="${module%.sign}"Signature · 1 line
2.25.1
Quoted 20 lines
-----Original Message-----
From: Kieran Bingham <[email protected]>
Sent: Tuesday, October 3, 2023 4:29 AM
To: Tom Hochstein <[email protected]>; openembedded- [email protected]
Cc: Tom Hochstein <[email protected]>
Subject: Re: [meta-multimedia][PATCH] libcamera: Avoid build break in signature recalculationQuoting Tom Hochstein (2023-10-02 18:36:44)
Quoted 3 lines
The signature recalculation task can fail:
``` /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/temp/run.do_recalculate_ipa_signatures_package.937421: line 154:
/.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/git/src/ipa/ipa-sign-install.sh: No such file or directoryQuoted 2 lines
```
Quoted 8 lines
Quoted 5 lines
This happens whenever ${S} is removed and packages are retrieved from sstate cache.
Instead of trying to fix the task, avoid the issue altogether by performing the signature recalculation directly in
do_package.Will this still happen after any calls to strip? (i.e. the binaries will not be modified after this step?)
Yes. The run.do_package script does have the recalculation call as the final line in the do_package function, which is after the call to split_and_strip.
Quoted 36 lines
--
KieranReview
Quoted 7 lines
Signed-off-by Tom Hochstein <[email protected]>--- .../recipes-multimedia/libcamera/libcamera_0.1.0.bb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)(quoted diff) +0
-0multimedia/libcamera/libcamera_0.1.0.bb b/meta-multimedia/recipes- multimedia/libcamera/libcamera_0.1.0.bb
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb do_install:append() { · line 53
Quoted 8 lines
index
ece1be6f3..2a3c6473e100644meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +0
-1@@ -50,8 +50,11 @@ do_install:append() { chrpath -d ${D}${libexecdir}/libcamera/v4l2-compat.so } -addtask do_recalculate_ipa_signatures_package after do_package before
do_packagedataQuoted 13 lines
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +5
-2-do_recalculate_ipa_signatures_package() { +do_package:append() { + bb.build.exec_func("do_package_recalculate_ipa_signatures", d) +} + +do_package_recalculate_ipa_signatures() { local modules for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do module="${module%.sign}" --2.25.1
Kieran Bingham
Acked-byQuoting Tom Hochstein (2023-10-03 14:38:41)
Quoted 26 lines
Quoted 26 lines
-----Original Message-----
From: Kieran Bingham <[email protected]>
Sent: Tuesday, October 3, 2023 4:29 AM
To: Tom Hochstein <[email protected]>; openembedded- [email protected]
Cc: Tom Hochstein <[email protected]>
Subject: Re: [meta-multimedia][PATCH] libcamera: Avoid build break in signature recalculationQuoting Tom Hochstein (2023-10-02 18:36:44)
Quoted 3 lines
The signature recalculation task can fail:
``` /.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/temp/run.do_recalculate_ipa_signatures_package.937421: line 154:
/.../build/tmp/work/armv8a-poky-linux/libcamera/1_0.0.4-r0/git/src/ipa/ipa-sign-install.sh: No such file or directoryQuoted 7 lines
```
This happens whenever ${S} is removed and packages are retrieved from sstate cache.
Instead of trying to fix the task, avoid the issue altogether by performing the signature recalculation directly in
do_package.
Quoted 6 lines
Quoted 2 lines
Will this still happen after any calls to strip? (i.e. the binaries will not be modified after this step?)
Yes. The run.do_package script does have the recalculation call as the final line in the
do_packagefunction, which is after the call tosplit_and_strip.
That settles my worries then! - I'm not sure I'm expert enough on the rest of the yocto syntax, but from libcamera perspective:
Quoted 37 lines
Quoted 37 lines
--
KieranReview
Quoted 7 lines
Signed-off-by Tom Hochstein <[email protected]>--- .../recipes-multimedia/libcamera/libcamera_0.1.0.bb | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)(quoted diff) +0
-0multimedia/libcamera/libcamera_0.1.0.bb b/meta-multimedia/recipes- multimedia/libcamera/libcamera_0.1.0.bb
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb do_install:append() { · line 53
Quoted 8 lines
index
ece1be6f3..2a3c6473e100644meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +0
-1@@ -50,8 +50,11 @@ do_install:append() { chrpath -d ${D}${libexecdir}/libcamera/v4l2-compat.so } -addtask do_recalculate_ipa_signatures_package after do_package before
do_packagedataQuoted 13 lines
meta-multimedia/recipes-multimedia/libcamera/libcamera_0.1.0.bb +5
-2-do_recalculate_ipa_signatures_package() { +do_package:append() { + bb.build.exec_func("do_package_recalculate_ipa_signatures", d) +} + +do_package_recalculate_ipa_signatures() { local modules for module in $(find ${PKGD}/usr/lib/libcamera -name "*.so.sign"); do module="${module%.sign}" --2.25.1