summaryrefslogtreecommitdiff
path: root/community/dumb/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/dumb/PKGBUILD')
-rw-r--r--community/dumb/PKGBUILD52
1 files changed, 27 insertions, 25 deletions
diff --git a/community/dumb/PKGBUILD b/community/dumb/PKGBUILD
index 2ddfc6153..c30d667a1 100644
--- a/community/dumb/PKGBUILD
+++ b/community/dumb/PKGBUILD
@@ -1,31 +1,35 @@
+# $Id: PKGBUILD 83614 2013-02-03 23:11:33Z arodseth $
+# Maintainer: Alexander Rødseth <rodseth@gmail.com>
# Contributor: Chris Brannon <cmbrannon79@gmail.com>
# Contributor: JJDaNiMoTh <jjdanimoth@gmail.com>
# Contributor: Bjørn Lindeijer <bjorn lindeijer nl>
pkgname=dumb
pkgver=0.9.3
-pkgrel=6
-pkgdesc="An IT, XM, S3M and MOD player library"
-arch=('i686' 'x86_64')
+pkgrel=7
+pkgdesc='IT, XM, S3M and MOD player library'
+arch=('x86_64' 'i686')
license=('custom:dumb' 'GPL')
-url="http://dumb.sourceforge.net/"
+url='http://dumb.sourceforge.net/'
+makedepends=('setconf')
depends=('glibc' 'allegro4')
-source=(http://downloads.sourceforge.net/sourceforge/dumb/$pkgname-$pkgver.tar.gz
- as-needed.patch
- CVE-2006-3668.patch)
-md5sums=('f48da5b990aa8aa822d3b6a951baf5c2'
- '580676387b07d3b5998bbd525df2df52'
- 'e1378e2eb30346073ee188608ac2c9e7')
+source=("http://downloads.sourceforge.net/sourceforge/dumb/$pkgname-$pkgver.tar.gz"
+ 'as-needed.patch'
+ 'CVE-2006-3668.patch')
+sha256sums=('8d44fbc9e57f3bac9f761c3b12ce102d47d717f0dd846657fb988e0bb5d1ea33'
+ 'f7a41576d5dcecad2f9a01cbb0228457b434423046cb67c9a0a720ec87f43fb9'
+ '9f6785435757db725bc73b1c4874b91e80b9277c6fdd2b56e47dae1cfbc968e6')
build() {
cd "$srcdir/$pkgname-$pkgver"
- [ "${CARCH}" = "x86_64" ] && export CFLAGS="${CFLAGS} -fPIC"
- # Fix CVE-2006-3668 (Patch found in Gentoo and other distros).
+ # Add -fPIC for anything but i686
+ [ "$CARCH" = 'i686' ] || export CFLAGS="${CFLAGS} -fPIC"
+
+ # Patch from Gentoo for CVE-2006-3668
patch -p1 < "$srcdir/CVE-2006-3668.patch"
- # Apply a patch from Gentoo, so that we can build against binutils
- # 2.22 and above.
+ # Patch from Gentoo for binutils >= 2.22
patch -p1 < "$srcdir/as-needed.patch"
sed -i '/LDFLAGS :=/d' Makefile
cp Makefile Makefile.rdy
@@ -39,23 +43,21 @@ build() {
include make/unix.inc
ALL_TARGETS := core core-examples core-headers
ALL_TARGETS += allegro allegro-examples allegro-headers
-PREFIX := "$pkgdir/usr"
+PREFIX := /usr
EOF
- # Upstream's makefile ignores our CFLAGS. They put -I directives in
- # their own CFLAGS, so we can't just say
- # make CFLAGS=...
- # Gentoo's ebuild overrides another of their makefile variables, named
- # OFLAGS.
- make OFLAGS="${CFLAGS}"
+ # Use OFLAGS to be able to set CFLAGS without replacing the -I directives
+ make -j1 OFLAGS="${CFLAGS}"
}
package() {
cd "$srcdir/$pkgname-$pkgver"
- # Create directories
+
install -d "$pkgdir"/usr/{lib,bin,include}
- install -D -m644 licence.txt \
+ install -Dm644 licence.txt \
"$pkgdir/usr/share/licenses/$pkgname/licence.txt"
-
- make install
+ setconf make/config.txt PREFIX "$pkgdir/usr"
+ make DESTDIR="$pkgdir" install
}
+
+# vim:set ts=2 sw=2 et: