Skip to content
Closed
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
8 changes: 6 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ list(REMOVE_DUPLICATES CAPS)

# Schemes and caps from the CCPP code generator use full paths with symlinks
# resolved, we need to do the same here for the below logic to work
get_filename_component(FULL_PATH_TO_CMAKELISTS CMakeLists.txt REALPATH BASE_DIR ${LOCAL_CURRENT_SOURCE_DIR})
get_filename_component(FULL_PATH_TO_CMAKELISTS CMakeLists.txt REALPATH)
get_filename_component(LOCAL_CURRENT_SOURCE_DIR ${FULL_PATH_TO_CMAKELISTS} DIRECTORY)

#------------------------------------------------------------------------------
Expand Down Expand Up @@ -186,8 +186,12 @@ set_target_properties(ccpp_physics PROPERTIES VERSION ${PROJECT_VERSION}
target_include_directories(ccpp_physics PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>)

if(ip_FOUND)
target_link_libraries(ccpp_physics PUBLIC ip::ip_d)
else()
target_link_libraries(ccpp_physics PUBLIC sp::sp_d)
endif()
target_link_libraries(ccpp_physics PUBLIC w3emc::w3emc_d
sp::sp_d
NetCDF::NetCDF_Fortran)

# Define where to install the library
Expand Down