blob: 0304a81ffec6d78d6ff569fdf9be78b6df679576 (
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
|
# Maintainer: Łukasz Jendrysik <scadu@yandex.com>
# Contributor: Bartłomiej Piotrowski <bpiotrowski@alpinelinux.org>
pkgname=mbedtls1
pkgver=1.3.11
pkgrel=0
pkgdesc='Portable cryptographic and SSL/TLS library'
arch=all
url='https://tls.mbed.org/'
license='GPL2'
replaces="mbedtls"
subpackages="$pkgname-dev $pkgname-utils"
source="https://tls.mbed.org/download/mbedtls-$pkgver-gpl.tgz
programs.makefile.patch"
prepare() {
cd "$srcdir"/mbedtls-$pkgver
sed -i 's|//\(#define POLARSSL_THREADING_C\)|\1|' include/polarssl/config.h
sed -i 's|//\(#define POLARSSL_THREADING_PTHREAD\)|\1|' include/polarssl/config.h
# cert_write
patch -p1 -d programs -i "$srcdir"/programs.makefile.patch
}
build() {
cd "$srcdir"/mbedtls-$pkgver
LDFLAGS="$LDFLAGS -I../include " make SHARED=1 no_test || return 1
}
check() {
cd "$srcdir"/mbedtls-$pkgver
make SHARED=1 check || return 1
}
package() {
cd "$srcdir"/mbedtls-$pkgver
make DESTDIR="$pkgdir/usr" install || return 1
}
utils() {
pkgdesc='PolarSSL command line utilities'
install -d "$subpkgdir"/usr
mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
install -Dm755 "$srcdir"/mbedtls-$pkgver/programs/x509/cert_write \
"$subpkgdir"/usr/bin/mbedtls_cert_write
}
md5sums="c02ce2e54862d678604794ee484fb59e mbedtls-1.3.11-gpl.tgz
d90f2d4cf4d4f04437a245cbaf7051ed programs.makefile.patch"
sha256sums="67a593027b6a442a4fa5b6c224c4ac8cdae5be721f5a28a11d34f10dcda441cb mbedtls-1.3.11-gpl.tgz
4310b1074ccb611bfcfc2329540ef688bcb6fc1731af61dd454248477a0f401d programs.makefile.patch"
sha512sums="242c486becc34d3b7ebba7624686aea6ed7713033aeabbfae7227284df322f191ddd5b9ded1228f100cd50bcfafb12396d93c30420afd3feb979b52a1860551e mbedtls-1.3.11-gpl.tgz
e77310e9bdd8b152838eaaf3bfc2e9fe42ab00945772d6102577062e69cd7de0992753eebcb3ae720eae2b6a2b63a02310db165a950151aaba64bbc52fd78dcf programs.makefile.patch"
|