[flang] Add install target to install flang headers (#78151)

This makes it more convenient to install flang without using the general
`ninja install` to install everything.

To install flang-new and associated things one needs `ninja
install-flang-new install-flang-libraries install-flang-headers`.
This commit is contained in:
Tom Eccles 2024-01-16 17:04:52 +00:00 committed by GitHub
parent 847c787269
commit 03f260fd83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -474,6 +474,9 @@ if (FLANG_LIBS)
endif()
if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
add_llvm_install_targets(install-flang-headers
COMPONENT flang-headers)
install(DIRECTORY include/flang
DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
COMPONENT flang-headers