diff options
author | joerg <joerg@pkgsrc.org> | 2014-03-05 21:22:38 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2014-03-05 21:22:38 +0000 |
commit | 6f38d846826fcfcca18477c718280a847d74a5e3 (patch) | |
tree | e8870f7227b3af318976c99eb58bc14a52f227a5 /security/botan-devel | |
parent | 41db815f0b51fb16dde9ad148339893e5476caa0 (diff) | |
download | pkgsrc-6f38d846826fcfcca18477c718280a847d74a5e3.tar.gz |
Fix build on NetBSD and with clang.
Diffstat (limited to 'security/botan-devel')
5 files changed, 62 insertions, 2 deletions
diff --git a/security/botan-devel/Makefile b/security/botan-devel/Makefile index be8626653c9..11fd35b6d5a 100644 --- a/security/botan-devel/Makefile +++ b/security/botan-devel/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.1 2014/02/24 20:49:14 joerg Exp $ +# $NetBSD: Makefile,v 1.2 2014/03/05 21:22:38 joerg Exp $ DISTNAME= Botan-1.11.8 PKGNAME= ${DISTNAME:tl} @@ -20,6 +20,11 @@ CONFIG_SHELL= ${PYTHONBIN} CONFIGURE_SCRIPT= ./configure.py CONFIGURE_ARGS+= --prefix=${PREFIX} --with-zlib --with-boost +.include "../../mk/compiler.mk" +.if !empty(PKGSRC_COMPILER:Mclang) +CONFIGURE_ARGS+= --cc-bin=${CXX} --cc=clang +.endif + MAKE_FLAGS+= LIB_OPT=${CXXFLAGS:Q} USE_TOOLS+= gmake diff --git a/security/botan-devel/distinfo b/security/botan-devel/distinfo index f093d2c5c01..008043e5184 100644 --- a/security/botan-devel/distinfo +++ b/security/botan-devel/distinfo @@ -1,6 +1,9 @@ -$NetBSD: distinfo,v 1.1 2014/02/24 20:49:14 joerg Exp $ +$NetBSD: distinfo,v 1.2 2014/03/05 21:22:38 joerg Exp $ SHA1 (Botan-1.11.8.tbz) = bde51183fd601b1cf1e687a1fe88eb2407c2db32 RMD160 (Botan-1.11.8.tbz) = 62f1ca66f5eceb18e9218321e8b983af3743167f Size (Botan-1.11.8.tbz) = 2193897 bytes +SHA1 (patch-src_build-data_cc_clang.txt) = e36a85e036765d103c06eedac2d9f553a9202173 SHA1 (patch-src_build-data_makefile_header.in) = 9ef8fba7f7a4d665d95478cdd87d58839d438f80 +SHA1 (patch-src_lib_alloc_locking__allocator_locking__allocator.cpp) = c4df20faf13b902c9fce21a0ff806b0d83c08780 +SHA1 (patch-src_lib_kdf_kdf.h) = 018dcfca7821b64b94175809aaad3fa3d578648c diff --git a/security/botan-devel/patches/patch-src_build-data_cc_clang.txt b/security/botan-devel/patches/patch-src_build-data_cc_clang.txt new file mode 100644 index 00000000000..87bb9413dc8 --- /dev/null +++ b/security/botan-devel/patches/patch-src_build-data_cc_clang.txt @@ -0,0 +1,14 @@ +$NetBSD: patch-src_build-data_cc_clang.txt,v 1.1 2014/03/05 21:22:38 joerg Exp $ + +--- src/build-data/cc/clang.txt.orig 2014-03-01 16:46:28.000000000 +0000 ++++ src/build-data/cc/clang.txt +@@ -53,8 +53,7 @@ ivybridge -> "-march=core-avx-i" + </mach_opt> + + <mach_abi_linking> +-#all -> "-stdlib=libc++ -pthread" +-all -> "-stdlib=libstdc++ -pthread" ++all -> "-pthread" + + x86_64 -> "-m64" + ppc64 -> "-m64" diff --git a/security/botan-devel/patches/patch-src_lib_alloc_locking__allocator_locking__allocator.cpp b/security/botan-devel/patches/patch-src_lib_alloc_locking__allocator_locking__allocator.cpp new file mode 100644 index 00000000000..a6d4b6a3b4f --- /dev/null +++ b/security/botan-devel/patches/patch-src_lib_alloc_locking__allocator_locking__allocator.cpp @@ -0,0 +1,26 @@ +$NetBSD: patch-src_lib_alloc_locking__allocator_locking__allocator.cpp,v 1.1 2014/03/05 21:22:38 joerg Exp $ + +--- src/lib/alloc/locking_allocator/locking_allocator.cpp.orig 2014-02-14 02:36:03.000000000 +0000 ++++ src/lib/alloc/locking_allocator/locking_allocator.cpp +@@ -7,9 +7,10 @@ + + #include <botan/locking_allocator.h> + #include <botan/mem_ops.h> +-#include <algorithm> + #include <sys/mman.h> + #include <sys/resource.h> ++#include <algorithm> ++#include <string> + + namespace Botan { + +@@ -213,6 +214,9 @@ mlock_allocator::mlock_allocator() : + #if !defined(MAP_NOCORE) + #define MAP_NOCORE 0 + #endif ++#if !defined(MAP_ANONYMOUS) ++ #define MAP_ANONYMOUS MAP_ANON ++#endif + + if(m_poolsize) + { diff --git a/security/botan-devel/patches/patch-src_lib_kdf_kdf.h b/security/botan-devel/patches/patch-src_lib_kdf_kdf.h new file mode 100644 index 00000000000..c7679d6c91f --- /dev/null +++ b/security/botan-devel/patches/patch-src_lib_kdf_kdf.h @@ -0,0 +1,12 @@ +$NetBSD: patch-src_lib_kdf_kdf.h,v 1.1 2014/03/05 21:22:38 joerg Exp $ + +--- src/lib/kdf/kdf.h.orig 2014-03-01 16:36:51.000000000 +0000 ++++ src/lib/kdf/kdf.h +@@ -10,6 +10,7 @@ + + #include <botan/secmem.h> + #include <botan/types.h> ++#include <string> + + namespace Botan { + |