SSX3LobbyServer/lib/impl/CMakeLists.txt

40 lines
1011 B
CMake
Raw Normal View History

add_library(base_impl
asio_src.cpp
beast_src.cpp
#mysql_src.cpp
tomlpp_src.cpp
)
lobbyserver_target(base_impl)
target_compile_definitions(base_impl PUBLIC
# We choose to only support Linux 5.15+ onwards,
# so explicitly use io_uring (when it works).
-DBOOST_ASIO_HAS_IO_URING=1
-DBOOST_ASIO_HAS_IO_URING_AS_DEFAULT=1
# We compile all of these header-only libraries in separate .cpp source files
# to decrease build churn
-DBOOST_ASIO_SEPARATE_COMPILATION=1
-DBOOST_BEAST_SEPARATE_COMPILATION=1
# TODO: re-enable this (once we have boost mysql)
#-DBOOST_MYSQL_SEPARATE_COMPILATION=1
-DTOML_HEADER_ONLY=0
# Disable deprecated functionality and some things which add additional dependencies or are
# simply baggage we aren't ever going to use
-DBOOST_ASIO_NO_DEPRECATED=1
-DBOOST_ASIO_DISABLE_BOOST_ARRAY=1
-DBOOST_ASIO_DISABLE_BOOST_BIND=1
)
target_link_libraries(base_impl PUBLIC
Boost::asio
Boost::beast
uring
tomlplusplus::tomlplusplus
)
add_library(base::impl ALIAS base_impl)