From 1bda00e358ce39e9f3083875b05610b85ec294e3 Mon Sep 17 00:00:00 2001 From: Wenju He Date: Thu, 3 Aug 2023 16:57:13 +0800 Subject: [PATCH] Only link clang libraries that are directly used (#473) Other dependent clang libraries, e.g. those clangFrontendTool depends, will be automatically added by cmake. --- CMakeLists.txt | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e50e440..2a68665 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -264,37 +264,9 @@ if(USE_PREBUILT_LLVM OR CLANG_LINK_CLANG_DYLIB) list(APPEND OPENCL_CLANG_LINK_LIBS clang-cpp) else() list(APPEND OPENCL_CLANG_LINK_LIBS -# The list of clang libraries is taken from clang makefile -# (build/tools/clang/tools/driver/CMakeFiles/clang.dir/link.txt) -# All duplicate libraries are there on purpose clangBasic - clangCodeGen - clangDriver clangFrontend clangFrontendTool - clangCodeGen - clangRewriteFrontend - clangARCMigrate - clangStaticAnalyzerFrontend - clangStaticAnalyzerCheckers - clangStaticAnalyzerCore - clangCrossTU - clangIndex - clangFrontend - clangDriver - clangParse - clangSerialization - clangSema - clangAnalysis - clangEdit - clangFormat - clangToolingInclusions - clangToolingCore - clangRewrite - clangASTMatchers - clangAST - clangLex - clangBasic ) endif()