wok-6.x rev 3930
Update: binutils (toolprefixed binaries with default binutil symlinks; needed for builds expecting toolprefixed binutil binaries when a target platform [e.g. i486-pc-linux-gnu] is specified)
author | Matthew Sheets <rcx@zoominternet.net> |
---|---|
date | Wed Aug 19 16:02:07 2009 +0000 (2009-08-19) |
parents | 617322eb9d0d |
children | 9302c4be8d07 |
files | binutils/receipt |
line diff
1.1 --- a/binutils/receipt Wed Aug 19 17:06:01 2009 +0200 1.2 +++ b/binutils/receipt Wed Aug 19 16:02:07 2009 +0000 1.3 @@ -16,8 +16,15 @@ 1.4 # 1.5 compile_rules() 1.6 { 1.7 + # Determine if TOOLPREFIX has been defined in tazwok.conf 1.8 + if [ -z "$TOOLPREFIX" ] ; then 1.9 + # Provide a default value 1.10 + TOOLPREFIX=i486-pc-linux-gnu- 1.11 + fi 1.12 + 1.13 mkdir binutils-build && cd binutils-build 1.14 ../$PACKAGE-$VERSION/configure \ 1.15 + --program-prefix=$TOOLPREFIX \ 1.16 --prefix=/usr \ 1.17 --infodir=/usr/share/info \ 1.18 --mandir=/usr/share/man \ 1.19 @@ -28,7 +35,17 @@ 1.20 # to the source tree. Can't install directly... This is done 1.21 # to keep the $src and $_pkg working for genpkg. 1.22 make tooldir=/usr DESTDIR=$PWD/_pkg install && 1.23 - mv _pkg ../$PACKAGE-$VERSION/ 1.24 + mv _pkg ../$PACKAGE-$VERSION/ && 1.25 + # This is the default binutils, so create symlinks 1.26 + # to the target platform binutil binaries. 1.27 + # Delete duplicate binaries to save space. 1.28 + for binutil in $(ls -1 $src/_pkg/usr/bin/ | grep "${TOOLPREFIX}") ; do 1.29 + genericBinutilPath="$src/_pkg/usr/bin/$(echo "$binutil" | sed "s:$TOOLPREFIX::g")" 1.30 + if [ -e $genericBinutilPath ] ; then 1.31 + rm -f $genericBinutilPath 1.32 + fi 1.33 + ln -s $binutil $genericBinutilPath 1.34 + done 1.35 } 1.36 1.37 # Rules to gen a SliTaz package suitable for Tazpkg. 1.38 @@ -44,5 +61,5 @@ 1.39 1.40 # Remove 'strings' (Busybox). 1.41 #rm $fs/usr/lib/libiberty.a 1.42 - rm $fs/usr/bin/strings 1.43 + rm $fs/usr/bin/strings $fs/usr/bin/*-strings 1.44 }