diff mbox

[rdma-core,2/4] cbuild: allow envs to pass custom options to rpmbuild

Message ID 1ab960a4-a747-6e3e-17f3-a5f5c41b3669@suse.de (mailing list archive)
State Accepted
Headers show

Commit Message

Nicolas Morey-Chaisemartin Nov. 8, 2017, 2:31 p.m. UTC
Signed-off-by: Nicolas Morey-Chaisemartin <NMoreyChaisemartin@suse.com>
---
 buildlib/cbuild | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/buildlib/cbuild b/buildlib/cbuild
index e6a64e8a..eb5349de 100755
--- a/buildlib/cbuild
+++ b/buildlib/cbuild
@@ -474,7 +474,8 @@  os.symlink({tarfn!r},os.path.join("SOURCES",tarfn));
            tarfn=tarfn,
            tspec_file=tspec_file);
 
-            bopts = ["-bb",tspec_file];
+            extra_opts = getattr(env,"rpmbuild_options", [])
+            bopts = ["-bb",tspec_file] + extra_opts;
 
             print >> F,'os.execlp("rpmbuild","rpmbuild",%s)'%(
                 ",".join(repr(I) for I in bopts));