From: Mark Hatle <mark.ha...@xilinx.com> Externalsrc removes do_fetch, do_unpack, and do_patch. The system normally discovers the correct reproducible date as a postfuncs of do_unpack, so this date is never found, so it falls back to the default epoch.
Instead we can move the discovery function to a prefuncs on the epoch deploy task. This task will run before do_configure, and since the source is already available can run safely at anytime. Signed-off-by: Mark Hatle <mark.ha...@xilinx.com> Signed-off-by: Mark Hatle <mark.ha...@kernel.crashing.org> Signed-off-by: Richard Purdie <richard.pur...@linuxfoundation.org> (cherry picked from commit 0b7dd711a54e92ce54abe99f59fc67e683d52dfe) Signed-off-by: Steve Sakoman <st...@sakoman.com> --- meta/classes/externalsrc.bbclass | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/meta/classes/externalsrc.bbclass b/meta/classes/externalsrc.bbclass index c7fcdca6ef..e94a5cc2af 100644 --- a/meta/classes/externalsrc.bbclass +++ b/meta/classes/externalsrc.bbclass @@ -109,6 +109,16 @@ python () { continue bb.build.deltask(task, d) + if bb.data.inherits_class('reproducible_build', d) and 'do_unpack' in d.getVar("SRCTREECOVEREDTASKS").split(): + # The reproducible_build's create_source_date_epoch_stamp function must + # be run after the source is available and before the + # do_deploy_source_date_epoch task. In the normal case, it's attached + # to do_unpack as a postfuncs, but since we removed do_unpack (above) + # we need to move the function elsewhere. The easiest thing to do is + # move it into the prefuncs of the do_deploy_source_date_epoch task. + # This is safe, as externalsrc runs with the source already unpacked. + d.prependVarFlag('do_deploy_source_date_epoch', 'prefuncs', 'create_source_date_epoch_stamp ') + d.prependVarFlag('do_compile', 'prefuncs', "externalsrc_compile_prefunc ") d.prependVarFlag('do_configure', 'prefuncs', "externalsrc_configure_prefunc ") -- 2.25.1
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#157238): https://lists.openembedded.org/g/openembedded-core/message/157238 Mute This Topic: https://lists.openembedded.org/mt/86449145/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-