diff options
author | Gennaro Iorio <gen.iorio92@gmail.com> | 2022-09-13 04:26:38 -1000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-09-16 17:53:22 +0100 |
commit | 43e98fb4551fe728be3544e982ac70f4056d49e9 (patch) | |
tree | 2e7805bc7e370c8fe623b6eaf172bcd10985ae8d /bitbake/lib | |
parent | e3fd45f0cfbf15a89a1a5367f5001624fd9f722c (diff) | |
download | poky-43e98fb4551fe728be3544e982ac70f4056d49e9.tar.gz |
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: d828cd2a16ddf4f084e61ffe44471483e132653a)
Signed-off-by: Gennaro Iorio <gennaro.iorio@schindler.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 4a0bd3bcd1f7fc25364df8bbf185ff64881c015b)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r-- | bitbake/lib/bb/fetch2/gitsm.py | 2 |
1 files changed, 1 insertions, 1 deletions
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): | |||
88 | subrevision[m] = module_hash.split()[2] | 88 | subrevision[m] = module_hash.split()[2] |
89 | 89 | ||
90 | # Convert relative to absolute uri based on parent uri | 90 | # Convert relative to absolute uri based on parent uri |
91 | if uris[m].startswith('..'): | 91 | if uris[m].startswith('..') or uris[m].startswith('./'): |
92 | newud = copy.copy(ud) | 92 | newud = copy.copy(ud) |
93 | newud.path = os.path.realpath(os.path.join(newud.path, uris[m])) | 93 | newud.path = os.path.realpath(os.path.join(newud.path, uris[m])) |
94 | uris[m] = Git._get_repo_url(self, newud) | 94 | uris[m] = Git._get_repo_url(self, newud) |