-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update model level build system to work with UFS Coastal (#122)
* extra work to make it run under UFS * add target to idry_e to use in the cap * enable utilities * fix pre processing build
- Loading branch information
1 parent
5d92ec6
commit c5cd940
Showing
11 changed files
with
180 additions
and
177 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,11 @@ | ||
|
||
add_custom_target(utility) | ||
add_subdirectory( UtilLib) | ||
add_subdirectory( Combining_Scripts ) | ||
add_subdirectory( Post-Processing-Fortran ) | ||
add_subdirectory( Pre-Processing ) | ||
add_subdirectory( Tides ) | ||
add_subdirectory( OneWayNestScripts ) | ||
add_subdirectory( Particle_Tracking ) | ||
add_subdirectory( Gen_Hotstart ) | ||
add_subdirectory( Grid_Scripts) | ||
|
||
add_dependencies(utility utillib) | ||
|
||
|
||
# Currently a link problem with NCOM | ||
# add_subdirectory( NCOM ) | ||
|
||
#add_subdirectory( ArcGIS ) | ||
add_subdirectory(UtilLib) | ||
add_subdirectory(Combining_Scripts) | ||
add_subdirectory(Post-Processing-Fortran) | ||
add_subdirectory(Pre-Processing) | ||
add_subdirectory(Tides) | ||
add_subdirectory(OneWayNestScripts) | ||
add_subdirectory(Particle_Tracking) | ||
add_subdirectory(Gen_Hotstart) | ||
add_subdirectory(Grid_Scripts) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
message(STATUS "In /Utility NetCDF_LIBS ${NetCDFLIBS}") | ||
add_definitions(${C_PREPROCESS_FLAG}) | ||
add_executable( combine_gr3 combine_gr3.f90 ) | ||
#add_executable( combine_outHA combine_outHA.f90 ) | ||
add_executable( combine_hotstart7 combine_hotstart7.f90 ) | ||
##add_executable( combine_output10 combine_output10.f90 netcdf_var_names.f90) | ||
add_executable( combine_output11 combine_output11.f90 netcdf_var_names.f90) | ||
|
||
target_link_libraries (combine_hotstart7 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
##target_link_libraries (combine_output10 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (combine_output11 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
add_executable(combine_gr3 combine_gr3.f90) | ||
add_executable(combine_hotstart7 combine_hotstart7.f90) | ||
add_executable(combine_output11 combine_output11.f90 netcdf_var_names.f90) | ||
|
||
target_link_libraries(combine_hotstart7 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries(combine_output11 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
|
||
add_dependencies(utility combine_gr3 combine_hotstart7 combine_output11) | ||
target_include_directories(combine_hotstart7 PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
target_include_directories(combine_output11 PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
|
||
add_dependencies(combine_gr3 utillib) | ||
add_dependencies(combine_hotstart7 utillib) | ||
add_dependencies(combine_output11 utillib) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,17 @@ | ||
message(STATUS "In Utility/Gen_Hotstart") | ||
|
||
add_executable( convert_hotstart_nc convert_hotstart_nc.f90 ) | ||
# set list of files | ||
set(gen_hotstart_file_list | ||
convert_hotstart_nc.f90 | ||
gen_hot_3Dth_from_hycom.f90 | ||
gen_hot_from_hycom.f90 | ||
gen_3Dth_from_hycom.f90) | ||
|
||
# Removed from cmake because it contains huge arrays and kind of forces mcmodel=medium and doesn't | ||
# necessarily compile gracefully even with that. Below are some flags to add these things on a | ||
# file specific basis, but that isn't working yet. | ||
add_executable( gen_hot_3Dth_from_hycom gen_hot_3Dth_from_hycom.f90) | ||
add_executable( gen_hot_from_hycom gen_hot_from_hycom.f90) | ||
add_executable( gen_3Dth_from_hycom gen_3Dth_from_hycom.f90) | ||
# target_compile_options(gen_hot_3Dth_from_hycom PRIVATE "-O2 -CB -mcmodel=medium") | ||
# target_link_options(gen_hot_3Dth_from_hycom PRIVATE "-mcmodel=medium -CB") | ||
|
||
target_link_libraries (convert_hotstart_nc utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (gen_hot_3Dth_from_hycom utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (gen_hot_from_hycom utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (gen_3Dth_from_hycom utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
|
||
add_dependencies(utility convert_hotstart_nc gen_hot_3Dth_from_hycom gen_hot_from_hycom gen_3Dth_from_hycom) | ||
# define executables and their dependencies | ||
foreach(f ${gen_hotstart_file_list}) | ||
get_filename_component(fwe ${f} NAME_WE) | ||
add_executable(${fwe} ${f}) | ||
target_include_directories(${fwe} PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
target_link_libraries(${fwe} utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
add_dependencies(${fwe} utillib) | ||
endforeach() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,17 @@ | ||
message(STATUS "In Utility/Grid_Scripts") | ||
|
||
add_executable( cpp_bp cpp_bp.f90) | ||
add_executable( cpp cpp.f90) | ||
add_executable( arctic_stereo arctic_stereo.f90) | ||
add_executable( grid_spring grid_spring.f90) | ||
add_executable( grid_subsampler grid_subsampler.f) | ||
add_executable( interpolate_depth_structured2 interpolate_depth_structured2.f90) | ||
add_executable( interpolate_unstructured interpolate_unstructured.f90) | ||
add_executable( periodic_grid periodic_grid.f90) | ||
add_executable( gen_boundary_global gen_boundary_global.f90) | ||
add_executable( check_lonlat_grid check_lonlat_grid.f90) | ||
add_executable( mergegrid5 mergegrid5.f90) | ||
|
||
target_link_libraries (mergegrid5 utillib) | ||
#mpi_wrap( combine_output6 combine_output5 combine_output4 ) | ||
#add_dependencies(utility cpp_bp cpp grid_spring grid_subsampler interpolate_unstructured periodic_grid gen_boundary_global check_lonlat_grid mergegrid5) | ||
add_executable(cpp_bp cpp_bp.f90) | ||
add_executable(cpp cpp.f90) | ||
add_executable(arctic_stereo arctic_stereo.f90) | ||
add_executable(grid_spring grid_spring.f90) | ||
add_executable(grid_subsampler grid_subsampler.f) | ||
add_executable(interpolate_depth_structured2 interpolate_depth_structured2.f90) | ||
add_executable(interpolate_unstructured interpolate_unstructured.f90) | ||
add_executable(periodic_grid periodic_grid.f90) | ||
add_executable(gen_boundary_global gen_boundary_global.f90) | ||
add_executable(check_lonlat_grid check_lonlat_grid.f90) | ||
add_executable(mergegrid5 mergegrid5.f90) | ||
|
||
target_link_libraries(mergegrid5 utillib) | ||
target_include_directories(mergegrid5 PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
add_dependencies(mergegrid5 utillib) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
|
||
add_executable(interpolate_variables7 interpolate_variables7.f90 ) | ||
add_executable(interpolate_variables7 interpolate_variables7.f90) | ||
add_executable(timeint_3Dth2 timeint_3Dth2.f90) | ||
add_executable(interpolate_variables8 interpolate_variables8.f90) | ||
|
||
add_dependencies(interpolate_variables7 utillib) | ||
add_dependencies(timeint_3Dth2 utillib) | ||
add_dependencies(interpolate_variables8 utillib) | ||
|
||
target_link_libraries(interpolate_variables8 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_include_directories(interpolate_variables8 PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
|
||
add_dependencies(utility interpolate_variables7 timeint_3Dth2) | ||
target_link_libraries(interpolate_variables7 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries(interpolate_variables7 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_include_directories(interpolate_variables7 PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
|
||
add_executable(interpolate_variables8 interpolate_variables8.f90 ) | ||
add_dependencies(utility interpolate_variables8 timeint_3Dth2) | ||
target_link_libraries(interpolate_variables8 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,27 @@ | ||
|
||
add_definitions(${C_PREPROCESS_FLAG}) | ||
add_executable( compute_alongchannel_vel compute_alongchannel_vel.f90) | ||
add_executable( compute_average3 compute_average3.f90) | ||
add_executable( compute_fluxes_ns compute_fluxes_ns.f90) | ||
add_executable( extract_subregion2 extract_subregion2.f90) | ||
add_executable( read_output8_allnodes read_output8_allnodes.f90) | ||
add_executable( read_output9_transect read_output9_transect.f90) | ||
add_executable( read_output9_xyt read_output9_xyt.f90) | ||
add_executable( read_output9_xyz read_output9_xyz.f90) | ||
add_executable( read_output9_xyzt read_output9_xyzt.f90) | ||
add_executable( read_output10_allnodes read_output10_allnodes.f90) | ||
add_executable( read_output10_xyz read_output10_xyz.f90) | ||
add_executable( read_output10_transect read_output10_transect.f90) | ||
add_executable( read_output10_xyt read_output10_xyt.f90) | ||
add_executable( read_output10_xyzt read_output10_xyzt.f90) | ||
|
||
|
||
target_link_libraries (compute_alongchannel_vel utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (compute_average3 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES} ) | ||
target_link_libraries (compute_fluxes_ns utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (extract_subregion2 utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output8_allnodes utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output9_transect utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output9_xyt utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output9_xyz utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output9_xyzt utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output10_allnodes utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output10_xyz utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output10_xyt utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output10_xyzt utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_link_libraries (read_output10_transect utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
|
||
add_dependencies(utility compute_alongchannel_vel compute_average3 compute_fluxes_ns extract_subregion2 read_output8_allnodes read_output9_transect read_output9_xyt read_output9_xyz read_output9_xyzt read_output10_xyz) | ||
# set list of files | ||
set(post_processing_files | ||
compute_alongchannel_vel.f90 | ||
compute_average3.f90 | ||
compute_fluxes_ns.f90 | ||
extract_subregion2.f90 | ||
read_output8_allnodes.f90 | ||
read_output9_transect.f90 | ||
read_output9_xyt.f90 | ||
read_output9_xyz.f90 | ||
read_output9_xyzt.f90 | ||
read_output10_allnodes.f90 | ||
read_output10_xyz.f90 | ||
read_output10_transect.f90 | ||
read_output10_xyt.f90 | ||
read_output10_xyzt.f90) | ||
|
||
# define executables, their dependencies and libraries that will be used in linking | ||
foreach(f ${post_processing_files}) | ||
get_filename_component(fwe ${f} NAME_WE) | ||
add_executable(${fwe} ${f}) | ||
target_link_libraries(${fwe} utillib ${NetCDFLIBS} ${HDF5_LIBRARIES}) | ||
target_include_directories(${fwe} PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/../UtilLib) | ||
add_dependencies(${fwe} utillib) | ||
endforeach() |
Oops, something went wrong.