Add NOT APPLE condition to linker option guard (#5369)

This commit is contained in:
Matthias Krack 2026-06-07 14:41:19 +02:00 committed by GitHub
parent c6fe882990
commit 9c2e77385f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -226,6 +226,8 @@ if(CMAKE_C_COMPILER_ID STREQUAL "Cray" AND CMAKE_C_COMPILER_VERSION
endif()
# Suppress GFortran runtime warnings when LIBXS provides the wrapper
if(CMAKE_Fortran_COMPILER_ID STREQUAL "GNU" AND CP2K_USE_LIBXS)
if(CMAKE_Fortran_COMPILER_ID STREQUAL "GNU"
AND CP2K_USE_LIBXS
AND NOT APPLE)
add_link_options("-Wl,--wrap=_gfortran_runtime_warning_at")
endif()