Mercurial > irccd
diff libcommon/CMakeLists.txt @ 513:928a40398dec
CMake: split options and conditions, closes #716
As described in the issue, the CMake process force off a cache variable
when a condition is not met. If the user installs the requirements and
re-run CMake it must also set the variable to on which is inconvenient.
The new process is to add a secondary variable and do not touch user
defined options.
author | David Demelier <markand@malikania.fr> |
---|---|
date | Mon, 23 Oct 2017 21:30:17 +0200 |
parents | 9fcdd3c9cd33 |
children | 16b9ebfd3f08 |
line wrap: on
line diff
--- a/libcommon/CMakeLists.txt Fri Oct 20 11:43:36 2017 +0200 +++ b/libcommon/CMakeLists.txt Mon Oct 23 21:30:17 2017 +0200 @@ -43,7 +43,7 @@ ${libcommon_SOURCE_DIR}/irccd/util.cpp ) -if (NOT WITH_SSL) +if (NOT HAVE_SSL) list(APPEND FLAGS NET_NO_SSL) endif () @@ -59,8 +59,8 @@ ${Boost_LIBRARIES} $<$<BOOL:${WIN32}>:shlwapi> $<$<BOOL:${WIN32}>:ws2_32> - $<$<BOOL:${WITH_SSL}>:OpenSSL::SSL> - $<$<BOOL:${WITH_SSL}>:OpenSSL::Crypto> + $<$<BOOL:${HAVE_SSL}>:OpenSSL::SSL> + $<$<BOOL:${HAVE_SSL}>:OpenSSL::Crypto> PUBLIC_INCLUDES ${Boost_INCLUDE_DIRS} $<BUILD_INTERFACE:${CMAKE_BINARY_DIR}>