aboutsummaryrefslogtreecommitdiffstats
path: root/testing/openjpeg/APKBUILD
blob: a1c34ff9fa06601da83eaf9faefc4bd92beb1a09 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Contributor: William Pitcock <nenolod@dereferenced.org>
# Maintainer:
pkgname=openjpeg
pkgver=1.5.1
pkgrel=1
pkgdesc="Open-source implementation of JPEG2000 image codec"
url="http://www.openjpeg.org/"
arch="all"
license="BSD"
depends=""
depends_dev="pkgconfig"
makedepends="$depends_dev libpng-dev tiff-dev lcms-dev doxygen"
install=""
subpackages="$pkgname-dev"
source="http://$pkgname.googlecode.com/files/$pkgname-$pkgver.tar.gz"

_builddir="${srcdir}/$pkgname-$pkgver"
prepare() {
	local i
	mkdir "$_builddir"
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	./configure \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--disable-static \
		--enable-mj2 \
		--enable-jpwl \
		--enable-jpip \
		|| return 1
	make LDFLAGS="-lm" || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	rm -f "$pkgdir"/usr/lib/*.la
}

md5sums="b5f74cec2688fb918331bb014061be6f  openjpeg-1.5.1.tar.gz"