APKBUILD 2 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
A. Klitzing's avatar
A. Klitzing committed
4 5
pkgver=1.6.26
_apngver=1.6.26
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
Carlo Landmeter's avatar
Carlo Landmeter committed
17 18

	libpng-fix-arm-neon.patch
19 20
	"

Carlo Landmeter's avatar
Carlo Landmeter committed
21 22
builddir="$srcdir"/$pkgname-$pkgver

23
prepare() {
Carlo Landmeter's avatar
Carlo Landmeter committed
24
	cd "$builddir"
25
	gunzip -c "$srcdir"/libpng-$_apngver-apng.patch.gz | patch -p1 || return 1
Carlo Landmeter's avatar
Carlo Landmeter committed
26
	default_prepare || return 1
27
}
28

Carlo Landmeter's avatar
Carlo Landmeter committed
29
build() {
Carlo Landmeter's avatar
Carlo Landmeter committed
30
	cd "$builddir"
31 32 33 34
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
35 36 37
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
38
		|| return 1
39
	make || return 1
40 41 42
}

package() {
Carlo Landmeter's avatar
Carlo Landmeter committed
43
	cd "$builddir"
44 45 46
	make DESTDIR="$pkgdir" install || return 1
	install -Dm644 LICENSE \
		"$pkgdir"/usr/share/licenses/$pkgname/LICENSE || return 1
Carlo Landmeter's avatar
Carlo Landmeter committed
47 48
}

A. Klitzing's avatar
A. Klitzing committed
49 50
md5sums="236cd975520fc1f34cc0b8f0e615f7a0  libpng-1.6.26.tar.gz
921d2717418bf74b40b94191c8b282c7  libpng-1.6.26-apng.patch.gz
Carlo Landmeter's avatar
Carlo Landmeter committed
51
e58c8d9a4086999456de13b2c4b9e224  libpng-fix-arm-neon.patch"
A. Klitzing's avatar
A. Klitzing committed
52 53
sha256sums="81bfc8f16ed125622c0c5ad44eeffda19e7a7c7e32f47e43c8932bf32deae7cc  libpng-1.6.26.tar.gz
01dec904d91ee8c90a9a78f253d01d8fac0e37a3f4beacb60e136ea7c814d72c  libpng-1.6.26-apng.patch.gz
Carlo Landmeter's avatar
Carlo Landmeter committed
54
db38cd0a8ae637e1bf2dca464a2068a40576346d16ae929f20dc712d21870316  libpng-fix-arm-neon.patch"
A. Klitzing's avatar
A. Klitzing committed
55 56
sha512sums="e1833fa4e87f5b56890ec697038ba02fc8d3f479c0c56de35813428bcec99d3d85f1823c1d0c14fa1fdfadfbc64a5ad3db52bb6e99f1e86605cdad9f28024386  libpng-1.6.26.tar.gz
e5831b8c5fbe963d6625dd55c656708997d41d9ac91173777560dd7d4a01beaa7a024497d7e428450800b32486ee788baacffbd2317cc0d909fbd89fbbd79684  libpng-1.6.26-apng.patch.gz
Carlo Landmeter's avatar
Carlo Landmeter committed
57
30c8389d075b90c0e30c0be8d7630cbf98c87c610f414c529485630dd0411cced28852d2fecc96bca72bc712f0f7e13358f9fc47b6d7b8c7806d34ebeef20514  libpng-fix-arm-neon.patch"