1 # hdw - linux toolchain binutils package
3 # author: hackbard@hackdaworld.dyndns.org
7 # [D] binutils-2.16.90.0.3.tar.bz2 http://ftp.kernel.org/pub/linux/devel/binutils/
9 if [ "$priority" = "1" ] ; then
10 confopt="$confopt --disable-nls"
11 # use host system tools
12 hdw_arch_prefix="" ; hdw_cflags=""
13 . ./scripts/optimization
18 if [ "$priority" = "4" ] ; then
21 # install binutils linking against new libc
22 cd $root/tmp/src.binutils/binutils-build
25 rm -rf $root/tmp/src.binutils
27 # show new linker to gcc
28 SPECFILE="`gcc --print-file specs`" &&
29 sed -e "s@/lib/ld.so.1@$prefix/lib/ld.so.1@g" \
30 -e "s@/lib/ld-linux.so.2@$prefix/lib/ld-linux.so.2@g" \
31 $SPECFILE > tempspecfile
32 mv tempspecfile $SPECFILE
34 rm -f $prefix/lib/gcc-lib/*/*/include/pthread.h
35 rm -f $prefix/lib/gcc-lib/*/*/include/bits/sigthread.h
39 if [ "$priority" = "5" ] ; then
40 confopt="$confopt --enable-shared --with-lib-path=$prefix/lib"
41 if [ "$hdw_crossbuild" = "0" ] ; then
42 libpath="/usr/lib:/lib"
44 libpath="$prefix/usr/lib:$prefix/lib"
49 mkdir -p ../binutils-build
51 ../binutils-${ver}/configure $confopt &&
53 make $install_conf install
57 # linkers default library path (where our glibc will go)
59 make -C ld LIB_PATH=$libpath
61 # store binutils tree to reinstall after glibc build
62 cd $root && mkdir -p tmp
63 rm -rf tmp/src.binutils && mv src.binutils tmp/