[PATCH] D71674: [clang-tools-extra] Fix linking dylib for LLVMFrontendOpenMP

Michał Górny via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 18 13:22:25 PST 2019


mgorny created this revision.
mgorny added reviewers: baloghadamsoftware, jdoerfert, ABataev.
Herald added subscribers: lebedev.ri, guansong, rnkovacs.
Herald added a reviewer: lebedev.ri.

Use LLVM_LINK_COMPONENTS to link the FrontendOpenMP library
instead of passing it explicitly to LINK_LIBS.  This fixes duplicating
the library when clang-tidy is linked to LLVM dylib.


https://reviews.llvm.org/D71674

Files:
  clang-tools-extra/clang-tidy/openmp/CMakeLists.txt


Index: clang-tools-extra/clang-tidy/openmp/CMakeLists.txt
===================================================================
--- clang-tools-extra/clang-tidy/openmp/CMakeLists.txt
+++ clang-tools-extra/clang-tidy/openmp/CMakeLists.txt
@@ -1,4 +1,6 @@
-set(LLVM_LINK_COMPONENTS support)
+set(LLVM_LINK_COMPONENTS
+  FrontendOpenMP
+  Support)
 
 add_clang_library(clangTidyOpenMPModule
   ExceptionEscapeCheck.cpp
@@ -11,5 +13,4 @@
   clangBasic
   clangTidy
   clangTidyUtils
-  LLVMFrontendOpenMP
   )


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D71674.234604.patch
Type: text/x-patch
Size: 504 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191218/fbd8f3c7/attachment-0001.bin>


More information about the cfe-commits mailing list