gtk/gcr/PKGBUILD
2019-01-24 09:02:12 +01:00

60 lines
1.5 KiB
Bash

# Contributions from ArchLinux: https://git.archlinux.org/svntogit/packages.git/tree/trunk?h=packages/gcr
pkgname=gcr
pkgver=3.28.1
pkgrel=1
pkgdesc="A library for bits of crypto UI and parsing"
url="https://git.gnome.org/browse/gcr"
arch=(x86_64)
license=(GPL2)
depends=(dconf gtk3 libgcrypt p11-kit)
makedepends=(intltool gobject-introspection python3 vala libxslt gnome-common git gtk-doc)
checkdepends=(python2)
_commit=3197d9e3711a946fca2efcb9059c7d5968254b90 # tags/3.28.1^0
source=("git+https://gitlab.gnome.org/GNOME/gcr.git#commit=$_commit"
10-gcr.conf)
sha256sums=('SKIP'
'1230351a1da53a9c2bada81c44f5a5113e5457552196eccb7b1413dcf4f661b5')
pkgver() {
cd $pkgname
git describe --tags | sed 's/-/+/g'
}
prepare() {
cd $pkgname
sed -i '1s/python$/&2/' build/tap-{driver,gtester}
NOCONFIGURE=1 ./autogen.sh
}
build() {
cd $pkgname
./configure --prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--libexecdir=/usr/lib \
--enable-gtk-doc \
--disable-static \
--disable-update-mime \
--disable-schemas-compile
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
check() {
cd $pkgname
# Secure memory tests fail
dbus-run-session make -k check || :
}
package() {
cd $pkgname
make DESTDIR="$pkgdir" install
# gcr wants to lock some memory to prevent swapping out private keys
# https://bugs.archlinux.org/task/32616
# https://bugzilla.gnome.org/show_bug.cgi?id=688161
install -Dt "$pkgdir/etc/security/limits.d" -m644 ../10-gcr.conf
}