diff options
author | Stella Laurenzo <laurenzo@google.com> | 2022-03-02 11:13:46 -0800 |
---|---|---|
committer | Stella Laurenzo <laurenzo@google.com> | 2022-03-02 11:13:46 -0800 |
commit | 7cdda6b8ce49ae3c90c068cff4dc355bba5d77f2 (patch) | |
tree | f9ce5b00d0105f213b0b6dc8e71661747635915f /llvm | |
parent | e81e5d788cd89e5e3f53caa1bd943639b6d8dc6a (diff) | |
download | llvm-7cdda6b8ce49ae3c90c068cff4dc355bba5d77f2.zip llvm-7cdda6b8ce49ae3c90c068cff4dc355bba5d77f2.tar.gz llvm-7cdda6b8ce49ae3c90c068cff4dc355bba5d77f2.tar.bz2 |
Revert "[cmake] Prefix gtest and gtest_main with "llvm_"."
lldb buildbot failure. will investigate and roll forward.
This reverts commit 9f37775472b45986b0ecce5243bd6ce119e5bd69.
Diffstat (limited to 'llvm')
-rw-r--r-- | llvm/cmake/modules/AddLLVM.cmake | 2 | ||||
-rw-r--r-- | llvm/lib/Testing/Support/CMakeLists.txt | 2 | ||||
-rw-r--r-- | llvm/runtimes/CMakeLists.txt | 4 | ||||
-rw-r--r-- | llvm/unittests/Support/CommandLineInit/CMakeLists.txt | 2 | ||||
-rw-r--r-- | llvm/utils/unittest/CMakeLists.txt | 12 | ||||
-rw-r--r-- | llvm/utils/unittest/UnitTestMain/CMakeLists.txt | 4 |
6 files changed, 13 insertions, 13 deletions
diff --git a/llvm/cmake/modules/AddLLVM.cmake b/llvm/cmake/modules/AddLLVM.cmake index 6827970..37bc98f 100644 --- a/llvm/cmake/modules/AddLLVM.cmake +++ b/llvm/cmake/modules/AddLLVM.cmake @@ -1502,7 +1502,7 @@ function(add_unittest test_suite test_name) # libpthreads overrides some standard library symbols, so main # executable must be linked with it in order to provide consistent # API for all shared libaries loaded by this executable. - target_link_libraries(${test_name} PRIVATE llvm_gtest_main llvm_gtest ${LLVM_PTHREAD_LIB}) + target_link_libraries(${test_name} PRIVATE gtest_main gtest ${LLVM_PTHREAD_LIB}) add_dependencies(${test_suite} ${test_name}) get_target_property(test_suite_folder ${test_suite} FOLDER) diff --git a/llvm/lib/Testing/Support/CMakeLists.txt b/llvm/lib/Testing/Support/CMakeLists.txt index 81774eb..1830ea8 100644 --- a/llvm/lib/Testing/Support/CMakeLists.txt +++ b/llvm/lib/Testing/Support/CMakeLists.txt @@ -12,7 +12,7 @@ add_llvm_library(LLVMTestingSupport Support ) -target_link_libraries(LLVMTestingSupport PRIVATE llvm_gtest) +target_link_libraries(LLVMTestingSupport PRIVATE gtest) # This is to avoid the error in gtest-death-test-internal.h # (150,16): error: 'Create' overrides a member function but diff --git a/llvm/runtimes/CMakeLists.txt b/llvm/runtimes/CMakeLists.txt index b99cb37..11391fa 100644 --- a/llvm/runtimes/CMakeLists.txt +++ b/llvm/runtimes/CMakeLists.txt @@ -480,8 +480,8 @@ if(runtimes) obj2yaml sancov sanstats - llvm_gtest_main - llvm_gtest + gtest_main + gtest ) foreach(target ${test_targets} ${SUB_CHECK_TARGETS}) add_dependencies(${target} ${RUNTIMES_TEST_DEPENDS}) diff --git a/llvm/unittests/Support/CommandLineInit/CMakeLists.txt b/llvm/unittests/Support/CommandLineInit/CMakeLists.txt index 1889c8f..a69182f 100644 --- a/llvm/unittests/Support/CommandLineInit/CMakeLists.txt +++ b/llvm/unittests/Support/CommandLineInit/CMakeLists.txt @@ -26,7 +26,7 @@ add_llvm_executable(${test_name} IGNORE_EXTERNALIZE_DEBUGINFO NO_INSTALL_RPATH CommandLineInitTest.cpp) -target_link_libraries(${test_name} PRIVATE llvm_gtest) +target_link_libraries(${test_name} PRIVATE gtest) add_dependencies(${test_suite} ${test_name}) diff --git a/llvm/utils/unittest/CMakeLists.txt b/llvm/utils/unittest/CMakeLists.txt index 9dd7b53..90037ae 100644 --- a/llvm/utils/unittest/CMakeLists.txt +++ b/llvm/utils/unittest/CMakeLists.txt @@ -39,7 +39,7 @@ if (LLVM_PTHREAD_LIBRARY_PATH) list(APPEND LIBS pthread) endif() -add_llvm_library(llvm_gtest +add_llvm_library(gtest googletest/src/gtest-all.cc googlemock/src/gmock-all.cc @@ -58,14 +58,14 @@ add_llvm_library(llvm_gtest # that warning here for any targets that link to gtest. if(CXX_SUPPORTS_SUGGEST_OVERRIDE_FLAG) add_definitions("-Wno-suggest-override") - set_target_properties(llvm_gtest PROPERTIES INTERFACE_COMPILE_OPTIONS "-Wno-suggest-override") + set_target_properties(gtest PROPERTIES INTERFACE_COMPILE_OPTIONS "-Wno-suggest-override") endif() if (NOT LLVM_ENABLE_THREADS) - target_compile_definitions(llvm_gtest PUBLIC GTEST_HAS_PTHREAD=0) + target_compile_definitions(gtest PUBLIC GTEST_HAS_PTHREAD=0) endif () -target_include_directories(llvm_gtest +target_include_directories(gtest PUBLIC googletest/include googlemock/include PRIVATE googletest googlemock ) @@ -89,5 +89,5 @@ function (gtest_remove_dylib_from_link_interface target) endif() endfunction() -gtest_remove_dylib_from_link_interface(llvm_gtest) -gtest_remove_dylib_from_link_interface(llvm_gtest_main) +gtest_remove_dylib_from_link_interface(gtest) +gtest_remove_dylib_from_link_interface(gtest_main) diff --git a/llvm/utils/unittest/UnitTestMain/CMakeLists.txt b/llvm/utils/unittest/UnitTestMain/CMakeLists.txt index 7a3ac8a..32f0f25 100644 --- a/llvm/utils/unittest/UnitTestMain/CMakeLists.txt +++ b/llvm/utils/unittest/UnitTestMain/CMakeLists.txt @@ -1,8 +1,8 @@ -add_llvm_library(llvm_gtest_main +add_llvm_library(gtest_main TestMain.cpp LINK_LIBS - llvm_gtest + gtest LINK_COMPONENTS Support # Depends on llvm::cl |