diff options
author | Cecil Hugh Watson <knoppmyth@gmail.com> | 2010-09-04 22:51:22 (GMT) |
---|---|---|
committer | Cecil Hugh Watson <knoppmyth@gmail.com> | 2010-09-04 22:51:22 (GMT) |
commit | 85c9e3866b49b924455f6964c6b93c9b104be708 (patch) | |
tree | ccc0f6a379d5850c6c8340b9883c471f8dc27ec4 /abs/core-testing/binutils/PKGBUILD | |
parent | 400b16afef123438f299a04d8ab1bc150f850304 (diff) | |
download | linhes_pkgbuild-85c9e3866b49b924455f6964c6b93c9b104be708.zip linhes_pkgbuild-85c9e3866b49b924455f6964c6b93c9b104be708.tar.gz linhes_pkgbuild-85c9e3866b49b924455f6964c6b93c9b104be708.tar.bz2 |
binutils:Bumped/Updated for LinHES 7.
Diffstat (limited to 'abs/core-testing/binutils/PKGBUILD')
-rw-r--r-- | abs/core-testing/binutils/PKGBUILD | 88 |
1 files changed, 46 insertions, 42 deletions
diff --git a/abs/core-testing/binutils/PKGBUILD b/abs/core-testing/binutils/PKGBUILD index 9a8b925..0ec1438 100644 --- a/abs/core-testing/binutils/PKGBUILD +++ b/abs/core-testing/binutils/PKGBUILD @@ -1,70 +1,74 @@ -# $Id: PKGBUILD 19325 2008-11-20 11:47:00Z andyrtr $ -# Maintainer: Andreas Radke <andyrtr@archlinux.org> +# $Id: PKGBUILD 80784 2010-05-22 08:05:08Z allan $ +# Maintainer: Allan McRae <allan@archlinux.org> -# toolchain build order: kernel-headers->glibc->binutils->gcc-libs->gcc->binutils->glibc +# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc pkgname=binutils -pkgver=2.19 -pkgrel=1 -_date=20081119 +pkgver=2.20.1 +pkgrel=3 +_date=20100521 pkgdesc="A set of programs to assemble and manipulate binary and object files" arch=('i686' 'x86_64') -url="http://sources.redhat.com/binutils" +url="http://www.gnu.org/software/binutils/" license=('GPL') groups=('base') +depends=('glibc>=2.12-1' 'zlib') options=('!libtool' '!distcc' '!ccache') -depends=('glibc>=2.9-1' 'texinfo>=4.12-3') -source=(ftp://ftp.archlinux.org/other/${pkgname}/${pkgname}-${pkgver}_${_date}.tar.bz2) -md5sums=('4a49694b08ef0e5931dba4813326d062') install=binutils.install +source=(ftp://ftp.archlinux.org/other/${pkgname}/${pkgname}-${pkgver}_${_date}.tar.bz2) +md5sums=('67053ffd8582e646e171fccd55b2f0f6') -build() { - # for cvs checkout -# mkdir ${startdir}/src/${pkgname}-${_date} -# cd ${startdir}/src/${pkgname}-${_date} -# export _TAG=binutils-2_19-branch -# export 'CVSROOT=:pserver:anoncvs@sourceware.org:/cvs/src' -# cvs -z9 co -r $_TAG binutils || return 1 -# cd src && tar -cvjf ../../../binutils-2.19_${_date}.tar.bz2 * -# return 1 - - cd ${startdir}/src +mksource() { + mkdir ${pkgname}-${_date} + cd ${pkgname}-${_date} + export _TAG=binutils-2_20-branch + export 'CVSROOT=:pserver:anoncvs@sourceware.org:/cvs/src' + cvs -z9 co -r $_TAG binutils || return 1 + cd src && tar -cvjf ../../binutils-${pkgver}_${_date}.tar.bz2 * +} - mkdir build - cd build +build() { + cd ${srcdir} + mkdir build && cd build CC="gcc -L`pwd`/bfd/.libs/" if [ "${CARCH}" = "x86_64" ]; then - ../configure --prefix=/usr --infodir=/usr/share/info --enable-shared --enable-64-bit-bfd --disable-multilib + ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-64-bit-bfd --disable-multilib else - ../configure --prefix=/usr --infodir=/usr/share/info --enable-shared + ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared fi + # fix man files install path + sed -i -e "s:mandir \= \/usr\/share:mandir \= ${pkgdir}\/usr\/share:" ${srcdir}/build/Makefile || return 1 # fix info files install path sed -i -e "s:infodir \= \/usr\/share:infodir \= ${pkgdir}\/usr\/share:" ${srcdir}/build/Makefile || return 1 # This checks the host environment and makes sure all the necessary tools are available to compile Binutils. make configure-host || return 1 - make tooldir=${startdir}/pkg/usr || return 1 - make prefix=${startdir}/pkg/usr tooldir=${startdir}/pkg/usr install - install -m 644 ../include/libiberty.h ${startdir}/pkg/usr/include + make tooldir=${pkgdir}/usr || return 1 +} - if [ "${CARCH}" = "x86_64" ]; then - # Rebuild libiberty.a with -fPIC - make -C libiberty clean - make CFLAGS="$CFLAGS -fPIC" -C libiberty - install -m 644 libiberty/libiberty.a ${startdir}/pkg/usr/lib - # Rebuild libbfd.a with -fPIC - make -C bfd clean - make CFLAGS="$CFLAGS -fPIC" -C bfd - install -m 644 bfd/libbfd.a ${startdir}/pkg/usr/lib - fi +package() { + cd ${srcdir}/build + make prefix=${pkgdir}/usr tooldir=${pkgdir}/usr install + install -m644 ${srcdir}/include/libiberty.h ${pkgdir}/usr/include - rm -f ${startdir}/pkg/usr/share/man/man1/{dlltool,nlmconv,windres,windmc}* + # Rebuild libiberty.a with -fPIC + make -C libiberty clean + make CFLAGS="$CFLAGS -fPIC" -C libiberty + install -m644 libiberty/libiberty.a ${pkgdir}/usr/lib + + # Rebuild libbfd.a with -fPIC + make -C bfd clean + # hidden visability prevent 3rd party shared libraries exporting bfd non-stable API + make CFLAGS="$CFLAGS -fPIC -fvisibility=hidden" -C bfd + install -m644 bfd/libbfd.a ${pkgdir}/usr/lib + + rm -f ${pkgdir}/usr/share/man/man1/{dlltool,nlmconv,windres,windmc}* # Remove these symlinks, with binutils prereleases they are not ABI stable. # Programs should compile static to the .a file. - rm -f ${startdir}/pkg/usr/lib/lib{bfd,opcodes}.so - - rm -f ${pkgdir}/usr/share/info/dir + rm -f ${pkgdir}/usr/lib/lib{bfd,opcodes}.so + echo "INPUT ( /usr/lib/libbfd.a -liberty -lz )" >${pkgdir}/usr/lib/libbfd.so + echo "INPUT ( /usr/lib/libopcodes.a -lbfd )" >${pkgdir}/usr/lib/libopcodes.so } |