summaryrefslogtreecommitdiff
path: root/test/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'test/CMakeLists.txt')
-rw-r--r--test/CMakeLists.txt8
1 files changed, 6 insertions, 2 deletions
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 15a9bfa..6f87cd5 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -18,10 +18,14 @@ target_include_directories(caresinternal
"${CMAKE_INSTALL_INCLUDEDIR}"
)
-target_link_libraries(caresinternal INTERFACE ${PROJECT_NAME}::cares_static)
+IF (CARES_STATIC)
+ target_link_libraries(caresinternal INTERFACE ${PROJECT_NAME}::cares_static)
+ELSE ()
+ target_link_libraries(caresinternal INTERFACE ${PROJECT_NAME}::cares)
+ENDIF ()
# Google Test and Mock
-set(GMOCK_DIR gmock-1.8.0)
+set(GMOCK_DIR gmock-1.11.0)
add_library(gmock STATIC
${GMOCK_DIR}/gmock-gtest-all.cc
${GMOCK_DIR}/gmock/gmock.h