core/zlib/PKGBUILD

59 lines
1.4 KiB
Bash
Raw Normal View History

2016-02-25 21:31:59 +08:00
# Contributions from Arch: https://projects.archlinux.org/svntogit/packages.git/tree/trunk?h=packages/zlib
2010-03-13 23:25:19 +08:00
2017-03-18 02:59:06 +08:00
pkgbase=zlib
pkgname=(zlib minizip)
pkgver=1.2.11
pkgrel=2
2016-02-25 21:31:59 +08:00
arch=('x86_64')
2010-03-13 23:25:19 +08:00
license=('custom')
url="http://www.zlib.net/"
depends=('glibc')
2016-02-25 21:31:59 +08:00
options=('staticlibs') # needed by binutils testsuite
2017-03-18 02:59:06 +08:00
source=("http://zlib.net/zlib-${pkgver}.tar.gz"{,.asc})
md5sums=('1c9f62f0778697a09d36121ead88e08e'
'SKIP')
validpgpkeys=('5ED46A6721D365587791E2AA783FCD8E58BCAFBA')
prepare() {
cd ${srcdir}/zlib-$pkgver
grep -A 24 '^ Copyright' zlib.h > LICENSE
}
2010-03-13 23:25:19 +08:00
build() {
cd ${srcdir}/zlib-$pkgver
2010-05-16 23:08:55 +08:00
./configure --prefix=/usr
make
2010-03-13 23:25:19 +08:00
2017-03-18 02:59:06 +08:00
cd contrib/minizip
cp Makefile Makefile.orig
cp ../README.contrib readme.txt
autoreconf --install
./configure --prefix=/usr --enable-static=no
make
2010-03-13 23:25:19 +08:00
}
2012-06-03 06:07:19 +08:00
check() {
cd ${srcdir}/zlib-$pkgver
make test
2017-03-18 02:59:06 +08:00
cd contrib/minizip
make -f Makefile.orig test
2012-06-03 06:07:19 +08:00
}
2017-03-18 02:59:06 +08:00
package_zlib() {
pkgdesc='Compression library implementing the deflate compression method found in gzip and PKZIP'
2010-03-13 23:25:19 +08:00
cd ${srcdir}/zlib-$pkgver
make install DESTDIR=${pkgdir}
2010-03-13 23:25:19 +08:00
install -D -m644 LICENSE ${pkgdir}/usr/share/licenses/zlib/LICENSE
2012-06-03 06:07:19 +08:00
}
2017-03-18 02:59:06 +08:00
package_minizip() {
pkgdesc='Mini zip and unzip based on zlib'
depends=('zlib')
cd ${srcdir}/zlib-$pkgver/contrib/minizip
make install DESTDIR=${pkgdir}
install -D -m644 ${srcdir}/zlib-$pkgver/LICENSE ${pkgdir}/usr/share/licenses/minizip/LICENSE
}