mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-04-26 14:37:44 +00:00
Automatically copy libmysql.dll to bin folder
This commit is contained in:
parent
47fb47112a
commit
a022a37aab
4 changed files with 9 additions and 7 deletions
|
@ -2,7 +2,6 @@ cmake_policy( SET CMP0014 NEW )
|
|||
cmake_minimum_required( VERSION 3.0.2 )
|
||||
project( Sapphire )
|
||||
|
||||
|
||||
set( CMAKE_MODULE_PATH
|
||||
${CMAKE_MODULE_PATH}
|
||||
${CMAKE_SOURCE_DIR}/cmake )
|
||||
|
|
|
@ -189,6 +189,12 @@ if( WIN32 )
|
|||
"$ENV{MYSQL_ROOT}/lib"
|
||||
DOC "Specify the location of the mysql library here."
|
||||
)
|
||||
|
||||
STRING( REGEX REPLACE "(.lib)$" ".dll" MYSQL_DLL ${MYSQL_LIBRARY} )
|
||||
|
||||
file(COPY ${MYSQL_DLL}
|
||||
DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/bin/" )
|
||||
|
||||
endif( WIN32 )
|
||||
|
||||
# On Windows you typically don't need to include any extra libraries
|
||||
|
|
|
@ -18,8 +18,8 @@ add_library( common ${UTILS_PUBLIC_INCLUDE_FILES} ${UTILS_SOURCE_FILES} )
|
|||
|
||||
target_link_libraries( common
|
||||
PUBLIC
|
||||
xivdat
|
||||
mysqlConnector
|
||||
xivdat
|
||||
mysqlConnector
|
||||
mysql )
|
||||
if( UNIX )
|
||||
target_link_libraries( common
|
||||
|
@ -33,7 +33,5 @@ target_include_directories( common
|
|||
"${CMAKE_CURRENT_SOURCE_DIR}/"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../../deps/"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../../deps/asio/asio/include/"
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../../deps/spdlog/include/"
|
||||
PRIVATE
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/src/libraries/external/")
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/../../deps/spdlog/include/" )
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ cmake_policy( SET CMP0014 NEW )
|
|||
cmake_minimum_required( VERSION 3.0.2 )
|
||||
project( Sapphire )
|
||||
|
||||
#set( CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/bin )
|
||||
set( EXECUTABLE_OUTPUT_PATH ${EXECUTABLE_OUTPUT_PATH}/tools )
|
||||
set( LIBRARY_OUTPUT_PATH ${LIBRARY_OUTPUT_PATH}/tools )
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue