Skip to content

Commit

Permalink
Merge pull request #57 from COSIMA/sync_components
Browse files Browse the repository at this point in the history
Sync OM3 codebase and build system with CESM
  • Loading branch information
micaeljtoliveira authored Aug 16, 2023
2 parents 0fb7fc2 + 6de1756 commit 1078036
Show file tree
Hide file tree
Showing 23 changed files with 436 additions and 11,270 deletions.
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[submodule "MOM6/MOM6"]
path = MOM6/MOM6
url = https://github.com/mom-ocean/MOM6
url = https://github.com/NCAR/MOM6.git
[submodule "CICE6/CICE6"]
path = CICE/CICE
url = https://github.com/ESCOMP/CICE
Expand Down
2 changes: 1 addition & 1 deletion CDEPS/CDEPS
Submodule CDEPS updated 52 files
+0 −71 .github/actions/buildesmf/action.yml
+0 −35 .github/actions/buildnetcdff/action.yml
+0 −78 .github/actions/buildpio/action.yml
+0 −30 .github/actions/buildpnetcdf/action.yml
+1 −1 .github/workflows/bumpversion.yml
+88 −72 .github/workflows/extbuild.yml
+13 −19 CMakeLists.txt
+1 −1 README.md
+46 −92 cime_config/buildlib
+3 −0 datm/CMakeLists.txt
+26 −70 datm/atm_comp_nuopc.F90
+9 −13 datm/datm_datamode_cfsr_mod.F90
+9 −19 datm/datm_datamode_clmncep_mod.F90
+2 −2 datm/datm_datamode_cplhist_mod.F90
+10 −15 datm/datm_datamode_era5_mod.F90
+10 −16 datm/datm_datamode_gefs_mod.F90
+3 −0 dice/CMakeLists.txt
+14 −38 dice/ice_comp_nuopc.F90
+3 −0 dlnd/CMakeLists.txt
+13 −27 dlnd/lnd_comp_nuopc.F90
+41 −51 doc/source/conf.py
+27 −48 doc/source/datm.rst
+54 −154 doc/source/design_details.rst
+0 −57 doc/source/dice.rst
+0 −58 doc/source/dlnd.rst
+0 −116 doc/source/docn.rst
+0 −115 doc/source/drof.rst
+0 −61 doc/source/dwav.rst
+0 −273 doc/source/extending.rst
+1 −7 doc/source/index.rst
+17 −25 doc/source/introduction.rst
+127 −259 doc/source/streams.rst
+3 −0 docn/CMakeLists.txt
+12 −35 docn/ocn_comp_nuopc.F90
+3 −0 drof/CMakeLists.txt
+13 −27 drof/rof_comp_nuopc.F90
+2 −1 dshr/CMakeLists.txt
+9 −11 dshr/dshr_dfield_mod.F90
+42 −60 dshr/dshr_mod.F90
+3 −0 dwav/CMakeLists.txt
+12 −26 dwav/wav_comp_nuopc.F90
+1 −0 share/CMakeLists.txt
+11 −5 share/shr_abort_mod.F90
+3 −4 share/shr_assert_mod.F90.in
+1 −0 share/shr_infnan_mod.F90.in
+24 −40 share/shr_log_mod.F90
+2,217 −0 share/shr_mpi_mod.F90
+12 −15 share/shr_orb_mod.F90
+1 −1 streams/CMakeLists.txt
+2 −2 streams/dshr_methods_mod.F90
+29 −41 streams/dshr_strdata_mod.F90
+3 −10 streams/dshr_stream_mod.F90
32 changes: 8 additions & 24 deletions CDEPS/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,3 @@
# CDEPS compiler flags
if(CMAKE_Fortran_COMPILER_ID MATCHES "GNU")
set(fortran_compile_flags -ffree-line-length-none)
if(${CMAKE_Fortran_COMPILER_VERSION} VERSION_GREATER_EQUAL 10)
list(APPEND fortran_compile_flags -fallow-argument-mismatch -fallow-invalid-boz)
endif()
set(fortran_compile_flags_debug -fcheck=bounds -ffpe-trap=invalid,zero,overflow,underflow)
elseif(CMAKE_Fortran_COMPILER_ID MATCHES "Intel")
set(fortran_compile_flags -O -assume realloc_lhs)
set(fortran_compile_flags_release -fp-model precise)
set(fortran_compile_flags_debug -check "SHELL:-check noarg_temp_created" "SHELL:-check nopointer" -fpe0 -ftrapuv -init=snan,arrays)
endif()

add_subdirectory(fox)

list(APPEND cdeps_common_src_files
Expand All @@ -22,7 +9,13 @@ list(APPEND cdeps_common_src_files
CDEPS/dshr/dshr_dfield_mod.F90
CDEPS/dshr/dshr_fldlist_mod.F90
CDEPS/dshr/dshr_mod.F90
)

list(APPEND cdeps_drof_src_files
CDEPS/drof/rof_comp_nuopc.F90
)

list(APPEND cdeps_datm_src_files
CDEPS/datm/atm_comp_nuopc.F90
CDEPS/datm/datm_datamode_cfsr_mod.F90
CDEPS/datm/datm_datamode_clmncep_mod.F90
Expand All @@ -31,12 +24,9 @@ list(APPEND cdeps_common_src_files
CDEPS/datm/datm_datamode_era5_mod.F90
CDEPS/datm/datm_datamode_gefs_mod.F90
CDEPS/datm/datm_datamode_jra_mod.F90

CDEPS/dlnd/lnd_comp_nuopc.F90

CDEPS/drof/rof_comp_nuopc.F90
)


list(APPEND cdeps_docn_src_files
CDEPS/docn/docn_datamode_aquaplanet_mod.F90
CDEPS/docn/docn_datamode_copyall_mod.F90
Expand All @@ -57,16 +47,10 @@ list(APPEND cdeps_dwav_src_files

add_fortran_library(cdeps_common mod STATIC ${cdeps_common_src_files})
target_include_directories(cdeps_common PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/fox/include>)
target_compile_options(cdeps_common PRIVATE "$<$<COMPILE_LANGUAGE:Fortran>:${fortran_compile_flags}>")
target_compile_options(cdeps_common PRIVATE "$<$<AND:$<CONFIG:Debug>,$<COMPILE_LANGUAGE:Fortran>>:${fortran_compile_flags_debug}>")
target_compile_options(cdeps_common PRIVATE "$<$<AND:$<CONFIG:Release>,$<COMPILE_LANGUAGE:Fortran>>:${fortran_compile_flags_release}>")
target_link_libraries(cdeps_common PUBLIC share cmeps esmf PIO::PIO_Fortran FoX_dom)

foreach(LIB cdeps_docn cdeps_dice cdeps_dwav)
foreach(LIB cdeps_docn cdeps_dice cdeps_dwav cdeps_drof cdeps_datm)
add_fortran_library(${LIB} ${LIB}/mod STATIC ${${LIB}_src_files})
target_include_directories(${LIB} PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/fox/include>)
target_compile_options(${LIB} PRIVATE "$<$<COMPILE_LANGUAGE:Fortran>:${fortran_compile_flags}>")
target_compile_options(${LIB} PRIVATE "$<$<AND:$<CONFIG:Debug>,$<COMPILE_LANGUAGE:Fortran>>:${fortran_compile_flags_debug}>")
target_compile_options(${LIB} PRIVATE "$<$<AND:$<CONFIG:Release>,$<COMPILE_LANGUAGE:Fortran>>:${fortran_compile_flags_release}>")
target_link_libraries(${LIB} PUBLIC share cmeps esmf PIO::PIO_Fortran FoX_dom cdeps_common)
endforeach()
6 changes: 0 additions & 6 deletions CDEPS/share/dtypes.h

This file was deleted.

Loading

0 comments on commit 1078036

Please sign in to comment.