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.6.6
5
_apngver=$pkgver
6
pkgrel=0
Carlo Landmeter's avatar
Carlo Landmeter committed
7 8
pkgdesc="Portable Network Graphics library"
url="http://www.libpng.org/"
9
arch="all"
Carlo Landmeter's avatar
Carlo Landmeter committed
10
license="GPL"
11
depends=
12 13
depends_dev="zlib-dev"
makedepends="$depends_dev gawk"
Carlo Landmeter's avatar
Carlo Landmeter committed
14
subpackages="$pkgname-doc $pkgname-dev"
15
source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
16
	http://downloads.sourceforge.net/sourceforge/libpng-apng/libpng-$_apngver-apng.patch.gz
17 18 19 20 21 22 23 24
	"

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

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

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

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

43 44 45 46 47 48
md5sums="2d8ec4b8251e0a343abda7d38594d557  libpng-1.6.6.tar.gz
8af242769611daf62a8a17349b6059f7  libpng-1.6.6-apng.patch.gz"
sha256sums="1a795068a97e654a897ba4ae4ff928c58fe79d395de81a82580fec1f6e74671d  libpng-1.6.6.tar.gz
d277de7a950da9da01dae0ee24e7921658f8f84dbdfc5c2f5377ea955a31e1c1  libpng-1.6.6-apng.patch.gz"
sha512sums="ae507b18d45a12979d954019fd157f2ac0d90f8b1d73ca04b9afd3d59f741d25d6f65d344aacb963bdb648e51f45aa433b1b40e4590bd572ff961e662bc319ad  libpng-1.6.6.tar.gz
8be5b149f7d87e240e1236c24e105d144b0d57a47aa60dd11e80b5bde715701039fb8ea67af2c58cc8a56de2708b0289169e9bea40f03a8c67e826b63e03e18a  libpng-1.6.6-apng.patch.gz"