update.sh revision 33975
138451Smsmith#! /bin/sh
238451Smsmith#
338451Smsmith# This script installs the main files generated by the binutils
438451Smsmith# "configure" scripts and makefiles.  It can be used for upgrading to
538451Smsmith# a new version of binutils.
638451Smsmith#
738451Smsmith# Don't forget to change the VERSION definition in the top level
838451Smsmith# "Makefile.inc0".
938451Smsmith
1038451Smsmithgnudir=$(pwd)
1138451Smsmithcontribdir="${gnudir}/../../../contrib/binutils"
1238451Smsmith
1338451Smsmithrm -rf build
1438451Smsmithmkdir -p build/i386-aout
1538451Smsmith(cd build/i386-aout
1638451Smsmith    ${contribdir}/configure i386-unknown-freebsd || exit
1738451Smsmith    (cd gas
1838451Smsmith	echo "Updating i386-aout/as"
1938451Smsmith	make config.h || exit
2038451Smsmith	cp config.h ${gnudir}/i386-aout/as/config.h || exit
2138451Smsmith	)
2238451Smsmith    )
2338451Smsmith
2438451Smsmithmkdir -p build/i386-elf
2538451Smsmith(cd build/i386-elf
2638451Smsmith    ${contribdir}/configure i386-unknown-freebsdelf || exit
2738451Smsmith    (cd gas
2838451Smsmith	echo "Updating i386-elf/as"
2938451Smsmith	make config.h || exit
3038451Smsmith	cp config.h ${gnudir}/i386-elf/as/config.h || exit
3138451Smsmith	)
3238451Smsmith    (cd ld
3338451Smsmith	echo "Updating i386-elf/ld"
3438451Smsmith	make config.h ldemul-list.h || exit
3538451Smsmith	cp config.h ldemul-list.h ${gnudir}/i386-elf/ld || exit
3638451Smsmith	)
3738451Smsmith    (cd bfd
3838451Smsmith	echo "Updating libbfd"
3938451Smsmith	make bfd.h config.h || exit
4038451Smsmith	cp bfd.h config.h ${gnudir}/libbfd || exit
4138451Smsmith	)
4238451Smsmith    (cd binutils
4338451Smsmith	echo "Updating libbinutils"
4438451Smsmith	make config.h || exit
4538451Smsmith	cp config.h ${gnudir}/libbinutils/config.h || exit
4638451Smsmith	)
4738451Smsmith    )
4838451Smsmith
4938451Smsmithrm -rf build
5038451Smsmith