Updated some stuff

This commit is contained in:
WolverinDEV 2020-04-18 00:14:52 +02:00
parent c31cc9d0ee
commit 17d2d7ae56

View File

@ -199,11 +199,10 @@ if(HAVE_OPEN_SSL)
openssl::crypto::static)
endif()
find_package(mysql REQUIRED)
find_package(mysql)
add_library(TeaSpeak STATIC ${SOURCE_FILES} ${HEADER_FILES})
target_link_libraries(TeaSpeak PUBLIC
mysql::client::static
threadpool::static jsoncpp_lib
${OPENSSL_LIBRARIES}
tomcrypt::static
@ -211,8 +210,13 @@ target_link_libraries(TeaSpeak PUBLIC
dl
)
target_compile_options(TeaSpeak PRIVATE "-Wall" "-DHAVE_MYSQL_H")
if(mysql_FOUND)
message("Found MySQL")
target_link_libraries(TeaSpeak PUBLIC
mysql::client::static
)
target_compile_options(TeaSpeak PRIVATE "-Wall" "-DHAVE_MYSQL_H")
endif()
if (TEASPEAK_SERVER)
target_link_libraries(TeaSpeak PUBLIC CXXTerminal::static)
endif ()