83 lines
2.6 KiB
Bash
83 lines
2.6 KiB
Bash
#!/usr/bin/bash
|
|
# JOBoRun : Jwm OpenBox Obarun RUNit
|
|
# Maintainer : Joe Bo Run <joborun@disroot.org>
|
|
# PkgSource : url="https://gittea.disroot.org/joborun-pkg/jobcore/$pkgname"
|
|
# Website : https://pozol.eu
|
|
#-----------------------------------------| DESCRIPTION |---------------------------------------
|
|
|
|
pkgbase=zlib
|
|
pkgname=(zlib minizip)
|
|
pkgdesc='Compression library implementing the deflate compression method found in gzip and PKZIP'
|
|
epoch=1
|
|
pkgver=1.3.1
|
|
pkgrel=02
|
|
url="https://www.zlib.net/"
|
|
depends=('glibc')
|
|
makedepends=('automake' 'autoconf')
|
|
options=('staticlibs') # needed by binutils testsuite
|
|
#options=('staticlibs' 'debug') ## uncomment this to have the debug pkg produced
|
|
|
|
# NOTE: Next time use tar.xz source so it matches Arch and their sums
|
|
source=("https://zlib.net/zlib-${pkgver}.tar.gz"{,.asc})
|
|
|
|
prepare() {
|
|
cd $pkgbase-$pkgver/contrib/minizip
|
|
cp Makefile Makefile.orig
|
|
cp ../README.contrib readme.txt
|
|
autoreconf -fiv
|
|
|
|
}
|
|
|
|
build() {
|
|
cd $pkgbase-$pkgver
|
|
CFLAGS+=" -ffat-lto-objects"
|
|
./configure --prefix=/usr
|
|
make
|
|
|
|
cd contrib/minizip
|
|
./configure --prefix=/usr --enable-static=no
|
|
make
|
|
}
|
|
|
|
check() {
|
|
make test -C $pkgbase-$pkgver
|
|
make -f Makefile.orig test -C $pkgbase-$pkgver/contrib/minizip
|
|
}
|
|
|
|
package_zlib() {
|
|
pkgdesc='Compression library implementing the deflate compression method found in gzip and PKZIP'
|
|
provides=('libz.so')
|
|
make install DESTDIR="${pkgdir}" -C $pkgbase-$pkgver
|
|
install -D -m644 $pkgbase-$pkgver/LICENSE -t "${pkgdir}/usr/share/licenses/$pkgname/"
|
|
}
|
|
|
|
package_minizip() {
|
|
pkgdesc='Mini zip and unzip based on zlib'
|
|
depends=('zlib')
|
|
make install DESTDIR="${pkgdir}" -C $pkgbase-$pkgver/contrib/$pkgname
|
|
install -D -m644 $pkgbase-$pkgver/LICENSE -t "${pkgdir}/usr/share/licenses/$pkgname/"
|
|
# https://github.com/madler/zlib/pull/229
|
|
rm "${pkgdir}/usr/include/minizip/crypt.h"
|
|
}
|
|
|
|
#---- arch license gpg-key & sha256sums ----
|
|
|
|
arch=(x86_64)
|
|
|
|
#license=('custom')
|
|
license=(Zlib)
|
|
|
|
validpgpkeys=('5ED46A6721D365587791E2AA783FCD8E58BCAFBA')
|
|
|
|
sha256sums=(9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23 # zlib-1.3.1.tar.gz
|
|
57266943f4c8f8a3c653e0f33ceb90c1207ea1f96b0b3f22ecf47581d2e67c99) # zlib-1.3.1.tar.gz.asc
|
|
|
|
# Note to packager:
|
|
#ls -l *pkg.tar.lz
|
|
#echo "you must rename this package to meet SF naming before you move to the repo"
|
|
#echo "mv $pkgname-$epoch:$pkgver-$pkgrel-$arch.pkg.tar.lz $pkgname-$epoch_$pkgver-$pkgrel-$arch.pkg.tar.lz"
|
|
|
|
## 1504076db1a65986fc9b5ed2fcfe612fdf4b2b212a861f178955b6788ab32c2d minizip-1_1.3.1-02-x86_64.pkg.tar.lz
|
|
## eb476f7db071036efd0bfd860e59b443ef3e143bc7061598907f6a818dd38575 zlib-1_1.3.1-02-x86_64.pkg.tar.lz
|
|
|
|
|