diff options
author | Simon Glass <sjg@chromium.org> | 2016-07-27 20:33:05 -0600 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2016-07-31 19:37:08 -0600 |
commit | c8785c5b494466066e0a08f9740a6655941ec0c0 (patch) | |
tree | 662b4da1a2be379970590dad532d37720e919020 /tools | |
parent | 7e92e46e630cd7ee60e045e806356fa26567c064 (diff) | |
download | u-boot-c8785c5b494466066e0a08f9740a6655941ec0c0.zip u-boot-c8785c5b494466066e0a08f9740a6655941ec0c0.tar.gz u-boot-c8785c5b494466066e0a08f9740a6655941ec0c0.tar.bz2 |
buildman: Avoid overwriting existing toolchain entries
The current code for setting up the toolchain config always writes the new
paths to an item called 'toolchain'. This means that it will overwrite any
existing toolchain item with the same name. In practice, this means that:
buildman --fetch-arch all
will fetch all toolchains, but only the path of the final one will be added
to the config. This normally works out OK, since most toolchains are the
same version (e.g. gcc 4.9) and will be found on the same path. But it is
not correct and toolchains for archs which don't use the same version will
not function as expected.
Adjust the code to use a complete glob of the toolchain path.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/buildman/toolchain.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tools/buildman/toolchain.py b/tools/buildman/toolchain.py index 02fbeb5..41e4e4c 100644 --- a/tools/buildman/toolchain.py +++ b/tools/buildman/toolchain.py @@ -553,6 +553,5 @@ class Toolchains: if not self.TestSettingsHasPath(dirpath): print ("Adding 'download' to config file '%s'" % bsettings.config_fname) - tools_dir = os.path.dirname(dirpath) - bsettings.SetItem('toolchain', 'download', '%s/*' % tools_dir) + bsettings.SetItem('toolchain', 'download', '%s/*/*' % dest) return 0 |