aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2017-10-26 10:16:48 +0100
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2017-11-27 22:15:34 +0000
commit000666ff784185583c76f33bf0882a08fd9c29f2 (patch)
tree47566d1e726380beb28f6823db327f4cb12562ff /CMakeLists.txt
parentMerge pull request #2827 (diff)
downloadmonero-000666ff784185583c76f33bf0882a08fd9c29f2.tar.xz
add a memwipe function
It's meant to avoid being optimized out memory_cleanse lifted from bitcoin
Diffstat (limited to '')
-rw-r--r--CMakeLists.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d63b50510..b11d6ba6f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -768,3 +768,11 @@ option(BUILD_GUI_DEPS "Build GUI dependencies." OFF)
option(INSTALL_VENDORED_LIBUNBOUND "Install libunbound binary built from source vendored with this repo." OFF)
+include(CheckCCompilerFlag)
+
+CHECK_C_COMPILER_FLAG(-std=c11 HAVE_C11)
+
+include(CheckLibraryExists)
+
+check_library_exists(c memset_s "string.h" HAVE_MEMSET_S)
+check_library_exists(c explicit_bzero "strings.h" HAVE_EXPLICIT_BZERO)