summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorJonathan Kotta2017-02-24 16:56:39 -0600
committerJonathan Kotta2017-02-24 16:56:39 -0600
commit8eb587116d07ad20e06697e05d19a2b7faf36374 (patch)
treecd33e49d247da66447319636653a2443eec1d04a /PKGBUILD
parentbd0463ace27803571142bd3a4da33c1cb92d0723 (diff)
downloadaur-avr-libc-atmel.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--PKGBUILD67
1 files changed, 35 insertions, 32 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 77af08ca388..59b6097e7fe 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,46 +1,49 @@
-# Maintainer: Andras Biro <bbandi86@gmail.com>
-# Contributor: Alex Forencich <alex at alexforencich dot com>
+# Maintainer: Jonathan Kotta <jpkotta@gmail.com>
# Contributor: Corrado Primier <bardo@aur.archlinux.org>
# Contributor: danst0 <danst0@west.de>
-_pkgnamenoplatform=libc
-_pkgnamenobrand=avr-${_pkgnamenoplatform}
-pkgname=${_pkgnamenobrand}-atmel
-pkgver=1.8.0
-_atmelver=3.4.4
+
+# Build order: avr-binutils -> avr-gcc -> avr-libc
+
+pkgname=avr-libc-atmel
+pkgver=2.0.0
+_atmelver=3.5.4
pkgrel=1
-pkgdesc="The C runtime library for the AVR family of microcontrollers"
+pkgdesc='The C runtime library for the AVR family of microcontrollers (from Atmel)'
+arch=("i686" "x86_64")
url="http://www.atmel.com/tools/ATMELAVRTOOLCHAINFORLINUX.aspx"
-arch=('x86_64' 'i686')
-license=('BSD' 'custom')
-depends=('avr-gcc-atmel')
+license=("BSD")
+depends=("avr-gcc")
+provides=("avr-libc")
conflicts=("avr-libc")
-provides=("avr-libc=$pkgver")
-options=('!strip' 'staticlibs')
-source=("http://distribute.atmel.no/tools/opensource/Atmel-AVR-GNU-Toolchain/${_atmelver}/${_pkgnamenobrand}-${pkgver}.tar.bz2")
-md5sums=('9afc252d6457957622909af9f197abe8')
+options=(!strip) # it corrupts avr libraries
+_url_base="http://distribute.atmel.no/tools/opensource/Atmel-AVR-GNU-Toolchain/${_atmelver}"
+source=("${_url_base}/avr-libc.tar.bz2" "${_url_base}/avr8-headers.zip")
+sha1sums=('eb77adb21f758635f4927a3f72f443b04cb83f0f'
+ 'fd8b7e7560732d4d55f0b5fc73affd6ea889de8d')
-_dirname="libc/avr-libc"
+prepare() {
+ cd $srcdir
+
+ # headers in avr8-headers are newer
+ cp -f avr/io[0-9a-zA-Z]*.h libc/avr-libc/include/avr/
+}
build() {
- #replace headers - it's not necessary, it's replaced in the tarball already
-# cd ${srcdir}/avr/
-# for i in io[0-9a-zA-Z]*.h
-# do
-# cp --verbose --force $i ../${_dirname}/include/avr
-# done
-
- cd ${srcdir}/${_dirname}
+ cd $srcdir/libc/avr-libc
./bootstrap
- ./configure --host=avr\
- --prefix="/usr" \
- --disable-versioned-doc
+ ./configure \
+ --build=$(./config.guess) \
+ --host=avr \
+ --prefix=/usr \
+ --enable-device-lib
+
make
}
package() {
- cd ${srcdir}/${_dirname}
- make DESTDIR=${pkgdir} install
- install -Dm644 LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/COPYING
-}
+ cd ${srcdir}/libc/avr-libc
-# vim:set ts=2 sw=2 et: \ No newline at end of file
+ make DESTDIR="$pkgdir" install
+
+ install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}