APKBUILD 1.73 KB
Newer Older
1
# Contriburo: Łukasz Jendrysik <scadu@yandex.com>
root's avatar
root committed
2
# Contributor: Michael Mason <ms13sp@gmail.com>
Natanael Copa's avatar
Natanael Copa committed
3
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
root's avatar
root committed
4
pkgname=gnutls
Natanael Copa's avatar
Natanael Copa committed
5
pkgver=3.4.0
Natanael Copa's avatar
Natanael Copa committed
6
pkgrel=0
7
pkgdesc="A TLS protocol implementation"
8
url="http://www.gnutls.org/"
9
arch="all"
root's avatar
root committed
10
license="GPL"
Natanael Copa's avatar
Natanael Copa committed
11
depends=
Natanael Copa's avatar
Natanael Copa committed
12
depends_dev="nettle-dev zlib-dev libtasn1-dev p11-kit-dev"
13
makedepends="$depends_dev texinfo"
root's avatar
root committed
14
install=
Natanael Copa's avatar
Natanael Copa committed
15
subpackages="$pkgname-dbg $pkgname-doc $pkgname-dev $pkgname-utils $pkgname-c++:xx"
Natanael Copa's avatar
Natanael Copa committed
16
source="ftp://ftp.gnutls.org/gcrypt/gnutls/v${pkgver%.*}/$pkgname-$pkgver.tar.xz
Natanael Copa's avatar
Natanael Copa committed
17
18
	"

Natanael Copa's avatar
Natanael Copa committed
19
_builddir="$srcdir/$pkgname-$pkgver"
Natanael Copa's avatar
Natanael Copa committed
20
21
22
23
24
25
26
27
28

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

build() {
Natanael Copa's avatar
Natanael Copa committed
31
	cd "$_builddir"
32
33
34
35
	LIBS="-lgmp" ./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
root's avatar
root committed
36
37
38
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
Natanael Copa's avatar
Natanael Copa committed
39
		--disable-openssl-compatibility \
40
41
		--disable-rpath \
		--disable-static \
Natanael Copa's avatar
Natanael Copa committed
42
43
		--disable-guile \
		--disable-valgrind-tests \
44
		|| return 1
Natanael Copa's avatar
Natanael Copa committed
45
46
	make
}
root's avatar
root committed
47

Natanael Copa's avatar
Natanael Copa committed
48
package() {
Natanael Copa's avatar
Natanael Copa committed
49
	cd "$_builddir"
Natanael Copa's avatar
Natanael Copa committed
50
	make -j1 DESTDIR="$pkgdir" install
51
	rm -f "$pkgdir"/usr/lib/*.la
root's avatar
root committed
52
53
}

54
55
56
57
58
utils() {
	pkgdesc="Command line tools for TLS protocol"
	mkdir -p "$subpkgdir"/usr/
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}
Natanael Copa's avatar
Natanael Copa committed
59
60
61
62
63
64
65

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

Natanael Copa's avatar
Natanael Copa committed
66
67
68
md5sums="aa015c2666b031044edfb01b01980d84  gnutls-3.4.0.tar.xz"
sha256sums="b422544431bfb5c4e24a605b6c793ee34792cc791c1060562ab46eaf77f3472e  gnutls-3.4.0.tar.xz"
sha512sums="ab11bb46e69a689f275cc158d8bc031bb09287a2193a2d9ccb36c04a8e106d9204754bd148c67417e6d63ed0c75750bbe7b602424bb7dcd9af2e25d9275ef02d  gnutls-3.4.0.tar.xz"