summaryrefslogtreecommitdiff
path: root/tests/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'tests/CMakeLists.txt')
-rwxr-xr-xtests/CMakeLists.txt12
1 files changed, 9 insertions, 3 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 0ee8769cd23..ea2f41abb73 100755
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -17,8 +17,14 @@ ADD_DEFINITIONS("-DMYSQL_CLIENT")
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
-ADD_EXECUTABLE(mysql_client_test mysql_client_test.c ../mysys/my_memmem.c)
+ADD_EXECUTABLE(mysql_client_test mysql_client_test.c)
TARGET_LINK_LIBRARIES(mysql_client_test mysqlclient)
+SET_TARGET_PROPERTIES(mysql_client_test PROPERTIES LINKER_LANGUAGE CXX)
-ADD_EXECUTABLE(bug25714 bug25714.c)
-TARGET_LINK_LIBRARIES(bug25714 mysqlclient)
+IF(WITH_UNIT_TESTS)
+ ADD_EXECUTABLE(bug25714 bug25714.c)
+ TARGET_LINK_LIBRARIES(bug25714 mysqlclient)
+ SET_TARGET_PROPERTIES(bug25714 PROPERTIES LINKER_LANGUAGE CXX)
+ENDIF()
+
+INSTALL(TARGETS mysql_client_test DESTINATION bin)