瀏覽代碼

* allow to set value on cmdline since llvm versions don't work atm.
* also patch gprt0.as

git-svn-id: trunk@35100 -

marco 8 年之前
父節點
當前提交
02e2b8752d
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      rtl/freebsd/i386/identpatch.sh

+ 6 - 0
rtl/freebsd/i386/identpatch.sh

@@ -1,12 +1,18 @@
 #!/bin/sh
 #!/bin/sh
+if [ "$#" -ne 1 ]
+then
 elfdump -n `which elfdump` |awk '/FreeBSD/{print $2}' >elfversion
 elfdump -n `which elfdump` |awk '/FreeBSD/{print $2}' >elfversion
 IDVERSION=`cat elfversion`
 IDVERSION=`cat elfversion`
 rm elfversion
 rm elfversion
+else
+IDVERSION=$1
+fi
 echo Patching cprt0.as with version $IDVERSION
 echo Patching cprt0.as with version $IDVERSION
 
 
 sed -I.sav -es/900044/$IDVERSION/ cprt0.as
 sed -I.sav -es/900044/$IDVERSION/ cprt0.as
 sed -I.sav -es/900044/$IDVERSION/ dllprt0.as
 sed -I.sav -es/900044/$IDVERSION/ dllprt0.as
 sed -I.sav -es/900044/$IDVERSION/ prt0.as
 sed -I.sav -es/900044/$IDVERSION/ prt0.as
+sed -I.sav -es/900044/$IDVERSION/ gprt0.as
 sed -I.sav -es/900044/$IDVERSION/ si_c.inc
 sed -I.sav -es/900044/$IDVERSION/ si_c.inc
 sed -I.sav -es/900044/$IDVERSION/ si_prc.inc
 sed -I.sav -es/900044/$IDVERSION/ si_prc.inc