diff options
author | Vladislav Vaintroub <wlad@montyprogram.com> | 2011-01-29 18:51:12 +0100 |
---|---|---|
committer | Vladislav Vaintroub <wlad@montyprogram.com> | 2011-01-29 18:51:12 +0100 |
commit | b19e99865ccf3e946ebe59bf09add8e0452904ac (patch) | |
tree | 23cb9e8176ef9d0e276b47d197e11d195b2ecafb /libmysqld | |
parent | 3edf4dcd5a36be8d5acc94e0c5e29e77e47cd15b (diff) | |
download | mariadb-git-b19e99865ccf3e946ebe59bf09add8e0452904ac.tar.gz |
MWL#55 : cherrypick MySQL 5.5 CMake/build improvements in order
to be able to build MSI based installer
Diffstat (limited to 'libmysqld')
-rw-r--r-- | libmysqld/CMakeLists.txt | 18 | ||||
-rw-r--r-- | libmysqld/examples/CMakeLists.txt | 15 |
2 files changed, 19 insertions, 14 deletions
diff --git a/libmysqld/CMakeLists.txt b/libmysqld/CMakeLists.txt index 27850357127..18ac1af9516 100644 --- a/libmysqld/CMakeLists.txt +++ b/libmysqld/CMakeLists.txt @@ -28,14 +28,15 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/sql ${CMAKE_SOURCE_DIR}/regex ${CMAKE_SOURCE_DIR}/extra/yassl/include - ${CMAKE_SOURCE_DIR}/zlib) + ${CMAKE_SOURCE_DIR}/zlib + ${CMAKE_BINARY_DIR}/sql) -SET(GEN_SOURCES ${CMAKE_SOURCE_DIR}/sql/sql_yacc.cc - ${CMAKE_SOURCE_DIR}/sql/sql_yacc.h +SET(GEN_SOURCES ${CMAKE_BINARY_DIR}/sql/sql_yacc.cc + ${CMAKE_BINARY_DIR}/sql/sql_yacc.h ${CMAKE_SOURCE_DIR}/sql/message.h ${CMAKE_SOURCE_DIR}/sql/message.rc - ${CMAKE_SOURCE_DIR}/sql/sql_builtin.cc - ${CMAKE_SOURCE_DIR}/sql/lex_hash.h) + ${CMAKE_BINARY_DIR}/sql/sql_builtin.cc + ${CMAKE_BINARY_DIR}/sql/lex_hash.h) SET_SOURCE_FILES_PROPERTIES(${GEN_SOURCES} PROPERTIES GENERATED 1) @@ -166,6 +167,9 @@ ADD_LIBRARY(libmysqld SHARED cmake_dummy.c libmysqld.def) ADD_DEPENDENCIES(libmysqld mysqlserver) TARGET_LINK_LIBRARIES(libmysqld mysqlserver wsock32) -INSTALL(TARGETS mysqlserver DESTINATION Embedded/static COMPONENT embedded) +INSTALL(TARGETS mysqlserver DESTINATION lib COMPONENT Embedded) +INSTALL_DEBUG_SYMBOLS(mysqlserver) +INSTALL_DEBUG_TARGET(mysqlserver DESTINATION lib/debug COMPONENT Embedded) -INSTALL(TARGETS libmysqld DESTINATION Embedded/DLL COMPONENT embedded) +INSTALL(TARGETS libmysqld DESTINATION lib COMPONENT Embedded) +INSTALL_DEBUG_SYMBOLS(libmysqld) diff --git a/libmysqld/examples/CMakeLists.txt b/libmysqld/examples/CMakeLists.txt index 5194836a728..1f41d608099 100644 --- a/libmysqld/examples/CMakeLists.txt +++ b/libmysqld/examples/CMakeLists.txt @@ -26,16 +26,17 @@ ENDIF(WIN32) ADD_DEFINITIONS(-DEMBEDDED_LIBRARY) -ADD_EXECUTABLE(mysql_embedded ../../client/completion_hash.cc + +MYSQL_ADD_EXECUTABLE(mysql_embedded ../../client/completion_hash.cc ../../client/mysql.cc ../../client/readline.cc - ../../client/sql_string.cc) + COMPONENT Test) TARGET_LINK_LIBRARIES(mysql_embedded debug dbug strings mysys vio yassl taocrypt regex ws2_32) -TARGET_LINK_LIBRARIES(mysql_embedded libmysqld) +TARGET_LINK_LIBRARIES(mysql_embedded mysqlserver) -ADD_EXECUTABLE(mysqltest_embedded ../../client/mysqltest.cc) +MYSQL_ADD_EXECUTABLE(mysqltest_embedded ../../client/mysqltest.cc COMPONENT Test) TARGET_LINK_LIBRARIES(mysqltest_embedded debug dbug strings mysys vio yassl taocrypt regex ws2_32) -TARGET_LINK_LIBRARIES(mysqltest_embedded libmysqld) +TARGET_LINK_LIBRARIES(mysqltest_embedded mysqlserver) -ADD_EXECUTABLE(mysql_client_test_embedded ../../tests/mysql_client_test.c) +MYSQL_ADD_EXECUTABLE(mysql_client_test_embedded ../../tests/mysql_client_test.c COMPONENT Test) TARGET_LINK_LIBRARIES(mysql_client_test_embedded debug dbug strings mysys vio yassl taocrypt regex ws2_32) -TARGET_LINK_LIBRARIES(mysql_client_test_embedded libmysqld) +TARGET_LINK_LIBRARIES(mysql_client_test_embedded mysqlserver) |