mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
46 lines
1.6 KiB
Bash
46 lines
1.6 KiB
Bash
# Maintainer: Alexander Foremny <alexanderforemny@gmail.com>
|
|
# Modified by OpenPogo
|
|
|
|
# toolchain build order: kernel-headers->glibc->binutils->gcc-libs->gcc->binutils->glibc
|
|
|
|
pkgname=binutils
|
|
pkgver=2.19.1
|
|
pkgrel=3
|
|
_date=20090205
|
|
pkgdesc="A set of programs to assemble and manipulate binary and object files"
|
|
arch=('arm')
|
|
url="http://www.gnu.org/software/binutils/"
|
|
license=('GPL')
|
|
groups=('base-devel')
|
|
options=('!libtool' '!distcc' '!ccache')
|
|
depends=('texinfo>=4.13a-3')
|
|
source=(ftp://ftp.archlinux.org/other/${pkgname}/${pkgname}-${pkgver}_${_date}.tar.bz2)
|
|
md5sums=('8fd8a7082814124917289eba9f2b46f1')
|
|
|
|
build() {
|
|
mkdir -p $srcdir/binutils-build
|
|
cd $srcdir/binutils-build
|
|
|
|
CC="gcc -L`pwd`/bfd/.libs/"
|
|
../configure --prefix=/opt \
|
|
--mandir=/opt/share/man --infodir=/opt/share/info \
|
|
--enable-shared || return 1
|
|
|
|
# fix man files install path
|
|
sed -i -e "s:mandir \= \/opt\/share:mandir \= ${pkgdir}\/opt\/share:" ${srcdir}/binutils-build/Makefile || return 1
|
|
|
|
# fix info files install path
|
|
sed -i -e "s:infodir \= \/opt\/share:infodir \= ${pkgdir}\/opt\/share:" ${srcdir}/binutils-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/opt || return 1
|
|
make prefix=${startdir}/pkg/opt tooldir=${startdir}/pkg/opt install
|
|
|
|
install -m 644 ../include/libiberty.h ${startdir}/pkg/opt/include
|
|
|
|
# Remove these symlinks, with binutils prereleases they are not ABI stable.
|
|
# Programs should compile static to the .a file.
|
|
rm -f ${startdir}/pkg/opt/lib/lib{bfd,opcodes}.so
|
|
}
|