[llvm] r310590 - [CMake][LLVM] Remove duplicated library mask. Broken clang linking against clangShared

Oleg Ranevskyy via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 10 06:37:58 PDT 2017


Author: oleg
Date: Thu Aug 10 06:37:58 2017
New Revision: 310590

URL: http://llvm.org/viewvc/llvm-project?rev=310590&view=rev
Log:
[CMake][LLVM] Remove duplicated library mask. Broken clang linking against clangShared

Summary:
The `LLVM${c}Info` mask is listed twice in LLVM-Config.cmake. This results in the libraries such as LLVMARMInfo, LLVMAArch4Info, etc appearing twice in `extract_symbols.py` command line while building `clangShared`. `Extract_symbols.py` does not work well in such a case and completely ignores the symbols from the duplicated libraries. Thus, the LLVM(...)Info symbols do not get exported from `clangShared` and linking clang against it fails with unresolved dependencies.

Seems to be a mere copy-paste mistake.

Reviewers: beanz, chapuni

Reviewed By: chapuni

Subscribers: chapuni, aemerson, mgorny, kristof.beyls, llvm-commits, asl

Differential Revision: https://reviews.llvm.org/D36119

Modified:
    llvm/trunk/cmake/modules/LLVM-Config.cmake

Modified: llvm/trunk/cmake/modules/LLVM-Config.cmake
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/cmake/modules/LLVM-Config.cmake?rev=310590&r1=310589&r2=310590&view=diff
==============================================================================
--- llvm/trunk/cmake/modules/LLVM-Config.cmake (original)
+++ llvm/trunk/cmake/modules/LLVM-Config.cmake Thu Aug 10 06:37:58 2017
@@ -175,18 +175,15 @@ function(llvm_map_components_to_libnames
           message(FATAL_ERROR "Target ${c} is not in the set of libraries.")
         endif()
       endif()
-      if( TARGET LLVM${c}AsmPrinter )
-        list(APPEND expanded_components "LLVM${c}AsmPrinter")
-      endif()
       if( TARGET LLVM${c}AsmParser )
         list(APPEND expanded_components "LLVM${c}AsmParser")
       endif()
+      if( TARGET LLVM${c}AsmPrinter )
+        list(APPEND expanded_components "LLVM${c}AsmPrinter")
+      endif()
       if( TARGET LLVM${c}Desc )
         list(APPEND expanded_components "LLVM${c}Desc")
       endif()
-      if( TARGET LLVM${c}Info )
-        list(APPEND expanded_components "LLVM${c}Info")
-      endif()
       if( TARGET LLVM${c}Disassembler )
         list(APPEND expanded_components "LLVM${c}Disassembler")
       endif()




More information about the llvm-commits mailing list