APKBUILD 1.59 KB
Newer Older
1
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
2
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
Carlo Landmeter's avatar
Carlo Landmeter committed
3
pkgname=libpng
4
pkgver=1.5.17
5
pkgrel=0
Carlo Landmeter's avatar
Carlo Landmeter committed
6 7
pkgdesc="Portable Network Graphics library"
url="http://www.libpng.org/"
8
arch="all"
Carlo Landmeter's avatar
Carlo Landmeter committed
9
license="GPL"
10
depends=
11 12
depends_dev="zlib-dev"
makedepends="$depends_dev gawk"
Carlo Landmeter's avatar
Carlo Landmeter committed
13
subpackages="$pkgname-doc $pkgname-dev"
14
source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
15
	http://downloads.sourceforge.net/project/libpng-apng/libpng15/$pkgver/libpng-$pkgver-apng.patch.gz
16 17 18 19 20 21 22 23
	"

_builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	cd "$_builddir"
	gunzip -c "$srcdir"/libpng-$pkgver-apng.patch.gz | patch -p1 || return 1
}
24

Carlo Landmeter's avatar
Carlo Landmeter committed
25
build() {
26
	cd "$_builddir"
27 28 29 30
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
31
		|| return 1
32 33 34 35 36
	make
}

package() {
	cd "$srcdir/$pkgname-$pkgver"
Carlo Landmeter's avatar
Carlo Landmeter committed
37
	make DESTDIR="$pkgdir" install
38
	install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE || return 1
39
	rm -f "$pkgdir"/usr/lib/*.la
Carlo Landmeter's avatar
Carlo Landmeter committed
40 41
}

42 43 44 45 46 47
md5sums="d2e27dbd8c6579d1582b3f128fd284b4  libpng-1.5.17.tar.gz
878deb6149c5d9b7ab68f63ce3b9c2cc  libpng-1.5.17-apng.patch.gz"
sha256sums="f37ea62cb79713ac327c0f2555160dddc547afdf1fd052e7f648f1bac0819470  libpng-1.5.17.tar.gz
3f09f15cc2377dec84c7d2ff8111a7652b27a80cb39c03061e6ccb555cb2416b  libpng-1.5.17-apng.patch.gz"
sha512sums="5c1645340244bb8905eef3e810c4b4c4d6ea0216dace7f9e97f52621b337bf1f2452abdbb837d91cae0be42be0bccceeb87e5442d4e6b513d0f22aa86dec5e5d  libpng-1.5.17.tar.gz
1e06389dcd8f94347089c776fdfd19d253e4fb944a2fa326baab1225dcdaea4d9fd52b6ff510dc0eebbdf1e0de9cee0d5f7e1090559e0909e239a0ec09d15780  libpng-1.5.17-apng.patch.gz"