Files
beast/test/cmake_test/CMakeLists.txt
T

95 lines
1.6 KiB
CMake
Raw Normal View History

2024-11-20 19:54:25 +00:00
#
# Copyright (c) 2022 alandefreitas (alandefreitas@gmail.com)
2024-12-01 10:02:19 +00:00
# Copyright (c) 2023 Christian Mazakas
# Copyright (c) 2024 Mohammad Nejati
2024-11-20 19:54:25 +00:00
#
# Distributed under the Boost Software License, Version 1.0.
# https://www.boost.org/LICENSE_1_0.txt
#
cmake_minimum_required(VERSION 3.5...3.16)
project(cmake_subdir_test LANGUAGES CXX)
set(__ignore__ ${CMAKE_C_COMPILER})
set(__ignore__ ${CMAKE_C_FLAGS})
if(BOOST_CI_INSTALL_TEST)
find_package(Boost CONFIG REQUIRED COMPONENTS beast)
else()
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR})
add_subdirectory(../.. boostorg/beast)
2024-12-01 10:02:19 +00:00
set(BOOST_BEAST_BUILD_TESTS OFF CACHE BOOL "" FORCE)
2024-11-20 19:54:25 +00:00
set(deps
# Primary dependencies
asio
assert
bind
config
container
container_hash
core
endian
intrusive
logic
mp11
optional
smart_ptr
static_string
system
throw_exception
type_index
type_traits
winapi
# Secondary dependencies
align
context
date_time
move
describe
utility
compat
2024-11-20 19:54:25 +00:00
variant2
predef
pool
algorithm
io
lexical_cast
numeric/conversion
range
tokenizer
2025-10-22 16:51:28 +00:00
preprocessor
2024-11-20 19:54:25 +00:00
array
concept_check
exception
function
iterator
mpl
regex
tuple
unordered
conversion
integer
detail
fusion
function_types
2024-11-20 19:54:25 +00:00
typeof
)
foreach(dep IN LISTS deps)
add_subdirectory(../../../${dep} boostorg/${dep} EXCLUDE_FROM_ALL)
endforeach()
endif()
add_executable(main main.cpp)
source_group("" FILES main.cpp)
2024-11-20 19:54:25 +00:00
target_link_libraries(main Boost::beast)
enable_testing()
add_test(NAME main COMMAND main)
add_custom_target(check COMMAND ${CMAKE_CTEST_COMMAND} --output-on-failure -C $<CONFIG>)