Commit 56fdbc0a authored by nomme's avatar nomme Committed by Alastair Robertson

Support for split LLVM libs (#230)

Support for split LLVM libs

Support for split LLVM libs is added since Gentoo does not distribute a
combined LLVM library.
parent 62e712a5
...@@ -36,5 +36,14 @@ if (STATIC_LINKING) ...@@ -36,5 +36,14 @@ if (STATIC_LINKING)
target_link_libraries(ast ${clang_libs}) target_link_libraries(ast ${clang_libs})
target_link_libraries(ast ${llvm_libs}) target_link_libraries(ast ${llvm_libs})
else() else()
target_link_libraries(ast LLVM libclang) find_library(found_LLVM LLVM)
if(found_LLVM)
target_link_libraries(ast LLVM)
else()
llvm_map_components_to_libnames(_llvm_libs bpfcodegen ipo irreader mcjit orcjit ${LLVM_TARGETS_TO_BUILD})
llvm_expand_dependencies(llvm_libs ${_llvm_libs})
target_link_libraries(ast ${llvm_libs})
endif()
target_link_libraries(ast libclang)
endif() endif()
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment