diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt index bb169a141..ebc1d440b 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt @@ -74,4 +74,5 @@ configure_file( "${PROJECT_BINARY_DIR}/cmake_config.h" ) -add_subdirectory(test) \ No newline at end of file +add_subdirectory(test) +add_dependencies(TsFile_Test tsfile) \ No newline at end of file diff --git a/cpp/test/CMakeLists.txt b/cpp/test/CMakeLists.txt index d65f8ebcf..5b718a04f 100644 --- a/cpp/test/CMakeLists.txt +++ b/cpp/test/CMakeLists.txt @@ -32,10 +32,6 @@ FetchContent_MakeAvailable(googletest) set(SDK_INCLUDE_DIR ${PROJECT_SOURCE_DIR}/../src) message("SDK_INCLUDE_DIR: ${SDK_INCLUDE_DIR}") -set(SDK_LIB_DIR_RELEASE ${PROJECT_BINARY_DIR}/../lib) -message("SDK_LIB_DIR_RELEASE: ${SDK_LIB_DIR_RELEASE}") - -find_library(TSFILE_LIB tsfile ${SDK_LIB_DIR_RELEASE}) include_directories(${SDK_INCLUDE_DIR}) @@ -48,7 +44,7 @@ target_link_libraries( TsFile_Test GTest::gtest_main GTest::gmock - ${TSFILE_LIB} + tsfile ) include(GoogleTest)