Author: glen                         Date: Tue Apr 15 00:29:18 2008 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- preprocess --target for rpmbuild (args with spaces are  likely broken)

---- Files affected:
SPECS:
   repackage.sh (1.27 -> 1.28) 

---- Diffs:

================================================================
Index: SPECS/repackage.sh
diff -u SPECS/repackage.sh:1.27 SPECS/repackage.sh:1.28
--- SPECS/repackage.sh:1.27     Sat Apr 12 18:45:02 2008
+++ SPECS/repackage.sh  Tue Apr 15 02:29:13 2008
@@ -20,6 +20,21 @@
 set -e
 
 rpmbuild() {
+       # preprocess args, we must have --target as first arg to rpmbuild
+       local a
+       while [ $# -gt 0 ]; do
+               case "$1" in
+               --target)
+                       shift
+                       TARGET=$1
+                       ;;
+               *)
+                       a="$a $1"
+                       ;;
+               esac
+               shift
+       done
+
        # use gz payload as time is what we need here, not compress ratio
 
        # we use %__ldconfig variable to test are we on rpm 4.4.9
@@ -37,7 +52,7 @@
                --define '_binary_payload w9.gzdio' \
                --define '__spec_install_pre %___build_pre' \
                --define '__spec_clean_body %{nil}' \
-               "$@" || exit
+               $a || exit
 }
 
 specdump() {
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/repackage.sh?r1=1.27&r2=1.28&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to