jca 1353cb4429 Update to mbedtls-2.6.0
https://tls.mbed.org/tech-updates/security-advisories/mbedtls-security-advisory-2017-01

mentions 3 security issues, at least CVE-2017-2784 (Freeing of memory
allocated on stack when validating a public key with a secp224k1 curve)
affects mbedtls-2.2.1.

Packaging:
- bump major of shared libs since symbols have been removed
- tweak license marker
- kill code in testsuite that fails to build with our stdio
  implementation (can't take the address of stdout, the C standard
  warns about that)
- kill some debug flags set by cmake

Make test passes on amd64 and arm, also tests & ok juanfra@
2017-10-21 00:47:52 +00:00

40 lines
1.1 KiB
Makefile

# $OpenBSD: Makefile,v 1.18 2017/10/21 00:47:52 jca Exp $
COMMENT= SSL library with an intuitive API and readable source code
DISTNAME= mbedtls-2.6.0
EXTRACT_SUFX= -gpl.tgz
# check SOVERSION
SHARED_LIBS += mbedtls 3.0 # 2.6
SHARED_LIBS += mbedcrypto 1.0 # 2.6
SHARED_LIBS += mbedx509 1.0 # 2.6
CATEGORIES= security
HOMEPAGE= https://tls.mbed.org/
# Dual licensed: GPLv2+/Commercial, Apache v2 is also available
PERMIT_PACKAGE_CDROM= Yes
# libssl/libcrypto are used for polarssl_o_p_test only
WANTLIB += c pthread
MASTER_SITES= https://tls.mbed.org/download/
MODULES= devel/cmake
CONFIGURE_ARGS= -DUSE_SHARED_MBEDTLS_LIBRARY=ON \
-DLINK_WITH_PTHREAD=ON
post-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/doc/mbedtls
cd ${WRKSRC}; ${INSTALL_DATA} README.md ChangeLog \
${PREFIX}/share/doc/mbedtls
mv ${PREFIX}/bin ${PREFIX}/share/examples/mbedtls
(echo "These programs are useful code samples for a crypto expert, but";\
echo "should not be relied upon by the normal end-user.") \
> ${PREFIX}/share/examples/mbedtls/README
.include <bsd.port.mk>