From 4558219ec8584e05c215057c0c271600fa52d6c2 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Wed, 22 Nov 2023 09:35:01 +0000 Subject: package_ipk: Fix Source: field variable dependency The Source: variable is generated from FILE but this is excluded from checksums normally which results in a reproduciubility issue when the filename changes. Add in a dependency by reworking the code a little to avoid this. (From OE-Core rev: 431e6ad7c5b0af3909f5a43599764c529146e6d6) Signed-off-by: Richard Purdie (cherry picked from commit 3ea7da76c6930031a0071069027b1d71f737fbc9) Signed-off-by: Steve Sakoman --- meta/classes-global/package_ipk.bbclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/meta/classes-global/package_ipk.bbclass b/meta/classes-global/package_ipk.bbclass index b4b7bc9ac2..64fa237c00 100644 --- a/meta/classes-global/package_ipk.bbclass +++ b/meta/classes-global/package_ipk.bbclass @@ -47,6 +47,10 @@ python do_package_ipk () { do_package_ipk[vardeps] += "ipk_write_pkg" do_package_ipk[vardepsexclude] = "BB_NUMBER_THREADS" +# FILE isn't included by default but we want the recipe to change if basename() changes +IPK_RECIPE_FILE = "${@os.path.basename(d.getVar('FILE'))}" +IPK_RECIPE_FILE[vardepvalue] = "${IPK_RECIPE_FILE}" + def ipk_write_pkg(pkg, d): import re, copy import subprocess @@ -62,7 +66,7 @@ def ipk_write_pkg(pkg, d): outdir = d.getVar('PKGWRITEDIRIPK') pkgdest = d.getVar('PKGDEST') - recipesource = os.path.basename(d.getVar('FILE')) + recipesource = d.getVar('IPK_RECIPE_FILE') localdata = bb.data.createCopy(d) root = "%s/%s" % (pkgdest, pkg) -- cgit v1.2.3-54-g00ecf