aboutsummaryrefslogtreecommitdiffstats
path: root/main/p11-kit/APKBUILD
blob: b2ee80f8875e4465ca2b93259274a6bf454d4390 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=p11-kit
pkgver=0.23.2
pkgrel=2
pkgdesc="Library for loading and sharing PKCS#11 modules"
url="https://p11-glue.freedesktop.org/"
arch="all"
license="BSD"
depends=""
depends_dev=""
makedepends="libtasn1-dev libffi-dev"
install=""
subpackages="$pkgname-dev $pkgname-doc $pkgname-trust"
source="https://p11-glue.freedesktop.org/releases/$pkgname-$pkgver.tar.gz"
builddir="$srcdir"/$pkgname-$pkgver

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--sysconfdir=/etc \
		--prefix=/usr \
		--mandir=/usr/share/man \
		--with-trust-paths=/etc/ssl/certs/ca-certificates.crt
	make
}

check() {
	cd "$builddir"
	make check
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

trust() {
	pkgdesc="System trust module from $pkgname"
	mkdir -p "$subpkgdir"/usr/share/p11-kit/modules \
		"$subpkgdir"/usr/lib/p11-kit \
		"$subpkgdir"/usr/lib/pkcs11

	mv "$pkgdir"/usr/lib/p11-kit/trust-extract-compat \
		"$subpkgdir"/usr/lib/p11-kit/
	mv "$pkgdir"/usr/share/p11-kit/modules/p11-kit-trust.module \
		"$subpkgdir"/usr/share/p11-kit/modules/
	mv "$pkgdir"/usr/lib/pkcs11/p11-kit-trust.so \
		"$subpkgdir"/usr/lib/pkcs11/
}

sha512sums="b665d89f0d752a41b01ec53e29c801c4fdcaf3f21fce524984b10acef0477ad5dbac085edd35ffb747423d0e1e09660b8d29501c979cf54937d3b9d2561cf18f  p11-kit-0.23.2.tar.gz"