vcpkg/ports/llvm/llvm_usage
Yury Bura 40449ff1cb
[llvm] update to 11.1.0, add features and fix issues (#16232)
* fix issue #16215

* add more projects and fix issue #16222

* add version

* exclude libc from default projects

* remove libc, add fland to default projects

* update to v11.1.0

* fix compiler-rt install path

* fix SHA for version 11.1.0

* fix libc++ install

* re-fix libc++ install

* fix pstl install

* fix flang's license file name

* install tools in tools/llvm, fix file names

* revert bin directory for libraries

* don't create clang sub-directory in llvm/tools

* overwrite version

* copy tool dependencies

* overwrite version

* remove vcpkg_copy_tools call

* overwrite version

* restore default features

* overwrite version

* overwrite version

* convert manifest to json

* install usage files

* overwrite version

* remove feature `default-projects`

* modernize CMake in usage files

* overwrite version

* update ordering

* override version
2021-04-13 15:17:17 -07:00

16 lines
522 B
Plaintext

The package llvm provides CMake targets:
find_package(LLVM CONFIG REQUIRED)
list(APPEND CMAKE_MODULE_PATH "${LLVM_CMAKE_DIR}")
include(HandleLLVMOptions)
add_definitions(${LLVM_DEFINITIONS})
target_include_directories(main PRIVATE ${LLVM_INCLUDE_DIRS})
# Find the libraries that correspond to the LLVM components that we wish to use
llvm_map_components_to_libnames(llvm_libs Support Core IRReader ...)
# Link against LLVM libraries
target_link_libraries(main PRIVATE ${llvm_libs})