diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-09-29 14:56:11 +0200 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-10-06 17:01:09 +0100 |
| commit | d8cfc4aa41cb1fe7e9495f38e869fafdfb02049d (patch) | |
| tree | d58d2164c1e50c2ab07dd2927b95a25b19c24c99 | |
| parent | 665aacdd14b70736019ddf0ec8321a7fbb82b66d (diff) | |
| download | poky-d8cfc4aa41cb1fe7e9495f38e869fafdfb02049d.tar.gz | |
bitbake: bitbake-setup: Allow local registry paths
It is useful for bitbake-setup to support local paths without access through
the fetcher so that internal data to the bitbake repository can be used as
a default.
(Bitbake rev: 5b8cd9d2156ef6bdd4c6e61130fadc0ff85f7f1f)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rwxr-xr-x | bitbake/bin/bitbake-setup | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/bitbake/bin/bitbake-setup b/bitbake/bin/bitbake-setup index d6509500d8..b07bf2eb7c 100755 --- a/bitbake/bin/bitbake-setup +++ b/bitbake/bin/bitbake-setup | |||
| @@ -509,10 +509,15 @@ def do_fetch(fetcher, dir): | |||
| 509 | 509 | ||
| 510 | def update_registry(registry, cachedir, d): | 510 | def update_registry(registry, cachedir, d): |
| 511 | registrydir = 'configurations' | 511 | registrydir = 'configurations' |
| 512 | full_registrydir = os.path.join(cachedir, registrydir) | 512 | if registry.startswith("."): |
| 513 | print("Fetching configuration registry\n {}\ninto\n {}".format(registry, full_registrydir)) | 513 | full_registrydir = os.path.join(os.getcwd(), registry, registrydir) |
| 514 | fetcher = bb.fetch.Fetch(["{};destsuffix={}".format(registry, registrydir)], d) | 514 | elif registry.startswith("/"): |
| 515 | do_fetch(fetcher, cachedir) | 515 | full_registrydir = os.path.join(registry, registrydir) |
| 516 | else: | ||
| 517 | full_registrydir = os.path.join(cachedir, registrydir) | ||
| 518 | print("Fetching configuration registry\n {}\ninto\n {}".format(registry, full_registrydir)) | ||
| 519 | fetcher = bb.fetch.Fetch(["{};destsuffix={}".format(registry, registrydir)], d) | ||
| 520 | do_fetch(fetcher, cachedir) | ||
| 516 | return full_registrydir | 521 | return full_registrydir |
| 517 | 522 | ||
| 518 | def has_expired(expiry_date): | 523 | def has_expired(expiry_date): |
