Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/external/esmf_time_f90/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,12 @@ add_library(esmf ${_esmf_time_src})
mpas_fortran_target(esmf)
add_library(${PROJECT_NAME}::external::esmf ALIAS esmf)

# This library is MPAS's bundled ESMF time-manager stubs, not the full ESMF. Naming the
# file libesmf lets the loader substitute a real ESMF found via LD_LIBRARY_PATH,
# breaking every MPAS executable. Changing the output name results in the library
# being installed as libesmf_time.{so,a} and resolves the name conflict.
set_target_properties(esmf PROPERTIES OUTPUT_NAME esmf_time)

target_compile_definitions(esmf PRIVATE HIDE_MPI=1)

target_include_directories(esmf PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>)
Expand Down