Skip to content

Commit

Permalink
[Polly] Fix gtest logic for standalone builds (#121114)
Browse files Browse the repository at this point in the history
Fix the gtest logic to account for llvm_gtest being installed as part of
LLVM, as of 91b3ca3.
  • Loading branch information
mgorny authored Dec 26, 2024
1 parent a72bfc5 commit 03093b6
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions polly/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,7 @@ if(POLLY_STANDALONE_BUILD)

# Enable unit tests if available.
set(POLLY_GTEST_AVAIL 0)
set(UNITTEST_DIR ${LLVM_THIRD_PARTY_DIR}/unittest)
if(EXISTS ${UNITTEST_DIR}/googletest/include/gtest/gtest.h)
if (NOT TARGET gtest)
add_subdirectory(${UNITTEST_DIR} third-party/unittest)
endif()
if(TARGET llvm_gtest)
set(POLLY_GTEST_AVAIL 1)
endif()

Expand Down

0 comments on commit 03093b6

Please sign in to comment.