summaryrefslogtreecommitdiffstats
path: root/meta-selftest
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-08-11 13:52:59 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-08-24 16:50:24 +0100
commit62afa02d01794376efab75623f42e7e08af08526 (patch)
treee713e2ad86aeb3daa677dc62d47b5e9d9402c957 /meta-selftest
parent871a4ac6e7e814242db4f90fc4d8ae92d72d7460 (diff)
downloadpoky-62afa02d01794376efab75623f42e7e08af08526.tar.gz
base/package: Move source revision information from PV to PKGV
Source control information being present in PV used to be a hard requirement for bitbake to operate correctly. Now that hashes are a required part of task stamps, this requirement no longer exists. This means we can defer the hash pieces to PKGV and simplify PV. Use new bitbake fetcher API to inject the source revisions directly into the hash allowing removal of some horrible code from base.bbclass and avoiding any hardcoding about how SRCREV may or may not be used. Use that API to object the string to append to PKGV and append that directly. The user visible effect of this change is that PV will no longer have revision information in it and this will now be appended to PV through PKGV when the packages are written. Since PV is used in STAMP and WORKDIR, users will see small directory naming and stamp naming changes. This will mean that sstate reuse through hash equivalence where the source revision changes but the output does not will become possible as the sstate naming will become less specific and no longer contain the revision. The SRCPV variable will no longer be needed in PV and is effectively now just a null operation. Usage can be removed over time. (From OE-Core rev: a8e7b0f932b9ea69b3a218fca18041676c65aba0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta-selftest')
-rw-r--r--meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline-fail.bb18
-rw-r--r--meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.bb2
-rw-r--r--meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.inc16
3 files changed, 20 insertions, 16 deletions
diff --git a/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline-fail.bb b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline-fail.bb
index 602e895199..5146129666 100644
--- a/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline-fail.bb
+++ b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline-fail.bb
@@ -1,16 +1,4 @@
1SUMMARY = "Test recipe for fetching git submodules" 1require gitunpackoffline.inc
2HOMEPAGE = "https://git.yoctoproject.org/git/matchbox-panel-2"
3LICENSE = "GPL-2.0-or-later"
4LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
5 2
6INHIBIT_DEFAULT_DEPS = "1" 3# Clear the base.bbclass magic srcrev call
7 4fetcher_hashes_dummyfunc[vardepvalue] = ""
8TAGVALUE = "2.10"
9
10# Deliberately have a tag which has to be resolved but ensure do_unpack doesn't access the network again.
11SRC_URI = "git://git.yoctoproject.org/git/matchbox-panel-2;branch=master;protocol=https"
12SRC_URI:append:gitunpack-enable-recipe = ";tag=${TAGVALUE}"
13SRCREV = "f82ca3f42510fb3ef10f598b393eb373a2c34ca7"
14SRCREV:gitunpack-enable-recipe = ""
15
16S = "${WORKDIR}/git"
diff --git a/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.bb b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.bb
index 597c89b199..b051b5da5a 100644
--- a/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.bb
+++ b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.bb
@@ -1,4 +1,4 @@
1require gitunpackoffline-fail.bb 1require gitunpackoffline.inc
2 2
3TAGVALUE = "2.11" 3TAGVALUE = "2.11"
4 4
diff --git a/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.inc b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.inc
new file mode 100644
index 0000000000..602e895199
--- /dev/null
+++ b/meta-selftest/recipes-test/gitunpackoffline/gitunpackoffline.inc
@@ -0,0 +1,16 @@
1SUMMARY = "Test recipe for fetching git submodules"
2HOMEPAGE = "https://git.yoctoproject.org/git/matchbox-panel-2"
3LICENSE = "GPL-2.0-or-later"
4LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
5
6INHIBIT_DEFAULT_DEPS = "1"
7
8TAGVALUE = "2.10"
9
10# Deliberately have a tag which has to be resolved but ensure do_unpack doesn't access the network again.
11SRC_URI = "git://git.yoctoproject.org/git/matchbox-panel-2;branch=master;protocol=https"
12SRC_URI:append:gitunpack-enable-recipe = ";tag=${TAGVALUE}"
13SRCREV = "f82ca3f42510fb3ef10f598b393eb373a2c34ca7"
14SRCREV:gitunpack-enable-recipe = ""
15
16S = "${WORKDIR}/git"