Jelmer Kuperus edited a comment on Bug MRPM-98

As an (admittedly very crude workaround) i did this :

1) mv /opt/local/bin/rpmbuild /opt/local/bin/rpmbuild.orig

2) recreated /opt/local/bin/rpmbuild as :

#!/usr/bin/python

  1. hacky workaround for : http://jira.codehaus.org/browse/MRPM-98?focusedCommentId=312942

import argparse
import subprocess
import sys

parser = argparse.ArgumentParser()

parser.add_argument("-bb", action="")
parser.add_argument("--define", action="", dest="defines", default=[])
parser.add_argument("--buildroot")
parser.add_argument("--target")
parser.add_argument("spec")

args = parser.parse_args()

invokerArgs = ["rpmbuild.orig"]

invokerArgs.append("-bb")

invokerArgs.append("--target")
invokerArgs.append(args.target)

invokerArgs.append("--buildroot")
invokerArgs.append(args.buildroot)

for define in args.defines:
invokerArgs.append("--define")
invokerArgs.append(define)

invokerArgs.append(args.spec)

subprocess.call(invokerArgs)

3) chmod +x /opt/local/bin/rpmbuild

4) Created ~/.popt with the following contents

rpmbuild.orig alias --buildroot --define ".buildroot !#:+"

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
--------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email

Reply via email to