1 # Maintainer: Pierre Schmitz <pierre@archlinux.de>
10 url="https://www.zlib.net/"
12 options=('staticlibs') # needed by binutils testsuite
13 source=("https://zlib.net/zlib-${pkgver}.tar.gz"{,.asc})
14 sha256sums=('b3a24de97a8fdbc835b9833169501030b8977031bcb54b3b3ac13740f846ab30'
16 validpgpkeys=('5ED46A6721D365587791E2AA783FCD8E58BCAFBA')
19 cd "${srcdir}/zlib-$pkgver"
20 grep -A 24 '^ Copyright' zlib.h > LICENSE
24 cd "${srcdir}/zlib-$pkgver"
26 CFLAGS+=" -ffat-lto-objects"
27 ./configure --prefix=/usr
31 cp Makefile Makefile.orig
32 cp ../README.contrib readme.txt
34 ./configure --prefix=/usr --enable-static=no
39 cd "${srcdir}/zlib-$pkgver"
43 make -f Makefile.orig test
47 pkgdesc='Compression library implementing the deflate compression method found in gzip and PKZIP'
49 cd "${srcdir}/zlib-$pkgver"
50 make install DESTDIR="${pkgdir}"
51 install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/zlib/LICENSE"
55 pkgdesc='Mini zip and unzip based on zlib'
58 cd "${srcdir}/zlib-$pkgver/contrib/minizip"
59 make install DESTDIR="${pkgdir}"
60 install -D -m644 "${srcdir}/zlib-$pkgver/LICENSE" "${pkgdir}/usr/share/licenses/minizip/LICENSE"
62 # https://github.com/madler/zlib/pull/229
63 rm "${pkgdir}/usr/include/minizip/crypt.h"