Merge remote-tracking branch 'origin/release-v4.5'
[WRF.git] / hydro / arc / Makefile.NoahMP
blob240e9d359d73e0d9900fa5658599cdaebff21df5
1 # Makefile 
3 CMD = Run/wrf_hydro.exe
5 all: $(CMD)
7 $(CMD):
8         @if [ ! -d "Run" ]; then \
9                 (mkdir Run);\
10         fi
11         (rm -f Run/wrf_hydro.exe   )
12         (make -f Makefile.comm BASIC)
13         @if [ -d "LandModel_cpl" ]; then \
14         (cd LandModel_cpl; make) \
15         fi
16         if [ $(WRF_HYDRO_RAPID) -eq 1 ]; then \
17                 (cd lib;rm -f librapid.a); \
18         fi
19         if [ $(WRF_HYDRO_RAPID) -eq 1 ]; then \
20                 (cd Rapid_routing; make -f makefile.cpl rapid); \
21         fi
23         @if [ -d "LandModel" ]; then \
24         (cd LandModel; make ) \
25         fi
27 debug:: 
28         @echo 'F90FLAGS := $$(DEBUGFLAGS) $$(F90FLAGS)' >> ./macros 
29         @echo 'F90FLAGS := $$(DEBUGFLAGS) $$(F90FLAGS)' >> ./LandModel/user_build_options
30 debug:: $(CMD)
32 install:
33         -rm -f ./Run/wrf_hydro.exe; \
34         mv LandModel/run/hrldas.exe  ./Run/wrf_hydro.exe
35 test:
36         @echo "No libraries or utilities are built, skip testing." 
37 clean:
38         @if [ -d "LandModel_cpl" ]; then \
39         (cd LandModel_cpl; make clean) \
40         fi
41         (make -f Makefile.comm clean)
42         @if [ -d "LandModel" ]; then \
43         (cd LandModel; make clean) \
44         fi
45         if [ $(WRF_HYDRO_RAPID) -eq 1 ]; then \
46                 (cd Rapid_routing; make -f makefile.cpl clean); \
47         fi
48         (rm -f */*.mod */*.o lib/*.a Run/wrf_hydro.exe)