summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Ospald <hasufell@gentoo.org>2015-09-19 14:18:41 +0200
committerJulian Ospald <hasufell@gentoo.org>2015-09-19 14:20:59 +0200
commit441dc3102c70b006dabaa13895fcf316b640fc3b (patch)
treed49e637a00d48273324a00d8c48891b7af2975e8 /net-libs
parentsci-electronics/gazebo: remove old. (diff)
downloadgentoo-441dc3102c70b006dabaa13895fcf316b640fc3b.tar.gz
gentoo-441dc3102c70b006dabaa13895fcf316b640fc3b.tar.bz2
gentoo-441dc3102c70b006dabaa13895fcf316b640fc3b.zip
net-libs/mbedtls: version bump to 2.1.1
Diffstat (limited to 'net-libs')
-rw-r--r--net-libs/mbedtls/Manifest1
-rw-r--r--net-libs/mbedtls/mbedtls-2.1.1.ebuild91
2 files changed, 92 insertions, 0 deletions
diff --git a/net-libs/mbedtls/Manifest b/net-libs/mbedtls/Manifest
index 375a07b4c4cf..daf15596a6cf 100644
--- a/net-libs/mbedtls/Manifest
+++ b/net-libs/mbedtls/Manifest
@@ -1,2 +1,3 @@
DIST mbedtls-2.0.0.tar.gz 1737179 SHA256 2af7f064580d7b7845c0a430b8111bd2ccc06d79d94589680f811c4c1091a1a1 SHA512 fd9f7e684a67f249512651727a84e5f327975ce05100d865fef8d5078e813eb2fb8d036d47fc2b15c7712e4900719e58718a6fd2a6592836c273f3b38f06eb0f WHIRLPOOL b73dc273ee18f035d25532e537cfdb21223613514f125cfa8e392d838da8f1c1a250915ab51d63b02d52d37a7e68ca21afc97c27388c60d455654238e3a7abc0
DIST mbedtls-2.1.0.tar.gz 1770972 SHA256 2d95eaed5c2ecc7acf04afe5cdb5895b6feb31c4040a55020a314b5a0182a27a SHA512 b581bcafcd76cd5830c84f4b8b23196d1e5db06399fe5578368468eea3ab4f9b814e107cc552ab94f62ffbe3054cac3071bac5ce72484cb7bf30209e9f497eee WHIRLPOOL 0cb3399c35c7181b4ea7c6585616bc488be9faa75c5ae6010248e9a516a125c95c344d132f0ae5a0fdf57008fbb7a360035ed4fef9aba9c216753ed7d675850f
+DIST mbedtls-2.1.1.tar.gz 1774848 SHA256 ae458a4987f36819bdf1d39519212f4063780fe448d4155878fccf4e782a715f SHA512 af49762f583d5063d1629498d5161ce58753cf2c05145d8b6c9e653bc99cc49e45bbab1d3b27f20ac8cc5ee937fb3b7aa4dbeba9fc8da6a8fa6253d3cbce3aef WHIRLPOOL 2586dafefb3ad992c32ab17462100c16f806eb75488461290d4fe2a99759001451bff2115eeb2b98a9eee11069c38ce564421cef99ab376b12014b9499708f4d
diff --git a/net-libs/mbedtls/mbedtls-2.1.1.ebuild b/net-libs/mbedtls/mbedtls-2.1.1.ebuild
new file mode 100644
index 000000000000..1c51012b3566
--- /dev/null
+++ b/net-libs/mbedtls/mbedtls-2.1.1.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit multilib cmake-utils multilib-minimal
+
+DESCRIPTION="Cryptographic library for embedded systems"
+HOMEPAGE="https://tls.mbed.org/"
+SRC_URI="https://github.com/ARMmbed/mbedtls/archive/mbedtls-${PV}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0/10" # slot for libmbedtls.so
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="cpu_flags_x86_sse2 doc havege programs test threads zlib"
+
+RDEPEND="
+ programs? ( dev-libs/openssl:0 )
+ zlib? ( >=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}] )"
+DEPEND="${RDEPEND}
+ doc? ( app-doc/doxygen media-gfx/graphviz )
+ test? ( dev-lang/perl )"
+
+S=${WORKDIR}/${PN}-${P}
+
+enable_mbedtls_option() {
+ local myopt="$@"
+ # check that config.h syntax is the same at version bump
+ sed -i \
+ -e "s://#define ${myopt}:#define ${myopt}:" \
+ include/mbedtls/config.h || die
+}
+
+src_prepare() {
+ use cpu_flags_x86_sse2 && enable_mbedtls_option MBEDTLS_HAVE_SSE2
+ use zlib && enable_mbedtls_option MBEDTLS_ZLIB_SUPPORT
+ use havege && enable_mbedtls_option MBEDTLS_HAVEGE_C
+ use threads && enable_mbedtls_option MBEDTLS_THREADING_C
+ use threads && enable_mbedtls_option MBEDTLS_THREADING_PTHREAD
+}
+
+multilib_src_configure() {
+ local mycmakeargs=(
+ $(multilib_is_native_abi && cmake-utils_use_enable programs PROGRAMS \
+ || echo -DENABLE_PROGRAMS=OFF)
+ $(cmake-utils_use_enable zlib ZLIB_SUPPORT)
+ -DUSE_STATIC_MBEDTLS_LIBRARY=OFF
+ $(cmake-utils_use_enable test TESTING)
+ -DUSE_SHARED_MBEDTLS_LIBRARY=ON
+ -DINSTALL_MBEDTLS_HEADERS=ON
+ -DLIB_INSTALL_DIR="/usr/$(get_libdir)"
+ )
+
+ cmake-utils_src_configure
+}
+
+multilib_src_compile() {
+ cmake-utils_src_compile
+ use doc && multilib_is_native_abi && emake apidoc
+}
+
+multilib_src_test() {
+ LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${BUILD_DIR}/library" \
+ cmake-utils_src_test
+}
+
+multilib_src_install() {
+ cmake-utils_src_install
+}
+
+multilib_src_install_all() {
+ einstalldocs
+
+ use doc && dohtml -r apidoc
+
+ if use programs ; then
+ # avoid file collisions with sys-apps/coreutils
+ local p e
+ for p in "${ED%/}"/usr/bin/* ; do
+ if [[ -x "${p}" && ! -d "${p}" ]] ; then
+ mv "${p}" "${ED%/}"/usr/bin/mbedtls_${p##*/} || die
+ fi
+ done
+ for e in aes hash pkey ssl test ; do
+ docinto "${e}"
+ dodoc programs/"${e}"/*.c
+ dodoc programs/"${e}"/*.txt
+ done
+ fi
+}