Skip to content

Commit

Permalink
This change refs #56153
Browse files Browse the repository at this point in the history
The $(MAKEFLAGS) special variable was misused in the top-level makefile to pass down custom options.  This breaks the capability of using the FV3/makefile as a submake from a larger build system.  The new NEMS build system is entirely makefiles, and calls FV3/makefile via $(MAKE), so this fix is needed before the NEMS commit.
  • Loading branch information
SamuelTrahanNOAA committed Oct 19, 2018
1 parent c5d56c8 commit 8b38096
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,19 @@ FV3_EXE = fv3.exe
FV3CAP_LIB = libfv3cap.a

all: libs
$(MAKE) $(FV3_EXE) $(MAKEFLAGS) FMS_DIR=$(FMS_DIR)
$(MAKE) $(FV3_EXE) $(MAKE_OPTS) FMS_DIR=$(FMS_DIR)

nems: libs
$(MAKE) $(FV3CAP_LIB) $(MAKEFLAGS) FMS_DIR=$(FMS_DIR)
$(MAKE) $(FV3CAP_LIB) $(MAKE_OPTS) FMS_DIR=$(FMS_DIR)
$(MAKE) esmf_make_fragment FMS_DIR=$(FMS_DIR)

libs:
$(MAKE) -C cpl $(MAKEFLAGS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C $(PHYSP)physics $(MAKEFLAGS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit
$(MAKE) -C ipd $(MAKEFLAGS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit
$(MAKE) -C io $(MAKEFLAGS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C atmos_cubed_sphere $(MAKEFLAGS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C stochastic_physics $(MAKEFLAGS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit
$(MAKE) -C cpl $(MAKE_OPTS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C $(PHYSP)physics $(MAKE_OPTS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit
$(MAKE) -C ipd $(MAKE_OPTS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit
$(MAKE) -C io $(MAKE_OPTS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C atmos_cubed_sphere $(MAKE_OPTS) FMS_DIR=$(FMS_DIR)
$(MAKE) -C stochastic_physics $(MAKE_OPTS) FMS_DIR=$(FMS_DIR) 32BIT=N # force gfs physics to 64bit

$(FV3_EXE): atmos_model.o coupler_main.o atmos_cubed_sphere/libfv3core.a io/libfv3io.a ipd/libipd.a $(PHYSP)physics/lib$(PHYSP)phys.a stochastic_physics/libstochastic_physics.a cpl/libfv3cpl.a fms/libfms.a
$(LD) -o $@ $^ $(NCEPLIBS) $(LDFLAGS)
Expand Down

0 comments on commit 8b38096

Please sign in to comment.