mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-01 04:49:02 +08:00
37 lines
914 B
Diff
37 lines
914 B
Diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
index 8ac1646..c081d3d 100644
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -38,6 +38,6 @@ endif()
|
|
|
|
if(UTF8_TESTS)
|
|
enable_testing()
|
|
- add_subdirectory(extern/gtest)
|
|
+ find_package(GTest CONFIG REQUIRED)
|
|
add_subdirectory(tests)
|
|
endif()
|
|
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
|
|
index 06e0d7e..4ee6dd8 100644
|
|
--- a/tests/CMakeLists.txt
|
|
+++ b/tests/CMakeLists.txt
|
|
@@ -15,16 +15,16 @@ add_executable(noexceptionstests
|
|
target_link_libraries(negative PRIVATE utf8::cpp)
|
|
target_link_libraries(cpp11 PRIVATE
|
|
utf8::cpp
|
|
- gtest_main
|
|
+ GTest::gtest_main
|
|
)
|
|
target_link_libraries(apitests PRIVATE
|
|
utf8::cpp
|
|
- gtest_main
|
|
+ GTest::gtest_main
|
|
)
|
|
|
|
target_link_libraries(noexceptionstests PRIVATE
|
|
utf8::cpp
|
|
- gtest_main
|
|
+ GTest::gtest_main
|
|
)
|
|
target_compile_options(noexceptionstests PUBLIC -fno-exceptions)
|
|
|