82 lines
2.3 KiB
Bash
82 lines
2.3 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=libcap-ng
|
|
pkgname=(libcap-ng python-capng)
|
|
pkgver=0.8.5
|
|
pkgrel=02
|
|
pkgdesc='A library for Linux that makes using posix capabilities easy'
|
|
url='https://people.redhat.com/sgrubb/libcap-ng/'
|
|
depends=(glibc)
|
|
makedepends=(python swig)
|
|
#options=(debug) # uncomment if you want libcap-ng-debug package made
|
|
source=(https://github.com/stevegrubb/libcap-ng/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz)
|
|
|
|
_pick() {
|
|
local p="$1" f d; shift
|
|
for f; do
|
|
d="$srcdir/$p/${f#$pkgdir/}"
|
|
mkdir -p "$(dirname "$d")"
|
|
mv "$f" "$d"
|
|
rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
|
|
done
|
|
}
|
|
|
|
prepare() {
|
|
# backport patch for removed swig functionality: https://github.com/stevegrubb/libcap-ng/issues/48
|
|
cd $pkgbase-$pkgver
|
|
# make stupid autotools happy -_-
|
|
touch NEWS
|
|
autoreconf -fiv
|
|
}
|
|
|
|
build() {
|
|
cd $pkgbase-$pkgver
|
|
./configure \
|
|
--prefix=/usr \
|
|
--enable-static=no \
|
|
--without-python \
|
|
--with-python3
|
|
make
|
|
}
|
|
|
|
check() {
|
|
make check -C $pkgbase-$pkgver
|
|
}
|
|
|
|
package_libcap-ng() {
|
|
provides=(libcap-ng.so libdrop_ambient.so)
|
|
|
|
make DESTDIR="$pkgdir" install -C $pkgbase-$pkgver
|
|
|
|
(
|
|
cd "$pkgdir"
|
|
_pick python-capng usr/lib/python*
|
|
)
|
|
}
|
|
|
|
package_python-capng() {
|
|
pkgdesc+=' (Python bindings)'
|
|
depends+=(libcap-ng.so)
|
|
provides=(python-libcap-ng)
|
|
|
|
mv -v python-capng/* "$pkgdir"
|
|
}
|
|
|
|
#---- arch license gpg-key & sha256sums ----
|
|
|
|
arch=(x86_64)
|
|
|
|
license=(GPL-2.0-or-later LGPL-2.1-or-later)
|
|
|
|
sha512sums=('3bd868c7f263b77edd2feda831470b407f1086b434618e54336fb78bbf8bf3bad53f4c006a2118fb594b16554f8f7ec2acb76e08be5586d0261684e9ba139231')
|
|
b2sums=('70d70da50aff6423cf98cc87512d691308ec73e4143b4deb4bbc32e764db856af60d2aab2fed6ead2c5662adccb1ebf3a72bc1a8990261e104b28d2b9225cf92')
|
|
sha256sums=(e4be07fdd234f10b866433f224d183626003c65634ed0552b02e654a380244c2) # libcap-ng-0.8.5.tar.gz
|
|
|
|
## 3bfcf3121d35c803dad172aa5c4dc2fb3650efc041008dd08ea818953f32b9a2 libcap-ng-0.8.5-02-x86_64.pkg.tar.lz
|
|
## ea11a8edd507b3cadd69eb36eaf39f3f738822d19e5a5412f50d88d76baae179 python-capng-0.8.5-02-x86_64.pkg.tar.lz
|
|
|