aboutsummaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2017-11-14 15:26:57 +0200
committerRiccardo Spagni <ric@spagni.net>2017-11-14 15:26:57 +0200
commit90d78b825ad01e35030b51a41f8badcd53f31a1d (patch)
treecaefd3300b3e668c00c45b2c8a9b47b2e34f0965 /external
parentMerge pull request #2727 (diff)
parentUpdated OpenBSD build instructions and fixed libressl linking issue (diff)
downloadmonero-90d78b825ad01e35030b51a41f8badcd53f31a1d.tar.xz
Merge pull request #2730
ba1b89fb Updated OpenBSD build instructions and fixed libressl linking issue (ston1th)
Diffstat (limited to 'external')
-rw-r--r--external/unbound/CMakeLists.txt9
1 files changed, 9 insertions, 0 deletions
diff --git a/external/unbound/CMakeLists.txt b/external/unbound/CMakeLists.txt
index 3dae8b425..8ac4bbd84 100644
--- a/external/unbound/CMakeLists.txt
+++ b/external/unbound/CMakeLists.txt
@@ -60,6 +60,15 @@ if (CMAKE_USE_WIN32_THREADS_INIT)
else ()
set(HAVE_WINDOWS_THREADS 0)
endif ()
+
+# determine if we have libressl
+check_symbol_exists(LIBRESSL_VERSION_TEXT "openssl/opensslv.h" HAVE_LIBRESSL)
+# check if we have found HAVE_DECL_REALLOCARRAY already, so we can safely undefine and redefine it with value 1
+if (HAVE_LIBRESSL AND HAVE_DECL_REALLOCARRAY)
+ unset(HAVE_DECL_REALLOCARRAY CACHE)
+ add_definitions(-DHAVE_DECL_REALLOCARRAY=1)
+endif ()
+
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/config.h")