diff --git a/.gitmodules b/.gitmodules index dc0798c32..0b9942ec3 100644 --- a/.gitmodules +++ b/.gitmodules @@ -4,8 +4,10 @@ branch = main [submodule "ccpp-physics"] path = ccpp/physics - url = https://github.com/NCAR/ccpp-physics - branch = main + #url = https://github.com/NCAR/ccpp-physics + #branch = main + url = https://github.com/climbfuji/ccpp-physics + branch = feature/ip5 [submodule "CMakeModules"] path = CMakeModules url = https://github.com/noaa-emc/CMakeModules diff --git a/ccpp/physics b/ccpp/physics index f0fbb34a3..be05d12e0 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit f0fbb34a350acac90e71de6e51351f78174eb8de +Subproject commit be05d12e00fc51722084ad75c044e19d25c0b6d0 diff --git a/scm/src/CMakeLists.txt b/scm/src/CMakeLists.txt index 4938e1b57..eb1871f75 100644 --- a/scm/src/CMakeLists.txt +++ b/scm/src/CMakeLists.txt @@ -69,7 +69,11 @@ SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/../../CMakeModule find_package(NetCDF REQUIRED COMPONENTS C Fortran) find_package(bacio REQUIRED) -find_package(sp REQUIRED) +# Use ip@5 or later if available, fall back to sp +find_package(ip 5) +if(NOT ip_FOUND) + find_package(sp REQUIRED) +endif() find_package(w3emc REQUIRED) find_package(MPI REQUIRED) if(NOT MPI_Fortran_HAVE_F08_MODULE) @@ -302,7 +306,11 @@ if(OPENMP) endif() TARGET_LINK_LIBRARIES(scm NetCDF::NetCDF_Fortran) TARGET_LINK_LIBRARIES(scm bacio::bacio_4) -TARGET_LINK_LIBRARIES(scm sp::sp_d) +if(ip_FOUND) + target_link_libraries(scm ip::ip_d) +else() + target_link_libraries(scm sp::sp_d) +endif() TARGET_LINK_LIBRARIES(scm w3emc::w3emc_d) TARGET_LINK_LIBRARIES(scm ccpp_framework) TARGET_LINK_LIBRARIES(scm ccpp_physics)