1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-12-25 17:36:13 +01:00

Add '--buildtool-opt' option passing options to underlying rpmbuild to the 'build' command

This commit is contained in:
Daniel Mach 2023-04-26 09:03:14 +02:00
parent c9c3dd62c0
commit 9f62fce5a4
2 changed files with 5 additions and 0 deletions

View File

@ -1057,6 +1057,9 @@ def main(apiurl, opts, argv):
if opts.build_opt:
buildargs += opts.build_opt
if opts.buildtool_opt:
buildargs += [f"--buildtool-opt={opt}" for opt in opts.buildtool_opt]
# real arch of this machine
# vs.
# arch we are supposed to build for

View File

@ -7012,6 +7012,8 @@ Please submit there instead, or use --nodevelproject to force direct submission.
help='define macro X with value Y')
@cmdln.option('--build-opt', metavar='OPT', action='append',
help='pass option OPT to the build command')
@cmdln.option('--buildtool-opt', metavar='OPT', action='append',
help='pass option OPT to the build tool command (rpmbuild)')
@cmdln.option('--userootforbuild', '--login-as-root', action='store_true',
help='Run build or shell as root. The default is to build as '
'unprivileged user. Note that a line "# norootforbuild" '