[flang-commits] [flang] [flang] Fix distribution build of Fortran builtin/intrinsic modules. (PR #184204)
Daniel Chen via flang-commits
flang-commits at lists.llvm.org
Mon Mar 2 11:00:40 PST 2026
https://github.com/DanielCChen created https://github.com/llvm/llvm-project/pull/184204
Currently, `-DLLVM_DISTRIBUTION_COMPONENTS="flang-module-interfaces"` doesn't work. It failed to build the Fortran builtin/intrinsic modules as distribution build, `install-distribution`.
This PR is to fix that.
>From 008c109d00e085d5b9231535530df13275ff3261 Mon Sep 17 00:00:00 2001
From: Daniel Chen <cdchen at ca.ibm.com>
Date: Mon, 2 Mar 2026 13:49:31 -0500
Subject: [PATCH] [flang] Fix distribution build of Fortran builtin/intrinsic
modules.
---
flang/tools/f18/CMakeLists.txt | 2 ++
1 file changed, 2 insertions(+)
diff --git a/flang/tools/f18/CMakeLists.txt b/flang/tools/f18/CMakeLists.txt
index 74b329f6c6c03..900b341e85c58 100644
--- a/flang/tools/f18/CMakeLists.txt
+++ b/flang/tools/f18/CMakeLists.txt
@@ -142,8 +142,10 @@ if (NOT CMAKE_CROSSCOMPILING)
else()
message(WARNING "Not building omp_lib.mod, no OpenMP runtime in either LLVM_ENABLE_PROJECTS or LLVM_ENABLE_RUNTIMES")
endif()
+ add_custom_target(flang-module-interfaces ALL DEPENDS module_files)
add_llvm_install_targets(install-flang-module-interfaces
COMPONENT flang-module-interfaces)
+ add_dependencies(install-flang-module-interfaces flang-module-interfaces)
endif()
add_custom_target(module_files ALL DEPENDS ${MODULE_FILES})
More information about the flang-commits
mailing list