From 22be22b0ad8836a6c8264075f79cbcca64ba74a7 Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Sat, 2 Nov 2019 07:31:38 +0900 Subject: [PATCH] Re-apply PR 11 (#15) * src/incmake/component_CCPP.mk: update CCPP source/install directories and set CCPP build directory (#11) * Update for NEMSCompsetRun on jet, bugfix for calling ccpp_prebuild.py in distclean phase (#12) * tests/rtgen: update to run NEMSCompsetRun on xjet * src/incmake/component_CCPP.mk: bugfix, correct path for calling ccpp_prebuild.py in distclean phase --- src/incmake/component_CCPP.mk | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/incmake/component_CCPP.mk b/src/incmake/component_CCPP.mk index b71e5934..19575411 100644 --- a/src/incmake/component_CCPP.mk +++ b/src/incmake/component_CCPP.mk @@ -3,15 +3,18 @@ ccpp_mk=$(CCPP_BINDIR)/ccpp.mk all_component_mk_files+=$(ccpp_mk) # Location of source code and installation -CCPP_SRCDIR?=$(ROOTDIR)/ccpp -CCPP_BINDIR?=$(ROOTDIR)/ccpp +CCPP_SRCDIR?=$(ROOTDIR)/FV3/ccpp +CCPP_BINDIR?=$(ROOTDIR)/FV3/ccpp + +# Build directory - set to FV3 (later fv3atm) for old make (i.e. in-source) build +CCPP_BUILDDIR?=$(ROOTDIR)/FV3 # Make sure we have a model that supports CCPP: ifeq (,$(findstring FV3,$(COMPONENTS))) $(error CCPP requires FV3) else # Ensure the model is selected. - override CCPP_CONFOPT += --config=ccpp/config/ccpp_prebuild_config.py + override CCPP_CONFOPT += --config=$(CCPP_SRCDIR)/config/ccpp_prebuild_config.py --builddir=$(CCPP_BUILDDIR) override CCPP_MAKEOPT ?= $(FV3_MAKEOPT) override CCPP_BUILDOPT ?= $(FV3_BUILDOPT) endif @@ -47,7 +50,7 @@ $(ccpp_mk): configure set -xue ; \ export PATH_CCPP="$(CCPP_SRCDIR)" ; \ cd $(ROOTDIR) ; \ - ./ccpp/framework/scripts/ccpp_prebuild.py $(CCPP_CONFOPT) ; \ + $$PATH_CCPP/framework/scripts/ccpp_prebuild.py $(CCPP_CONFOPT) ; \ cd $$PATH_CCPP ; \ ./build_ccpp.sh ${BUILD_TARGET} "$$PATH_CCPP" $(ccpp_mk) \ "$(CCPP_MAKEOPT)" NO NO ; \