From 241a27ea80968329625463213f76a5c5880a33e8 Mon Sep 17 00:00:00 2001 From: Gennaro Iorio Date: Thu, 30 Jun 2022 19:24:55 +0200 Subject: bitbake: fetch2: gitsm: fix incorrect handling of git submodule relative urls As specified by git submodule manual relative urls can start either with '..' or './', second case was incorrectly managed leading to an interpretation of urls starting with './' as absoulte urls. (Bitbake rev: 4a0bd3bcd1f7fc25364df8bbf185ff64881c015b) Signed-off-by: Gennaro Iorio Signed-off-by: Richard Purdie --- bitbake/lib/bb/fetch2/gitsm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bitbake/lib/bb/fetch2/gitsm.py b/bitbake/lib/bb/fetch2/gitsm.py index c5c23d5260..c1950e4819 100644 --- a/bitbake/lib/bb/fetch2/gitsm.py +++ b/bitbake/lib/bb/fetch2/gitsm.py @@ -88,7 +88,7 @@ class GitSM(Git): subrevision[m] = module_hash.split()[2] # Convert relative to absolute uri based on parent uri - if uris[m].startswith('..'): + if uris[m].startswith('..') or uris[m].startswith('./'): newud = copy.copy(ud) newud.path = os.path.realpath(os.path.join(newud.path, uris[m])) uris[m] = Git._get_repo_url(self, newud) -- cgit v1.2.3-54-g00ecf