Skip to content

Commit

Permalink
Merge pull request #24 from GEOS-ESM/feature/rmontuoro/ufs-integration
Browse files Browse the repository at this point in the history
NOAA UFS integration
  • Loading branch information
tclune authored Mar 4, 2021
2 parents 689d2ed + 5f69e7c commit b62e40d
Show file tree
Hide file tree
Showing 64 changed files with 3,907 additions and 11,576 deletions.
38 changes: 38 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,57 @@ if (NOT CMAKE_BUILD_TYPE)
"Debug" "Release" "MinSizeRel" "RelWithDebInfo")
endif ()

# Set build options
option (BUILD_UFS "Build GOCART component for UFS" OFF)

set (DOING_GEOS5 YES)

# Should find a better place for this - used in Chem component
set (ACG_FLAGS -v)
set (FV_PRECISION R4R8)

if (BUILD_UFS)
# Ensure we build as 32-bit
message ("Force 32-bit build for GOCART")
if (CMAKE_Fortran_COMPILER_ID MATCHES "Intel")
string (REPLACE "-real-size 64" "" CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS}")
elseif (CMAKE_Fortran_COMPILER_ID MATCHES "GNU")
string (REPLACE "-fdefault-real-8" "" CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS}")
endif()
endif()

if (NOT COMMAND esma)
list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake@")
include (esma)
endif()

ecbuild_declare_project()

if (NOT Baselibs_FOUND)
# Find dependencies
if (NOT NetCDF_Fortran_FOUND)
find_package (NetCDF REQUIRED Fortran)
endif ()
add_definitions(-DHAS_NETCDF3)

if (NOT ESMF_FOUND)
find_package (ESMF REQUIRED)
endif ()

find_package (GFTL REQUIRED)
find_package (GFTL_SHARED REQUIRED)
find_package (PFLOGGER REQUIRED)
find_package (YAFYAML REQUIRED)
endif ()

if (BUILD_UFS)
find_package (MAPL REQUIRED)
include(mapl_acg)
elseif (IS_DIRECTORY "${PROJECT_SOURCE_DIR}/ESMF/Shared/MAPL@")
message (STATUS "Using local MAPL source tree: ${PROJECT_SOURCE_DIR}/ESMF/Shared/MAPL@")
endif ()


# This is a KLUDGE to emulate paths used in GEOSgcm so that GOCART Legacy code generation works
file (MAKE_DIRECTORY ${esma_include}/GEOSchem_GridComp)

Expand Down

This file was deleted.

This file was deleted.

23 changes: 0 additions & 23 deletions ESMF/Aerosol_GridComp/AeroCinderella_GridComp/CMakeLists.txt

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit b62e40d

Please sign in to comment.