aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-03-21 14:47:27 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-03-21 14:47:29 +0000
commit450b4a00895ed1f9396a8ff859dc1cc0eccc838f (patch)
tree2704fbdc26d5067e1866d3e757147bf4223e3bff
parent282a3d618b565a60b8734ca0fb710db93023b5c8 (diff)
downloadbitbake-contrib-450b4a00895ed1f9396a8ff859dc1cc0eccc838f.tar.gz
fetch2: Rename __BBSEENSRCREV -> __BBSRCREV_SEEN
For readability of following patches, rename this internal variable to allow for others in a similar format. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/fetch2/__init__.py2
-rw-r--r--lib/bb/fetch2/git.py2
-rw-r--r--lib/bb/tests/fetch.py8
3 files changed, 6 insertions, 6 deletions
diff --git a/lib/bb/fetch2/__init__.py b/lib/bb/fetch2/__init__.py
index cf65727a2..3b96849a2 100644
--- a/lib/bb/fetch2/__init__.py
+++ b/lib/bb/fetch2/__init__.py
@@ -769,7 +769,7 @@ def get_srcrev(d, method_name='sortable_revision'):
that fetcher provides a method with the given name and the same signature as sortable_revision.
"""
- d.setVar("__BBSEENSRCREV", "1")
+ d.setVar("__BBSRCREV_SEEN", "1")
recursion = d.getVar("__BBINSRCREV")
if recursion:
raise FetchError("There are recursive references in fetcher variables, likely through SRC_URI")
diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py
index 5bb839313..66c2a7e54 100644
--- a/lib/bb/fetch2/git.py
+++ b/lib/bb/fetch2/git.py
@@ -733,7 +733,7 @@ class Git(FetchMethod):
"""
Compute the HEAD revision for the url
"""
- if not d.getVar("__BBSEENSRCREV"):
+ if not d.getVar("__BBSRCREV_SEEN"):
raise bb.fetch2.FetchError("Recipe uses a floating tag/branch '%s' for repo '%s' without a fixed SRCREV yet doesn't call bb.fetch2.get_srcrev() (use SRCPV in PV for OE)." % (ud.unresolvedrev[name], ud.host+ud.path))
# Ensure we mark as not cached
diff --git a/lib/bb/tests/fetch.py b/lib/bb/tests/fetch.py
index 1533d52b1..2e5b404d9 100644
--- a/lib/bb/tests/fetch.py
+++ b/lib/bb/tests/fetch.py
@@ -785,7 +785,7 @@ class FetcherLocalTest(FetcherTest):
# Fetch and check revision
self.d.setVar("SRCREV", "AUTOINC")
- self.d.setVar("__BBSEENSRCREV", "1")
+ self.d.setVar("__BBSRCREV_SEEN", "1")
url = "git://" + self.gitdir + ";branch=master;protocol=file;" + suffix
fetcher = bb.fetch.Fetch([url], self.d)
fetcher.download()
@@ -1654,7 +1654,7 @@ class GitShallowTest(FetcherTest):
self.d.setVar('BB_GIT_SHALLOW', '1')
self.d.setVar('BB_GENERATE_MIRROR_TARBALLS', '0')
self.d.setVar('BB_GENERATE_SHALLOW_TARBALLS', '1')
- self.d.setVar("__BBSEENSRCREV", "1")
+ self.d.setVar("__BBSRCREV_SEEN", "1")
def assertRefs(self, expected_refs, cwd=None):
if cwd is None:
@@ -2218,7 +2218,7 @@ class GitLfsTest(FetcherTest):
self.d.setVar('SRCREV', '${AUTOREV}')
self.d.setVar('AUTOREV', '${@bb.fetch2.get_autorev(d)}')
- self.d.setVar("__BBSEENSRCREV", "1")
+ self.d.setVar("__BBSRCREV_SEEN", "1")
bb.utils.mkdirhier(self.srcdir)
self.git_init(cwd=self.srcdir)
@@ -2936,7 +2936,7 @@ class GitSharedTest(FetcherTest):
super(GitSharedTest, self).setUp()
self.recipe_url = "git://git.openembedded.org/bitbake;branch=master"
self.d.setVar('SRCREV', '82ea737a0b42a8b53e11c9cde141e9e9c0bd8c40')
- self.d.setVar("__BBSEENSRCREV", "1")
+ self.d.setVar("__BBSRCREV_SEEN", "1")
@skipIfNoNetwork()
def test_shared_unpack(self):