[PATCH] D142449: [clang] Fix linking to LLVMTestingAnnotations in standalone build

Michał Górny via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 24 04:21:57 PST 2023


This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG0f8b995b6362: [clang] Fix linking to LLVMTestingAnnotations in standalone build (authored by mgorny).
Herald added a project: clang.

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D142449/new/

https://reviews.llvm.org/D142449

Files:
  clang/unittests/CMakeLists.txt


Index: clang/unittests/CMakeLists.txt
===================================================================
--- clang/unittests/CMakeLists.txt
+++ clang/unittests/CMakeLists.txt
@@ -2,7 +2,12 @@
 set_target_properties(ClangUnitTests PROPERTIES FOLDER "Clang tests")
 
 if(CLANG_BUILT_STANDALONE)
-  # LLVMTestingSupport library is needed for some of the unittests.
+  # LLVMTesting* libraries are needed for some of the unittests.
+  if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations
+      AND NOT TARGET LLVMTestingAnnotations)
+    add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations
+      lib/Testing/Annotations)
+  endif()
   if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Support
       AND NOT TARGET LLVMTestingSupport)
     add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Support


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D142449.491712.patch
Type: text/x-patch
Size: 804 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230124/1e9a21dc/attachment.bin>


More information about the cfe-commits mailing list