From e12f1b43c4d2a79f476db5876135a3bfb3905043 Mon Sep 17 00:00:00 2001 From: Dinar Valeev Date: Tue, 10 Mar 2015 11:58:08 +0100 Subject: [PATCH] Pass threads option to obs-build Currently --jobs sets only -smp flag for VM, in some cases we want to pass threads as well. So the command line would like -smp 4,threads=4 Signed-off-by: Dinar Valeev --- osc/build.py | 2 ++ osc/commandline.py | 2 ++ 2 files changed, 4 insertions(+) diff --git a/osc/build.py b/osc/build.py index 1ea8d2d0..eea25ac3 100644 --- a/osc/build.py +++ b/osc/build.py @@ -444,6 +444,8 @@ def main(apiurl, opts, argv): build_root = opts.root if opts.target: buildargs.append('--target=%s' % opts.target) + if opts.threads: + buildargs.append('--threads=%s' % opts.threads) if opts.jobs: buildargs.append('--jobs=%s' % opts.jobs) elif config['build-jobs'] > 1: diff --git a/osc/commandline.py b/osc/commandline.py index c8222ef5..a296f870 100644 --- a/osc/commandline.py +++ b/osc/commandline.py @@ -5527,6 +5527,8 @@ Please submit there instead, or use --nodevelproject to force direct submission. help='Build in specified directory') @cmdln.option('-j', '--jobs', metavar='N', help='Compile with N jobs') + @cmdln.option('-t', '--threads', metavar='N', + help='Compile with N threads') @cmdln.option('--icecream', metavar='N', help='use N parallel build jobs with icecream') @cmdln.option('--ccache', action='store_true',