From 4933dc3fb7d5f8f0ccd6a9d782fadff24863c132 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robin=20Lind=C3=A9n?= Date: Wed, 8 May 2019 21:40:04 +0200 Subject: [PATCH] Add option of using blocking random --- CMakeLists.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9703f72..490d1e9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -4,6 +4,7 @@ project("sodium") option(SODIUM_DISABLE_TESTS "Disable tests" OFF) option(SODIUM_MINIMAL "Only compile the minimum set of functions required for the high-level API" OFF) +option(SODIUM_ENABLE_BLOCKING_RANDOM "Enable this switch only if /dev/urandom is totally broken on the target platform" OFF) add_library(${PROJECT_NAME} libsodium/src/libsodium/crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c @@ -267,6 +268,7 @@ target_compile_definitions(${PROJECT_NAME} $<$:SODIUM_LIBRARY_MINIMAL> PRIVATE $<$:SODIUM_DLL_EXPORT> + $<$:USE_BLOCKING_RANDOM> $<$:MINIMAL> )