We are seeing an issue using Intel Fortran and Fortran as the Linker Languge. We came across the issue where we wanted to add the headerpad_max_install_names flag to the linker. In the Darwin.cmake file, Fortran is ignored… was this just overlooked?
Darwin.cmake:
foreach(lang C CXX OBJC OBJCXX)
set(CMAKE_${lang}_OSX_COMPATIBILITY_VERSION_FLAG "-compatibility_version ")
set(CMAKE_${lang}_OSX_CURRENT_VERSION_FLAG "-current_version ")
set(CMAKE_${lang}_LINK_FLAGS "-Wl,-headerpad_max_install_names")
if(HAVE_FLAG_SEARCH_PATHS_FIRST)
set(CMAKE_${lang}_LINK_FLAGS "-Wl,-search_paths_first ${CMAKE_${lang}_LINK_FLAGS}")
endif()
set(CMAKE_SHARED_LIBRARY_CREATE_${lang}_FLAGS "-dynamiclib -Wl,-headerpad_max_install_names")
set(CMAKE_SHARED_MODULE_CREATE_${lang}_FLAGS "-bundle -Wl,-headerpad_max_install_names")
set(CMAKE_SHARED_MODULE_LOADER_${lang}_FLAG "-Wl,-bundle_loader,")
endforeach()