Merge remote-tracking branch 'origin/release-v4.5'
[WRF.git] / hydro / Routing / Overland / Makefile
blob51991551596d40bf5c60108710b5e5f75ce8f5e8
1 #simple compilation test for modules in overland routing
3 include ../../macros
5 # Settings for testing with ifort
6 FC=ifort
7 FFLAGS=-c -free -O3
9 # Setting for testing with gfortran
10 #FC=gfortran
11 #FFLAGS=-c --free-form -std=f2003 -O3
13 FLFLAGS=
15 .PHONY: all mod test
17 all: mod
19 mod:
20 #Build each sub module then build the module that depends on all sub modules
21 $(COMPILER90) $(CPPINVOKE) $(CPPFLAGS) $(F90FLAGS) $(LDFLAGS) $(MODFLAGS) -I$(NETCDFINC) module_overland_control.F
22 $(COMPILER90) $(CPPINVOKE) $(CPPFLAGS) $(F90FLAGS) $(LDFLAGS) $(MODFLAGS) -I$(NETCDFINC) module_overland_streams_and_lakes.F
23 $(COMPILER90) $(CPPINVOKE) $(CPPFLAGS) $(F90FLAGS) $(LDFLAGS) $(MODFLAGS) -I$(NETCDFINC) module_overland_routing_properties.F
24 $(COMPILER90) $(CPPINVOKE) $(CPPFLAGS) $(F90FLAGS) $(LDFLAGS) $(MODFLAGS) -I$(NETCDFINC) module_overland_mass_balance.F
25 $(COMPILER90) $(CPPINVOKE) $(CPPFLAGS) $(F90FLAGS) $(LDFLAGS) $(MODFLAGS) -I$(NETCDFINC) module_overland.F
26 ar -r ../../lib/libHYDRO.a module_overland_control.o
27 ar -r ../../lib/libHYDRO.a module_overland_streams_and_lakes.o
28 ar -r ../../lib/libHYDRO.a module_overland_routing_properties.o
29 ar -r ../../lib/libHYDRO.a module_overland_mass_balance.o
30 ar -r ../../lib/libHYDRO.a module_overland.o
32 cp *.mod ../../mod
33 test:
34 $(COMPILER90) $(FFLAGS) overland_tests.F
35 $(COMPILER90) -o overland_tests \
36 module_overland_control.o \
37 module_overland_streams_and_lakes.o \
38 module_overland_routing_properties.o \
39 module_overland_mass_balance.o \
40 module_overland.o \
41 overland_tests.o
42 clean:
43 rm -f *.o
44 rm -f *.mod
45 rm -f overland_tests