Skip to content

Commit ae89a20

Browse files
committed
Fix disabled flang_rt.quad.math
1 parent d88c4be commit ae89a20

File tree

2 files changed

+23
-22
lines changed

2 files changed

+23
-22
lines changed

flang-rt/lib/runtime/CMakeLists.txt

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -191,28 +191,29 @@ set_property(SOURCE
191191
)
192192

193193
# Import changes from flang_rt.quadmath
194-
get_target_property(f128_sources
195-
FortranFloat128MathILib INTERFACE_SOURCES
196-
)
197-
if (f128_sources)
198-
# The interface may define special macros for Float128Math files,
199-
# so we need to propagate them.
200-
get_target_property(f128_defs
201-
FortranFloat128MathILib INTERFACE_COMPILE_DEFINITIONS
202-
)
203-
set_property(SOURCE ${f128_sources}
204-
APPEND PROPERTY COMPILE_DEFINITIONS
205-
${f128_defs}
206-
)
207-
get_target_property(f128_include_dirs
208-
FortranFloat128MathILib INTERFACE_INCLUDE_DIRECTORIES
194+
set(f128_sources "")
195+
if (TARGET f128_sources)
196+
get_target_property(f128_sources
197+
FortranFloat128MathILib INTERFACE_SOURCES
209198
)
210-
set_property(SOURCE ${f128_sources}
211-
APPEND PROPERTY INCLUDE_DIRECTORIES
212-
${f128_include_dirs}
213-
)
214-
else ()
215-
set(f128_sources "")
199+
if (f128_sources)
200+
# The interface may define special macros for Float128Math files,
201+
# so we need to propagate them.
202+
get_target_property(f128_defs
203+
FortranFloat128MathILib INTERFACE_COMPILE_DEFINITIONS
204+
)
205+
set_property(SOURCE ${f128_sources}
206+
APPEND PROPERTY COMPILE_DEFINITIONS
207+
${f128_defs}
208+
)
209+
get_target_property(f128_include_dirs
210+
FortranFloat128MathILib INTERFACE_INCLUDE_DIRECTORIES
211+
)
212+
set_property(SOURCE ${f128_sources}
213+
APPEND PROPERTY INCLUDE_DIRECTORIES
214+
${f128_include_dirs}
215+
)
216+
endif ()
216217
endif ()
217218

218219
if (NOT FLANG_RT_ENABLE_STATIC AND NOT FLANG_RT_ENABLE_SHARED)

openmp/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ else()
160160
get_clang_resource_dir(LIBOMP_HEADERS_INSTALL_PATH SUBDIR include)
161161
endif()
162162

163-
if(LIBOMP_FORTRUNTIMES_FLANG_MODULES_ENABLEDRAN_MODULES)
163+
if(RUNTIMES_FLANG_MODULES_ENABLED)
164164
add_subdirectory(module)
165165
else()
166166
message(STATUS "Building omp_lib.mod disabled by RUNTIMES_FLANG_MODULES_ENABLED='${RUNTIMES_FLANG_MODULES_ENABLED}'; libomp-mod does nothing")

0 commit comments

Comments
 (0)