# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
setvar pkgname = 'zlib'
setvar pkgver = '1.2.11'
setvar pkgrel = '1'
setvar pkgdesc = ""A compression/decompression Library""
setvar arch = ""all""
setvar license = ""zlib""
setvar url = ""http://zlib.net""
setvar depends = """"
setvar subpackages = ""$pkgname-dev $pkgname-doc""
setvar source = ""http://zlib.net/$pkgname-$pkgver.tar.gz""

setvar builddir = ""$srcdir/$pkgname-$pkgver""

proc build {
	cd $builddir
	# we trade size for a little more speed.
	export CFLAGS="$CFLAGS -O2""
	CHOST=${CHOST}" ./configure \
		--prefix=/usr \
		--libdir=/lib \
		--shared
	make
}

proc check {
	cd $builddir
	make check
}

proc package {
	cd $builddir
	make install \
		pkgconfigdir="/usr/lib/pkgconfig" \
		DESTDIR="$pkgdir"
}

setvar md5sums = ""1c9f62f0778697a09d36121ead88e08e  zlib-1.2.11.tar.gz""
setvar sha256sums = ""c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca1197cb1a1  zlib-1.2.11.tar.gz""
setvar sha512sums = ""73fd3fff4adeccd4894084c15ddac89890cd10ef105dd5e1835e1e9bbb6a49ff229713bd197d203edfa17c2727700fce65a2a235f07568212d820dca88b528ae  zlib-1.2.11.tar.gz""