From c88fd125542f265ab3e6c8bac0b8b4040dc481f5 Mon Sep 17 00:00:00 2001 From: Anthony Islas Date: Wed, 31 Jul 2024 17:47:42 -0700 Subject: [PATCH 1/3] Prepare cmake build to not have core selection --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0951267f9b..9263ac0113 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -127,6 +127,9 @@ set( WRF_CASE_OPTIONS EM_CONVRAD EM_SQUALL2D_X EM_SQUALL2D_Y + + # No case selected, for situations where we are not compiling ARW + NONE ) set( WRF_CASE "" CACHE STRING "WRF_CASE" ) From f14dc92fd974e690aedb4e8e63199b9333106e99 Mon Sep 17 00:00:00 2001 From: Anthony Islas Date: Wed, 31 Jul 2024 17:48:44 -0700 Subject: [PATCH 2/3] Make sure appropriate selection of option for non-ARW cores --- CMakeLists.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9263ac0113..d3e8c4754d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -223,6 +223,11 @@ if ( NOT ${WRF_CORE} IN_LIST WRF_CORE_OPTIONS ) message( FATAL_ERROR "WRF Core option not recognized : ${WRF_CORE}" ) endif() +if ( NOT ${WRF_CORE} STREQUAL "ARW" ) + message( STATUS "All non-ARW Cores requires using pointers in grid state struct" ) + set( USE_ALLOCATABLES OFF CACHE BOOL "Required by configuration" FORCE ) +endif() + if ( NOT ${WRF_NESTING} IN_LIST WRF_NESTING_OPTIONS ) message( FATAL_ERROR "WRF Nesting option not recognized : ${WRF_NESTING}" ) endif() From f82877daa3da2da4eb3ade406669196993383176 Mon Sep 17 00:00:00 2001 From: Anthony Islas Date: Wed, 31 Jul 2024 17:49:02 -0700 Subject: [PATCH 3/3] Shortcut selections for other cores --- arch/configure_reader.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/arch/configure_reader.py b/arch/configure_reader.py index fb89bfca80..2668a86f1f 100755 --- a/arch/configure_reader.py +++ b/arch/configure_reader.py @@ -575,8 +575,12 @@ def generateCMakeToolChainFile( cmakeToolChainTemplate, output, stanza, optionsD def projectSpecificOptions( options, stanzaCfg ) : coreOption = getStringOptionSelection( options.sourceCMakeFile, "WRF_CORE_OPTIONS", "WRF_CORE" ) - nestingOption = getStringOptionSelection( options.sourceCMakeFile, "WRF_NESTING_OPTIONS", "WRF_NESTING", 1 ) - caseOption = getStringOptionSelection( options.sourceCMakeFile, "WRF_CASE_OPTIONS", "WRF_CASE" ) + if coreOption == "ARW" : + nestingOption = getStringOptionSelection( options.sourceCMakeFile, "WRF_NESTING_OPTIONS", "WRF_NESTING", 1 ) + caseOption = getStringOptionSelection( options.sourceCMakeFile, "WRF_CASE_OPTIONS", "WRF_CASE" ) + else : + nestingOption = "NONE" + caseOption = "NONE" # These are yes yesValues = [ "yes", "y", "true", "1" ]