source: CPL/oasis3-mct/branches/OASIS3-MCT_2.0_branch/examples/test_interpolation/Makefile @ 4775

Last change on this file since 4775 was 4775, checked in by aclsce, 5 years ago
  • Imported oasis3-mct from Cerfacs svn server (not suppotred anymore).

The version has been extracted from https://oasis3mct.cerfacs.fr/svn/branches/OASIS3-MCT_2.0_branch/oasis3-mct@1818

File size: 2.9 KB
Line 
1#
2include header_Makefile
3LIBPSMILE = $(ARCHDIR)/lib/libpsmile.${CHAN}.a $(ARCHDIR)/lib/libmct.a $(ARCHDIR)/lib/libmpeu.a $(ARCHDIR)/lib/libscrip.a
4#
5##### User configurable options #####
6#
7# CPP keys for model 1 (_M1) and for model 2 (_M2)
8# type of decomposition :
9# DECOMP_APPLE for 1D decomposition
10# DECOMP_BOX for 2D decomposition
11CPPKEYDECOMP_M1=DECOMP_APPLE
12CPPKEYDECOMP_M2=DECOMP_APPLE
13#
14# Precision for REAL: USE_DOUBLE_PRECISION or NO_USE_DOUBLE_PRECISION
15include header_precision
16CPPLOCAL_M1 = -D${CPPKEYDP} -D${CPPKEYDECOMP_M1}
17CPPLOCAL_M2 = -D${CPPKEYDP} -D${CPPKEYDECOMP_M2}
18#
19### End User configurable options ###
20#
21OBJ_M1 =  routine_hdlerr.o read_all_data.o \
22          decomp_def.o \
23          function_ana.o write_all_fields.o
24OBJ_M2 =  routine_hdlerr.o read_all_data.o \
25          decomp_def_m2.o \
26          function_ana.o  write_all_fields.o
27#-------------------------------------------------------------------------------
28# General rules
29#-------------------------------------------------------------------------------
30#
31default: all
32#
33all: oasis3_psmile model1 model2
34#
35# Compile and link libaries
36oasis3_psmile:
37        (cd $(O3DIR)/util/make_dir ; $(MAKE) oasis3_psmile -f TopMakefileOasis3)
38#
39#
40#-------------------------------------------------------------------------------
41# Rules for executables
42#-------------------------------------------------------------------------------
43#
44model1: $(OBJ_M1) model1.o $(LIBPSMILE) Makefile
45        $(LD) $(LDFLAGS) -o $@ $(OBJ_M1) model1.o $(LIBPSMILE) $(FLIBS)
46model2: $(OBJ_M2) model2.o $(LIBPSMILE) Makefile
47        $(LD) $(LDFLAGS) -o $@ $(OBJ_M2) model2.o $(LIBPSMILE) $(FLIBS)
48#
49#-------------------------------------------------------------------------------
50# Rules for compilation
51#-------------------------------------------------------------------------------
52#
53routine_hdlerr.o :              routine_hdlerr.F90
54                                $(F90) $(F90FLAGS) -c routine_hdlerr.F90
55read_all_data.o :               read_all_data.F90
56                                $(F90) $(F90FLAGS) -D${CPPKEYDP} -c read_all_data.F90
57write_all_fields.o :            write_all_fields.F90
58                                $(F90) $(F90FLAGS) -D${CPPKEYDP} -c write_all_fields.F90
59function_ana.o :                function_ana.F90
60                                $(F90) $(F90FLAGS) -D${CPPKEYDP} -c function_ana.F90
61decomp_def.o :                  decomp_def.F90
62                                $(F90) $(F90FLAGS) $(CPPLOCAL_M1) -c decomp_def.F90
63decomp_def_m2.o :               decomp_def.F90
64                                $(F90) $(F90FLAGS) $(CPPLOCAL_M2) -o decomp_def_m2.o -c decomp_def.F90
65
66model1.o :      model1.F90 Makefile
67                $(F90) $(F90FLAGS) $(CPPLOCAL_M1) -c model1.F90
68model2.o :      model2.F90 Makefile
69                $(F90) $(F90FLAGS) $(CPPLOCAL_M2) -c model2.F90
70#
71#-------------------------------------------------------------------------------
72# Utilities
73#-------------------------------------------------------------------------------
74#
75help:
76        more Make.help
77#
78# Clean directory
79#
80clean:
81        -rm -f *.o *.mod *.MOD model1 model2
82        -rm -f i.*.F90 *.L
83        -rm -f core core.*
84#
85# Make sure to recompile everything
86#
87realclean: clean remove
88remove:
89        (cd $(O3DIR)/util/make_dir ; $(MAKE) realclean -f TopMakefileOasis3)
Note: See TracBrowser for help on using the repository browser.