aboutsummaryrefslogtreecommitdiffstats
path: root/testing/mbedtls
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2015-07-31 09:06:00 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2015-07-31 09:06:00 +0000
commit8fe83f980fdd53744e7f433f7fbfe5746ff88f16 (patch)
tree907119f91a2b8420a6d03799b602597fd02ce969 /testing/mbedtls
parent52b662eed09aea1eedae71763703a6a6676f787e (diff)
downloadaports-8fe83f980fdd53744e7f433f7fbfe5746ff88f16.tar.bz2
aports-8fe83f980fdd53744e7f433f7fbfe5746ff88f16.tar.xz
testing/mbedtls: new aport
Light-weight cryptographic and SSL/TLS library https://tls.mbed.org/
Diffstat (limited to 'testing/mbedtls')
-rw-r--r--testing/mbedtls/APKBUILD57
1 files changed, 57 insertions, 0 deletions
diff --git a/testing/mbedtls/APKBUILD b/testing/mbedtls/APKBUILD
new file mode 100644
index 0000000000..41e9bfb4f8
--- /dev/null
+++ b/testing/mbedtls/APKBUILD
@@ -0,0 +1,57 @@
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=mbedtls
+pkgver=2.0.0
+pkgrel=0
+pkgdesc="Light-weight cryptographic and SSL/TLS library"
+url="https://tls.mbed.org/"
+arch="all"
+license="GPLv2+ with exceptions"
+depends=""
+depends_dev=""
+makedepends="$depends_dev cmake"
+install=""
+subpackages="$pkgname-static $pkgname-dev $pkgname-utils"
+source="https://tls.mbed.org/download/mbedtls-$pkgver-gpl.tgz"
+
+_builddir="$srcdir"/mbedtls-2.0.0
+prepare() {
+ local i
+ 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"
+ cmake . \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_BUILD_TYPE="Release" \
+ -DUSE_SHARED_MBEDTLS_LIBRARY=1 \
+ || return 1
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install || return 1
+ rm -f "$pkgdir"/usr/lib/*.la
+}
+
+utils() {
+ pkgdesc="Utilities for mbedtls"
+ mkdir -p "$subpkgdir"/usr/libexec
+ mv "$pkgdir"/usr/bin "$subpkgdir"/usr/libexec/mbedtls || return 1
+}
+
+static() {
+ pkgdesc="Static files for mbedtls"
+ mkdir -p "$subpkgdir"/usr/lib
+ mv "$pkgdir"/usr/lib/*.a "$subpkgdir"/usr/lib/
+}
+
+md5sums="6b8246a19a7a77737856e729cc8a0952 mbedtls-2.0.0-gpl.tgz"
+sha256sums="149a06621368540b7e1cef1b203c268439c2edbf29e2e9471d8021125df34952 mbedtls-2.0.0-gpl.tgz"
+sha512sums="184b7ad8a673db80321de9b63d6d1e19e1f62bea585efc6ac67e1c58ed312d112370dfd157ed1ff2db76f2ff5dc2bc7e9808e4c6779707f2b2c426726c2e1f1c mbedtls-2.0.0-gpl.tgz"