APKBUILD 1.04 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.5
5
pkgrel=1
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 15 16 17 18 19 20 21 22 23
source="http://downloads.sourceforge.net/$pkgname/$pkgname-$pkgver.tar.gz
	http://downloads.sourceforge.net/project/libpng-apng/libpng-devel/$pkgver/libpng-$pkgver-apng.patch.gz
	"

_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"
Carlo Landmeter's avatar
Carlo Landmeter committed
27
	./configure --prefix=/usr \
28
		|| return 1
29 30 31 32 33
	make
}

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

39 40
md5sums="003bcac022125029bae4818d74c42a94  libpng-1.5.5.tar.gz
4c4e8c1b5beacc3e0cf8caa84489d223  libpng-1.5.5-apng.patch.gz"