mirror of
https://github.com/boostorg/beast.git
synced 2025-08-03 23:04:35 +02:00
Tidy up CMakeLists.txt
This commit is contained in:
@@ -72,6 +72,7 @@ find_package(OpenSSL)
|
|||||||
|
|
||||||
if (OPENSSL_FOUND)
|
if (OPENSSL_FOUND)
|
||||||
add_definitions (-DBEAST_USE_OPENSSL=1)
|
add_definitions (-DBEAST_USE_OPENSSL=1)
|
||||||
|
|
||||||
else()
|
else()
|
||||||
add_definitions (-DBEAST_USE_OPENSSL=0)
|
add_definitions (-DBEAST_USE_OPENSSL=0)
|
||||||
message("OpenSSL not found.")
|
message("OpenSSL not found.")
|
||||||
@@ -149,6 +150,10 @@ include_directories (.)
|
|||||||
include_directories (extras)
|
include_directories (extras)
|
||||||
include_directories (include)
|
include_directories (include)
|
||||||
|
|
||||||
|
if (OPENSSL_FOUND)
|
||||||
|
include_directories (${OPENSSL_INCLUDE_DIR})
|
||||||
|
endif()
|
||||||
|
|
||||||
set(ZLIB_SOURCES
|
set(ZLIB_SOURCES
|
||||||
${PROJECT_SOURCE_DIR}/test/zlib/zlib-1.2.8/crc32.h
|
${PROJECT_SOURCE_DIR}/test/zlib/zlib-1.2.8/crc32.h
|
||||||
${PROJECT_SOURCE_DIR}/test/zlib/zlib-1.2.8/deflate.h
|
${PROJECT_SOURCE_DIR}/test/zlib/zlib-1.2.8/deflate.h
|
||||||
|
@@ -1,6 +1,5 @@
|
|||||||
# Part of Beast
|
# Part of Beast
|
||||||
|
|
||||||
GroupSources(extras/beast extras)
|
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(example/echo-op "/")
|
GroupSources(example/echo-op "/")
|
||||||
|
@@ -4,11 +4,12 @@ GroupSources(include/beast beast)
|
|||||||
|
|
||||||
GroupSources(example/http-client-ssl "/")
|
GroupSources(example/http-client-ssl "/")
|
||||||
|
|
||||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
|
||||||
|
|
||||||
add_executable (http-client-ssl
|
add_executable (http-client-ssl
|
||||||
${BEAST_INCLUDES}
|
${BEAST_INCLUDES}
|
||||||
http_client_ssl.cpp
|
http_client_ssl.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(http-client-ssl Beast ${OPENSSL_LIBRARIES})
|
target_link_libraries(http-client-ssl
|
||||||
|
Beast
|
||||||
|
${OPENSSL_LIBRARIES}
|
||||||
|
)
|
||||||
|
@@ -1,6 +1,5 @@
|
|||||||
# Part of Beast
|
# Part of Beast
|
||||||
|
|
||||||
GroupSources(extras/beast extras)
|
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(example/http-client "/")
|
GroupSources(example/http-client "/")
|
||||||
|
@@ -1,6 +1,5 @@
|
|||||||
# Part of Beast
|
# Part of Beast
|
||||||
|
|
||||||
GroupSources(extras/beast extras)
|
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(example/http-crawl "/")
|
GroupSources(example/http-crawl "/")
|
||||||
|
@@ -4,10 +4,6 @@ GroupSources(include/beast beast)
|
|||||||
|
|
||||||
GroupSources(example/server-framework "/")
|
GroupSources(example/server-framework "/")
|
||||||
|
|
||||||
if (OPENSSL_FOUND)
|
|
||||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
add_executable (server-framework
|
add_executable (server-framework
|
||||||
${BEAST_INCLUDES}
|
${BEAST_INCLUDES}
|
||||||
${SERVER_INCLUDES}
|
${SERVER_INCLUDES}
|
||||||
|
@@ -4,11 +4,12 @@ GroupSources(include/beast beast)
|
|||||||
|
|
||||||
GroupSources(example/websocket-client-ssl "/")
|
GroupSources(example/websocket-client-ssl "/")
|
||||||
|
|
||||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
|
||||||
|
|
||||||
add_executable (websocket-client-ssl
|
add_executable (websocket-client-ssl
|
||||||
${BEAST_INCLUDES}
|
${BEAST_INCLUDES}
|
||||||
websocket_client_ssl.cpp
|
websocket_client_ssl.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
target_link_libraries(websocket-client-ssl Beast ${OPENSSL_LIBRARIES})
|
target_link_libraries(websocket-client-ssl
|
||||||
|
Beast
|
||||||
|
${OPENSSL_LIBRARIES}
|
||||||
|
)
|
||||||
|
@@ -1,6 +1,5 @@
|
|||||||
# Part of Beast
|
# Part of Beast
|
||||||
|
|
||||||
GroupSources(extras/beast extras)
|
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(example/websocket-client "/")
|
GroupSources(example/websocket-client "/")
|
||||||
|
@@ -13,6 +13,7 @@ if ((NOT "${VARIANT}" STREQUAL "coverage") AND
|
|||||||
|
|
||||||
GroupSources(extras/beast extras)
|
GroupSources(extras/beast extras)
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(test "/")
|
GroupSources(test "/")
|
||||||
|
|
||||||
add_executable (lib-tests
|
add_executable (lib-tests
|
||||||
|
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
GroupSources(extras/beast extras)
|
GroupSources(extras/beast extras)
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(test/benchmarks "/")
|
GroupSources(test/benchmarks "/")
|
||||||
GroupSources(test/http "/")
|
GroupSources(test/http "/")
|
||||||
|
|
||||||
|
@@ -3,6 +3,7 @@
|
|||||||
GroupSources(examples examples)
|
GroupSources(examples examples)
|
||||||
GroupSources(extras/beast extras)
|
GroupSources(extras/beast extras)
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(test/core "/")
|
GroupSources(test/core "/")
|
||||||
|
|
||||||
add_executable (core-tests
|
add_executable (core-tests
|
||||||
|
@@ -6,10 +6,6 @@ GroupSources(include/beast beast)
|
|||||||
|
|
||||||
GroupSources(test/server "/")
|
GroupSources(test/server "/")
|
||||||
|
|
||||||
if (OPENSSL_FOUND)
|
|
||||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
add_executable (server-test
|
add_executable (server-test
|
||||||
${BEAST_INCLUDES}
|
${BEAST_INCLUDES}
|
||||||
${SERVER_INCLUDES}
|
${SERVER_INCLUDES}
|
||||||
|
@@ -2,13 +2,10 @@
|
|||||||
|
|
||||||
GroupSources(extras/beast extras)
|
GroupSources(extras/beast extras)
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(test/websocket "/")
|
GroupSources(test/websocket "/")
|
||||||
|
|
||||||
include_directories(../../example/)
|
#include_directories(../../example/)
|
||||||
|
|
||||||
if (OPENSSL_FOUND)
|
|
||||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
|
||||||
endif()
|
|
||||||
|
|
||||||
add_executable (websocket-tests
|
add_executable (websocket-tests
|
||||||
${BEAST_INCLUDES}
|
${BEAST_INCLUDES}
|
||||||
|
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
GroupSources(extras/beast extras)
|
GroupSources(extras/beast extras)
|
||||||
GroupSources(include/beast beast)
|
GroupSources(include/beast beast)
|
||||||
|
|
||||||
GroupSources(test/zlib "/")
|
GroupSources(test/zlib "/")
|
||||||
|
|
||||||
if (MSVC)
|
if (MSVC)
|
||||||
|
Reference in New Issue
Block a user