[flang-commits] [flang] 4605ba0 - [flang] Link libflangPasses against correct libraries

via flang-commits flang-commits at lists.llvm.org
Wed Oct 9 12:09:20 PDT 2024


Author: Tarun Prabhu
Date: 2024-10-09T13:09:17-06:00
New Revision: 4605ba0437728ecf8233ba6dbb52ffba30a22743

URL: https://github.com/llvm/llvm-project/commit/4605ba0437728ecf8233ba6dbb52ffba30a22743
DIFF: https://github.com/llvm/llvm-project/commit/4605ba0437728ecf8233ba6dbb52ffba30a22743.diff

LOG: [flang] Link libflangPasses against correct libraries

libflangPasses.so was not linked against the correct libraries which
caused a build failure with -DBUILD_SHARED_LIBS=On. Fixes #110425

Added: 
    

Modified: 
    flang/lib/Optimizer/Passes/CMakeLists.txt

Removed: 
    


################################################################################
diff  --git a/flang/lib/Optimizer/Passes/CMakeLists.txt b/flang/lib/Optimizer/Passes/CMakeLists.txt
index 3df988940e005f..40abbdfbdd6511 100644
--- a/flang/lib/Optimizer/Passes/CMakeLists.txt
+++ b/flang/lib/Optimizer/Passes/CMakeLists.txt
@@ -1,3 +1,6 @@
+get_property(dialect_libs GLOBAL PROPERTY MLIR_DIALECT_LIBS)
+get_property(extension_libs GLOBAL PROPERTY MLIR_EXTENSION_LIBS)
+
 add_flang_library(flangPasses
   CommandLineOpts.cpp
   Pipelines.cpp
@@ -9,6 +12,8 @@ add_flang_library(flangPasses
   FIRCodeGen
   FIRTransforms
   FlangOpenMPTransforms
+  ${dialect_libs}
+  ${extension_libs}
   FortranCommon
   HLFIRTransforms
   MLIRPass


        


More information about the flang-commits mailing list