APKBUILD 1.88 KB
Newer Older
Natanael Copa's avatar
Natanael Copa committed
1 2 3
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=a52dec
pkgver=0.7.4
Fabian Affolter's avatar
Fabian Affolter committed
4 5
pkgrel=6
pkgdesc="A free library for decoding ATSC A/52 streams."
Natanael Copa's avatar
Natanael Copa committed
6
url="http://liba52.sourceforge.net/"
7
arch="all"
Fabian Affolter's avatar
Fabian Affolter committed
8
license="GPL2+"
Natanael Copa's avatar
Natanael Copa committed
9
subpackages="$pkgname-dev $pkgname-doc"
Fabian Affolter's avatar
Fabian Affolter committed
10
depends=""
11
makedepends="autoconf automake libtool linux-headers"
Fabian Affolter's avatar
Fabian Affolter committed
12
source="http://liba52.sourceforge.net/files/a52dec-$pkgver.tar.gz
Natanael Copa's avatar
Natanael Copa committed
13
	automake.patch
Natanael Copa's avatar
Natanael Copa committed
14 15
	$pkgname-$pkgver-build.patch"

Fabian Affolter's avatar
Fabian Affolter committed
16
_builddir="$srcdir"/a52dec-$pkgver
Natanael Copa's avatar
Natanael Copa committed
17
prepare() {
Fabian Affolter's avatar
Fabian Affolter committed
18
	cd "$_builddir"
Natanael Copa's avatar
Natanael Copa committed
19 20 21 22 23
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
24
	update_config_sub || return 1
Natanael Copa's avatar
Natanael Copa committed
25 26 27 28
	libtoolize --force && \
		aclocal && autoconf && automake --add-missing
}

29
build() {
Fabian Affolter's avatar
Fabian Affolter committed
30
	cd "$_builddir"
31 32 33 34
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
Natanael Copa's avatar
Natanael Copa committed
35 36 37
		--enable-shared \
		|| return 1
	make || return 1
38 39 40
}

package() {
Fabian Affolter's avatar
Fabian Affolter committed
41
	cd "$_builddir"
Natanael Copa's avatar
Natanael Copa committed
42 43 44
	make DESTDIR="$pkgdir" install || return 1
	install -m644 liba52/a52_internal.h "$pkgdir"/usr/include/a52dec/ || return 1
}
Fabian Affolter's avatar
Fabian Affolter committed
45

Natanael Copa's avatar
Natanael Copa committed
46
md5sums="caa9f5bc44232dc8aeea773fea56be80  a52dec-0.7.4.tar.gz
Natanael Copa's avatar
Natanael Copa committed
47
8ebfc507f7efa16ec2dcf8f6b11c985d  automake.patch
Natanael Copa's avatar
Natanael Copa committed
48
fa16f224a7dceb7613824380abef0052  a52dec-0.7.4-build.patch"
Natanael Copa's avatar
Natanael Copa committed
49 50 51 52 53 54
sha256sums="a21d724ab3b3933330194353687df82c475b5dfb997513eef4c25de6c865ec33  a52dec-0.7.4.tar.gz
6fd5085dfa857c095f028224918e462fca14d8a179a0b4552d294293dc76e475  automake.patch
00a094d6178cd21bfc2303ff2ac91ce656810e6fef50e77ab30e18d0f4d4a650  a52dec-0.7.4-build.patch"
sha512sums="4b26fe9492f218b775fb190b76ecf06edaeb656adfe6dcbd24d0a0f86871c3ba917edb88a398eb12dccedaa1605b6f0a0be06b09f9fddd9a46e457b7dd244848  a52dec-0.7.4.tar.gz
4a832b7e13e19ba00b1fcf5ddbdcca416ee71818f2fd77f19114d7f98fb41dbd04f906eb78f403dc27324d7e8bd8ec4e0b670139a27b49a7acdb2e3cf88d8d12  automake.patch
eee40a2871c00fc704fa49d3192a41ceadc4cf7e80d7d7cf368aa2a3e7ebb786f39ef835bdffca5685bf054316a9bacf87556b9a0c90868dbf29e7269873806e  a52dec-0.7.4-build.patch"