From 4b40fd97a72d4ac9d65ce37f22ca311d5de901f8 Mon Sep 17 00:00:00 2001 From: kakwa Date: Mon, 30 Jan 2017 08:29:17 +0100 Subject: [PATCH] add custom args for civetweb external project --- CMakeLists.txt | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7726138..1ae0c6f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,15 +2,14 @@ cmake_minimum_required (VERSION 2.6) project (uts-server) include(ExternalProject) - set(VERSION 0.1.6) -option(DEBUG "compile with debug symbol" OFF) -option(BUNDLE_CIVETWEB "bundle civetweb with uts-server" OFF) - -option(STATIC "static linked binary" OFF) -option(LINK_DL "dynamicaly link dl" OFF) -option(LINK_GCC_S "dynamicaly link gcc_s" OFF) +option(DEBUG "compile with debug symbol" OFF) +option(BUNDLE_CIVETWEB "bundle civetweb with uts-server" OFF) +option(STATIC "static linked binary" OFF) +option(LINK_DL "dynamicaly link dl" OFF) +option(LINK_GCC_S "dynamicaly link gcc_s" OFF) +option(CIVETWEB_CUST_ARGS "Custom args for civetweb (if civetweb is bundled)" "") IF(STATIC) set(CMAKE_FIND_LIBRARY_SUFFIXES ".a") @@ -78,7 +77,9 @@ if(BUNDLE_CIVETWEB) -DCIVETWEB_DISABLE_CACHING=ON -DBUILD_TESTING=OFF -DCIVETWEB_SSL_OPENSSL_API_1_1=${OPENSSL_API_1_1} + -DOPENSSL_USE_STATIC_LIBS=${OPENSSL_USE_STATIC_LIBS} -DCIVETWEB_ENABLE_SSL_DYNAMIC_LOADING=OFF + ${CIVETWEB_CUST_ARGS} INSTALL_COMMAND make install DESTDIR=${CMAKE_CURRENT_SOURCE_DIR}/vendor/ ) set(LIBCIVETWEB_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/vendor/usr/include") @@ -116,7 +117,6 @@ INSTALL(TARGETS uts-server RUNTIME DESTINATION bin ) - if(BUNDLE_CIVETWEB) add_dependencies(uts-server civetweb) endif(BUNDLE_CIVETWEB)