identpatch.sh 490 B

123456789101112131415161718
  1. #!/bin/sh
  2. if [ "$#" -ne 1 ]
  3. then
  4. elfdump -n `which elfdump` |awk '/FreeBSD/{print $2}'| head -n1 >elfversion
  5. IDVERSION=`cat elfversion`
  6. rm elfversion
  7. else
  8. IDVERSION=$1
  9. fi
  10. echo Patching cprt0.as with version $IDVERSION
  11. sed -I.sav -es/1201000/$IDVERSION/ cprt0.as
  12. sed -I.sav -es/1201000/$IDVERSION/ dllprt0.as
  13. sed -I.sav -es/1201000/$IDVERSION/ prt0.as
  14. sed -I.sav -es/1201000/$IDVERSION/ gprt0.as
  15. sed -I.sav -es/1201000/$IDVERSION/ si_c.inc
  16. sed -I.sav -es/1201000/$IDVERSION/ si_prc.inc