repos: fix path if no url, but path given
The `repo` documentation says: "If the url is missing and the path defined, this entry references the directory the path points to. [...] In case of a relative path name `kas_work_dir` is prepended." But if no `url` is given and a relative path is given in `path`, then the layer paths being added to `bblayer.conf` are missing the `kas_work_dir` prefix. This patch fixes it. Signed-off-by: Silvano Cirujano Cuesta <silvano.cirujano-cuesta@siemens.com> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
parent
87af46ff8c
commit
1f1a21992d
@ -120,6 +120,10 @@ class Repo:
|
||||
path = Repo.get_root_path(repo_fallback_path)
|
||||
logging.info('Using %s as root for repository %s', path,
|
||||
name)
|
||||
else:
|
||||
if not os.path.isabs(path):
|
||||
# Relative pathes are assumed to start from work_dir
|
||||
path = os.path.join(get_context().kas_work_dir, path)
|
||||
|
||||
url = path
|
||||
disable_operations = True
|
||||
|
Loading…
Reference in New Issue
Block a user