summaryrefslogtreecommitdiffstats
path: root/source-builder/sb/options.py
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2016-03-10 16:19:58 +1100
committerChris Johns <chrisj@rtems.org>2016-03-10 16:32:49 +1100
commitd3fa1581091bed9d66e5a071be76ce5830a8a6c9 (patch)
tree309805ec75f27b9ad18227802a6b62bb8c19228f /source-builder/sb/options.py
parentsb: Fix typo on the urlparse name in download.py (diff)
downloadrtems-source-builder-d3fa1581091bed9d66e5a071be76ce5830a8a6c9.tar.bz2
sb: Add a download option --with-release-url/--without-release-url.
The default without the option is to prepend the release URL to the URL list to download from the RTEMS FTP site first if the RSB is released. This option can force the RTEMS FTP to be tried first when not a release, or you can supply a different URL to download from or you can request no RTEMS URL is tried first. Eg: --with-release-url --with-release-url=file://opt/local/cache --without-release-url Move the RTEMS release URL to the default.mc file. Change the URL to the RTEMS FTP server and do not use the https method of access. The option's with_arg call was cleaned up to make sense. Remove the log's raw output of an extra space. Some download error message formating was cleaned up. Closes #2636.
Diffstat (limited to 'source-builder/sb/options.py')
-rw-r--r--source-builder/sb/options.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/source-builder/sb/options.py b/source-builder/sb/options.py
index cddc880..ba1eff0 100644
--- a/source-builder/sb/options.py
+++ b/source-builder/sb/options.py
@@ -460,7 +460,9 @@ class command_line:
return None
return self.parse_args(arg)
- def with_arg(self, label):
+ def with_arg(self, label, default = 'not-found'):
+ # the default if there is no option for without.
+ result = default
for pre in ['with', 'without']:
arg_str = '--%s-%s' % (pre, label)
arg_label = '%s_%s' % (pre, label)
@@ -471,10 +473,6 @@ class command_line:
else:
result = arg[1]
break
- if pre == 'with':
- result = 'yes'
- else:
- result = 'no'
return [arg_label, result]
def get_config_files(self, config):