aboutsummaryrefslogtreecommitdiffstats
path: root/main/gnutls/APKBUILD
blob: 836a3eef70ce59145afc3b065b16d80b7f954009 (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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Contriburo: Łukasz Jendrysik <scadu@yandex.com>
# Contributor: Michael Mason <ms13sp@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=gnutls
pkgver=3.3.12
pkgrel=0
pkgdesc="A TLS protocol implementation"
url="http://www.gnutls.org/"
arch="all"
license="GPL"
depends=
depends_dev="nettle-dev zlib-dev libtasn1-dev p11-kit-dev"
makedepends="$depends_dev texinfo"
install=
subpackages="$pkgname-dbg $pkgname-doc $pkgname-dev $pkgname-utils $pkgname-c++:xx"
source="ftp://ftp.gnutls.org/gcrypt/gnutls/v${pkgver%.*}/$pkgname-$pkgver.tar.xz
	"

_builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"
	LIBS="-lgmp" ./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--disable-openssl-compatibility \
		--disable-rpath \
		--disable-static \
		--disable-guile \
		--disable-valgrind-tests \
		|| return 1
	make
}

package() {
	cd "$_builddir"
	make -j1 DESTDIR="$pkgdir" install
	rm -f "$pkgdir"/usr/lib/*.la
}

utils() {
	pkgdesc="Command line tools for TLS protocol"
	mkdir -p "$subpkgdir"/usr/
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

xx() {
	pkgdesc="The C++ interface to GnuTLS"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/lib*xx.so.* "$subpkgdir"/usr/lib/
}

md5sums="a37b20b4352a5f542367ded904729c90  gnutls-3.3.12.tar.xz"
sha256sums="67ab3e92c5d48f3323b897d7c1aa0bb2af6f3a84f5bd9931cda163a7ff32299b  gnutls-3.3.12.tar.xz"
sha512sums="71c5ed7dee6c14581f675137b587173065c896040cb023b2910a3503a0f644abedc1f43c4e90c7a47ad4482215426788e272ba4b0b81c0475c2adcd62c4301a7  gnutls-3.3.12.tar.xz"