diff options
author | Jonathan Kotta | 2017-02-24 16:51:33 -0600 |
---|---|---|
committer | Jonathan Kotta | 2017-02-24 16:51:33 -0600 |
commit | eb845be83282049531257a0333a2f7199075fb40 (patch) | |
tree | 68890d3883ee004e8268039f5cd118a3e99d4eaa /PKGBUILD | |
parent | 0cec3ec6af650d6d305de07fa2d2e81bc7aaceea (diff) | |
download | aur-eb845be83282049531257a0333a2f7199075fb40.tar.gz |
update for toolchain 3.5.4
also, trying to follow atmel's build script more closely
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 93 |
1 files changed, 52 insertions, 41 deletions
@@ -1,16 +1,16 @@ -# Maintainer: Andras Biro <bbandi86@gmail.com> +# Maintainer: Jonathan Kotta <jpkotta@gmail.com> +# Contributor: Andras Biro <bbandi86@gmail.com> # Contributor: Alex Forencich <alex at alexforencich dot com> # Contributor: schuay <jakob.gruber@gmail.com> # Contributor: Brad Fanella <bradfanella@archlinux.us> # Contributor: Corrado Primier <bardo@aur.archlinux.org> # Contributor: danst0 <danst0@west.de> -_pkgnamenoplatform=binutils -_pkgnamenobrand=avr-${_pkgnamenoplatform} -pkgname=${_pkgnamenobrand}-atmel -pkgver=2.24 -_atmelver=3.4.4 + +pkgname=avr-binutils-atmel +pkgver=2.26 +_atmelver=3.5.4 pkgrel=1 -pkgdesc="A set of programs to assemble and manipulate binary and object files for the AVR architecture" +pkgdesc="A set of programs to assemble and manipulate binary and object files for the AVR architecture (from Atmel)" url="http://www.atmel.com/tools/ATMELAVRTOOLCHAINFORLINUX.aspx" arch=('x86_64' 'i686') license=('GPL') @@ -18,52 +18,63 @@ depends=('glibc>=2.17' 'zlib') provides=('avr-binutils') conflicts=('avr-binutils') options=('staticlibs' '!distcc' '!ccache') -install=avr-binutils.install -source=("http://distribute.atmel.no/tools/opensource/Atmel-AVR-GNU-Toolchain/${_atmelver}/${_pkgnamenobrand}-${pkgver}.tar.bz2" - "https://stormdragon.tk/patches/atmel-binutils-3.4.4-autotool.patch") -md5sums=('192f39ba0bd76096a09c57a6a0d4bdc5' - '71e7b8a48b41db3be5d37cdcd6d24dfd') +source=("http://distribute.atmel.no/tools/opensource/Atmel-AVR-GNU-Toolchain/${_atmelver}/avr-binutils.tar.bz2") +md5sums=('2929edd12f24c774f90cb109fc45630b') + +_builddir=build + +prepare() { + cd ${srcdir}/binutils -_builddir=binutils-build -build() { - - cd ${srcdir}/${_pkgnamenoplatform} - patch -p1 < ../atmel-binutils-3.4.4-autotool.patch - # https://bugs.archlinux.org/task/34629 sed -i "/ac_cpp=/s/\$CPPFLAGS/\$CPPFLAGS -O2/" libiberty/configure - + rm -rf ${_builddir} - mkdir ${_builddir} && cd ${_builddir} - - CFLAGS="-Os -g0 -s" ${srcdir}/${_pkgnamenoplatform}/configure\ - --prefix=/usr\ - --with-lib-path=/usr/lib:/usr/local/lib \ - --disable-nls\ - --enable-doc\ - --target=avr\ - --disable-werror\ - --enable-install-libiberty\ - --enable-instal-libbfd - - make configure-host - - make tooldir=/usr + mkdir ${_builddir} +} + +build() { + cd ${srcdir}/binutils + + config_guess=$(./config.guess) + + cd ${_builddir} + + # major difference with atmel's build script: + # --enable-install-libiberty + # --enable-install-libbfd + CFLAGS="-Os -g0" ${srcdir}/binutils/configure \ + --prefix=/usr \ + --with-lib-path=/usr/lib:/usr/local/lib \ + --disable-nls \ + --enable-doc \ + --target=avr \ + --build=${config_guess} \ + --host=${config_guess} \ + --disable-werror \ + --disable-gdb \ + --disable-libdecnumber \ + --disable-readline \ + --disable-sim + + make configure-host + + make tooldir=/usr } package() { - cd ${srcdir}/${_pkgnamenoplatform}/${_builddir} - + cd ${srcdir}/binutils/${_builddir} + make prefix=${pkgdir}/usr tooldir=${pkgdir}/usr install - - for bin in ar as nm objcopy objdump ranlib strip ; do + + for bin in ar as nm objcopy objdump ranlib strip readelf ; do rm -f ${pkgdir}/usr/bin/${bin} done - - for info in as bfd binutils configure gprof ld standards; do + + for info in as bfd binutils gprof ld ; do mv ${pkgdir}/usr/share/info/${info}.info ${pkgdir}/usr/share/info/avr-${info}.info done - + rm -rf ${pkgdir}/usr/share/locale } |