X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/ebd170a764ab9660adee464588cda1801c7986b4..46d0fa38003ef0b122fea77dfaa252fa832cb5a3:/projects/stargazer/plugins/CMakeLists.txt?ds=inline diff --git a/projects/stargazer/plugins/CMakeLists.txt b/projects/stargazer/plugins/CMakeLists.txt index 40e18dec..b6e4d326 100644 --- a/projects/stargazer/plugins/CMakeLists.txt +++ b/projects/stargazer/plugins/CMakeLists.txt @@ -12,10 +12,32 @@ if ( BUILD_MOD_AO ) endif ( BUILD_MOD_AO ) if ( BUILD_MOD_RADIUS ) - add_library ( mod_radius MODULE other/radius/radius.cpp ) - target_link_libraries ( mod_radius scriptexecuter logger common ) + find_package ( Boost REQUIRED ) + + add_library ( mod_radius MODULE other/radius/radius.cpp + other/radius/server.cpp) + target_link_libraries ( mod_radius PRIVATE scriptexecuter logger common ) set_target_properties ( mod_radius PROPERTIES PREFIX "" ) + include ( ExternalProject ) + + ExternalProject_Add ( async-radius + GIT_REPOSITORY https://github.com/madf/async-radius.git + GIT_TAG 1.1.0 + GIT_SHALLOW true + INSTALL_COMMAND "" + CMAKE_ARGS -DCMAKE_CXX_FLAGS=-fPIC ) + + ExternalProject_Get_property ( async-radius SOURCE_DIR BINARY_DIR ) + + target_include_directories ( mod_radius PRIVATE "${SOURCE_DIR}/include" ) + target_link_directories ( mod_radius PRIVATE "${BINARY_DIR}/src" ) + + add_dependencies ( mod_radius async-radius ) + + find_package ( OpenSSL 1.0.0 REQUIRED ) + target_link_libraries ( mod_radius PRIVATE radproto Boost::boost OpenSSL::Crypto) + if ( CLANG_TIDY_EXE ) set_target_properties ( mod_radius PROPERTIES CXX_CLANG_TIDY "${DO_CLANG_TIDY}" ) endif ()