Skip to content

Commit 4d6bff4

Browse files
authored
[flang][rt] Add install target for header files (llvm#165610)
1 parent 3bc9b28 commit 4d6bff4

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

flang-rt/CMakeLists.txt

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,3 +330,19 @@ if (FLANG_RT_INCLUDE_TESTS)
330330
else ()
331331
add_custom_target(check-flang-rt)
332332
endif()
333+
334+
###################
335+
# Install headers #
336+
###################
337+
338+
if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
339+
add_llvm_install_targets(install-flang-rt-headers COMPONENT flang-rt-headers)
340+
341+
install(DIRECTORY include/flang-rt/runtime
342+
DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/flang-rt"
343+
COMPONENT flang-rt-headers
344+
FILES_MATCHING
345+
PATTERN "*.h"
346+
PATTERN ".git" EXCLUDE
347+
PATTERN "CMakeFiles" EXCLUDE)
348+
endif()

0 commit comments

Comments
 (0)