source: branches/publications/ORCHIDEE-PEAT_r5488/src_stomate/AA_make @ 5491

Last change on this file since 5491 was 3771, checked in by albert.jornet, 8 years ago

Merge: new Grassland Management Module (GRM) from revision [3759/perso/jinfeng.chang/ORCHIDEE-MICT/ORCHIDEE/ORCHIDEE]. Done by Jinfeng.

  • Property svn:keywords set to Id
File size: 8.8 KB
Line 
1#-
2#- $Id$
3#-
4PARALLEL_LIB = $(LIBDIR)/libparallel.a
5SXPARALLEL_LIB = $(PARALLEL_LIB)
6#-Q- sxnec  SXPARALLEL_LIB = $(LIBDIR)/libsxparallel.a
7#-Q- sx6nec SXPARALLEL_LIB = $(LIBDIR)/libsxparallel.a
8#-Q- eshpux SXPARALLEL_LIB = $(LIBDIR)/libsxparallel.a
9#-Q- sx8brodie SXPARALLEL_LIB = $(LIBDIR)/libsxparallel.a
10#-
11PARAM_LIB = $(LIBDIR)/libparameters.a
12SXPARAM_LIB = $(PARAM_LIB)
13#-Q- sxnec  SXPARAM_LIB = $(LIBDIR)/libsxparameters.a
14#-Q- sx6nec SXPARAM_LIB = $(LIBDIR)/libsxparameters.a
15#-Q- eshpux SXPARAM_LIB = $(LIBDIR)/libsxparameters.a
16#-Q- sx8brodie SXPARAM_LIB = $(LIBDIR)/libsxparameters.a
17#-
18ORGLOB_LIB = $(LIBDIR)/liborglob.a
19SXORGLOB_LIB = $(ORGLOB_LIB)
20#-Q- sxnec  SXORGLOB_LIB = $(LIBDIR)/libsxorglob.a
21#-Q- sx6nec SXORGLOB_LIB = $(LIBDIR)/libsxorglob.a
22#-Q- eshpux SXORGLOB_LIB = $(LIBDIR)/libsxorglob.a
23#-Q- sx8brodie SXORGLOB_LIB = $(LIBDIR)/libsxorglob.a
24#-
25MODS1 = stomate_data.f90      \
26        lpj_constraints.f90        \
27        lpj_cover.f90              \
28        lpj_crown.f90              \
29        lpj_establish.f90          \
30        lpj_spitfire.f90               \
31        lpj_gap.f90                \
32        lpj_kill.f90               \
33        lpj_light.f90              \
34        lpj_pftinout.f90           \
35        stomate_alloc.f90          \
36        stomate_data.f90           \
37        stomate_io.f90             \
38        stomate_litter.f90         \
39        stomate_npp.f90            \
40        stomate_phenology.f90      \
41        stomate_prescribe.f90      \
42        stomate_season.f90         \
43        stomate_soilcarbon.f90     \
44        stomate_turnover.f90       \
45        stomate_vmax.f90           \
46        stomate_lcchange.f90       \
47        stomate_glcchange_fh.f90       \
48        stomate_glcchange_SinAgeC_fh.f90       \
49        grassland_constantes.f90         \
50        grassland_fonctions.f90          \
51        grassland_cutting.f90          \
52        grassland_fertilisation.f90   \
53        grassland_grazing.f90         \
54        grassland_management.f90     \
55        stomate_lpj.f90            \
56        stomate_resp.f90           \
57        stomate_permafrost_soilcarbon.f90  \
58        stomate_wet_ch4_pt_ter_0.f90 \
59        stomate_wet_ch4_pt_ter_wet1.f90 \
60        stomate_wet_ch4_pt_ter_wet2.f90 \
61        stomate_wet_ch4_pt_ter_wet3.f90 \
62        stomate_wet_ch4_pt_ter_wet4.f90 \
63        stomate.f90
64
65OBJSMODS1 = $(MODS1:.f90=.o)
66#-
67.PRECIOUS : $(MODEL_LIB)
68#-Q- sxnec  .PRECIOUS : $(SXMODEL_LIB)
69#-Q- sx6nec .PRECIOUS : $(SXMODEL_LIB)
70#-Q- eshpux .PRECIOUS : $(SXMODEL_LIB)
71#-Q- sx8brodie .PRECIOUS : $(SXMODEL_LIB)
72#-
73all:
74        $(M_K) libparallel
75        $(M_K) libparameters
76        $(M_K) liborglob
77        $(M_K) m_all
78        @echo stomate is OK
79
80m_all: $(MODEL_LIB)($(OBJSMODS1))
81#-Q- intel m_all: WORK_MOD $(MODEL_LIB)($(OBJSMODS1))
82
83memory:
84#-Q- sxnec      @echo maximum memory must be defined on Rhodes
85#-Q- sxnec      @echo in sh or ksh : ulimit -v unlimited
86#-Q- sxnec      @echo in csh or tcsh : limit vmemoryuse unlimited
87#-Q- sxnec      -/sbin/ulimit -v unlimited
88#-Q- sxnec      -limit vmemoryuse unlimited
89
90libparallel:
91        (cd ../src_parallel; $(M_K) -f Makefile)
92
93libparameters:
94        (cd ../src_parameters; $(M_K) -f Makefile)
95
96liborglob:
97        (cd ../src_global; $(M_K) -f Makefile)
98
99$(MODEL_LIB)(%.o): %.f90
100        $(F_C) $(F_O) -I$(NCDF_INC) $*.f90
101        $(A_C) $(MODEL_LIB) $*.o
102        $(A_C) $(ORCHIDEE_LIB) $*.o
103#-Q- sxnec      $(A_X) $(SXMODEL_LIB) $*.o
104#-Q- sxnec      mv $*.mod $(MODDIR)
105#-Q- sx6nec     $(A_X) $(SXMODEL_LIB) $*.o
106#-Q- sx6nec     mv $*.mod $(MODDIR)
107#-Q- eshpux     $(A_X) $(SXMODEL_LIB) $*.o
108#-Q- eshpux     mv $*.mod $(MODDIR)
109#-Q- sx8mercure         mv $*.mod $(MODDIR)
110#-Q- sx9mercure         mv $*.mod $(MODDIR)
111#-Q- sx8brodie  $(A_X) $(SXMODEL_LIB) $*.o
112#-Q- sx8brodie  mv $*.mod $(MODDIR)
113#-Q- solaris    mv $*.mod $(MODDIR)
114        $(RM) $*.o
115#-Q- intel
116#-Q- intel WORK_MOD:
117#-Q- intel      $(RM) work.pcl
118#-Q- intel      @echo "work.pc" > work.pcl
119#-Q- intel      @echo "../src_parameters/work.pc" >> work.pcl
120#-Q- intel      @echo "../../IOIPSL/src/work.pc" >> work.pcl
121
122config:
123        $(BINDIR)/Fparser -name STOMATE $(MODS1)
124        echo 'Configuration of STOMATE done'
125
126clean:
127        $(RM) $(MODEL_LIB)
128
129$(MODEL_LIB)(stomate.o):          \
130  $(PARAM_LIB)(pft_parameters.o)  \
131  $(MODEL_LIB)(stomate_io.o)      \
132  $(MODEL_LIB)(stomate_permafrost_soilcarbon.o)  \
133  $(MODEL_LIB)(stomate_lpj.o)
134
135$(MODEL_LIB)(stomate_permafrost_soilcarbon.o): \
136  $(MODEL_LIB)(stomate_data.o) \
137  $(PARAM_LIB)(pft_parameters.o) \
138  $(PARAM_LIB)(constantes_soil.o) \
139  $(PARAM_LIB)(constantes_soil_var.o) \
140  $(PARAM_LIB)(constantes_var.o)
141 
142$(MODEL_LIB)(stomate_data.o): \
143  $(PARAM_LIB)(pft_parameters.o)        \
144  $(PARAM_LIB)(constantes.o) 
145
146$(MODEL_LIB)(lpj_constraints.o): \
147  $(MODEL_LIB)(stomate_data.o)
148
149$(MODEL_LIB)(lpj_cover.o): \
150  $(MODEL_LIB)(stomate_data.o)
151
152$(MODEL_LIB)(lpj_crown.o): \
153  $(MODEL_LIB)(stomate_data.o)
154
155$(MODEL_LIB)(lpj_establish.o): \
156  $(MODEL_LIB)(stomate_data.o)
157
158$(MODEL_LIB)(lpj_fire.o): \
159  $(MODEL_LIB)(stomate_data.o)
160
161$(MODEL_LIB)(lpj_gap.o): \
162  $(MODEL_LIB)(stomate_data.o)
163
164$(MODEL_LIB)(lpj_kill.o): \
165  $(MODEL_LIB)(stomate_data.o)
166
167$(MODEL_LIB)(lpj_light.o): \
168  $(MODEL_LIB)(stomate_data.o)
169
170$(MODEL_LIB)(lpj_pftinout.o): \
171  $(MODEL_LIB)(stomate_data.o)
172
173$(MODEL_LIB)(stomate_alloc.o): \
174  $(PARAM_LIB)(pft_parameters.o)        \
175  $(MODEL_LIB)(stomate_data.o)
176
177$(MODEL_LIB)(stomate_io.o): \
178  $(MODEL_LIB)(stomate_data.o) \
179  $(PARALLEL_LIB)(mod_orchidee_para.o)
180
181
182$(MODEL_LIB)(stomate_litter.o): \
183  $(MODEL_LIB)(stomate_data.o)
184
185$(MODEL_LIB)(stomate_npp.o): \
186  $(MODEL_LIB)(stomate_data.o)
187
188$(MODEL_LIB)(stomate_wet_ch4_pt_ter_0.o): \
189  $(PARAM_LIB)(pft_parameters.o)
190
191$(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet1.o): \
192  $(PARAM_LIB)(pft_parameters.o)
193
194$(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet2.o): \
195  $(PARAM_LIB)(pft_parameters.o)
196
197$(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet3.o): \
198  $(PARAM_LIB)(pft_parameters.o)
199
200$(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet4.o): \
201  $(PARAM_LIB)(pft_parameters.o)
202
203$(MODEL_LIB)(stomate_phenology.o): \
204  $(MODEL_LIB)(stomate_data.o)
205
206$(MODEL_LIB)(stomate_prescribe.o): \
207  $(MODEL_LIB)(stomate_data.o)
208
209$(MODEL_LIB)(stomate_resp.o): \
210  $(MODEL_LIB)(stomate_data.o)
211
212$(MODEL_LIB)(stomate_season.o): \
213  $(PARAM_LIB)(pft_parameters.o)        \
214  $(MODEL_LIB)(stomate_data.o)
215
216$(MODEL_LIB)(stomate_soilcarbon.o): \
217  $(MODEL_LIB)(stomate_data.o) \
218  $(ORGLOB_LIB)(grid.o)\
219  $(ORGLOB_LIB)(solar.o)
220
221$(MODEL_LIB)(stomate_turnover.o): \
222  $(MODEL_LIB)(stomate_data.o)
223
224$(MODEL_LIB)(stomate_vmax.o): \
225  $(MODEL_LIB)(stomate_data.o)
226
227$(MODEL_LIB)(stomate_lcchange.o): \
228  $(MODEL_LIB)(stomate_data.o)
229
230$(MODEL_LIB)(grassland_constantes.o): \
231  $(PARAM_LIB)(pft_parameters.o)        \
232  $(PARAM_LIB)(constantes.o)
233
234$(MODEL_LIB)(grassland_fonctions.o): \
235  $(PARAM_LIB)(pft_parameters.o)        \
236  $(PARAM_LIB)(constantes.o)            \
237  $(MODEL_LIB)(grassland_constantes.o)
238
239$(MODEL_LIB)(grassland_fertilisation.o): \
240  $(PARAM_LIB)(pft_parameters.o)        \
241  $(PARAM_LIB)(constantes.o)            \
242  $(MODEL_LIB)(grassland_constantes.o)      \
243  $(MODEL_LIB)(grassland_fonctions.o)
244
245$(MODEL_LIB)(grassland_cutting.o): \
246  $(PARAM_LIB)(pft_parameters.o)        \
247  $(PARAM_LIB)(constantes.o)            \
248  $(MODEL_LIB)(grassland_constantes.o)      \
249  $(MODEL_LIB)(grassland_fonctions.o)
250
251$(MODEL_LIB)(grassland_grazing.o): \
252  $(PARAM_LIB)(pft_parameters.o)        \
253  $(PARAM_LIB)(constantes.o)            \
254  $(MODEL_LIB)(grassland_constantes.o)      \
255  $(MODEL_LIB)(grassland_fonctions.o)
256
257$(MODEL_LIB)(grassland_management.o): \
258  $(PARAM_LIB)(pft_parameters.o)        \
259  $(PARAM_LIB)(constantes.o)            \
260  $(MODEL_LIB)(grassland_constantes.o)      \
261  $(MODEL_LIB)(grassland_fonctions.o)       \
262  $(MODEL_LIB)(grassland_grazing.o)      \
263  $(MODEL_LIB)(grassland_cutting.o)       \
264  $(MODEL_LIB)(grassland_fertilisation.o)
265
266$(MODEL_LIB)(stomate_lpj.o):            \
267  $(MODEL_LIB)(lpj_constraints.o)       \
268  $(MODEL_LIB)(lpj_cover.o)             \
269  $(MODEL_LIB)(lpj_crown.o)             \
270  $(MODEL_LIB)(lpj_establish.o)         \
271  $(MODEL_LIB)(lpj_spitfire.o)          \
272  $(MODEL_LIB)(lpj_fire.o)              \
273  $(MODEL_LIB)(lpj_gap.o)               \
274  $(MODEL_LIB)(lpj_kill.o)              \
275  $(MODEL_LIB)(lpj_light.o)             \
276  $(MODEL_LIB)(lpj_pftinout.o)          \
277  $(MODEL_LIB)(stomate_alloc.o)         \
278  $(MODEL_LIB)(stomate_data.o)          \
279  $(MODEL_LIB)(stomate_litter.o)        \
280  $(MODEL_LIB)(stomate_npp.o)           \
281  $(MODEL_LIB)(stomate_phenology.o)     \
282  $(MODEL_LIB)(stomate_prescribe.o)     \
283  $(MODEL_LIB)(stomate_season.o)        \
284  $(MODEL_LIB)(stomate_soilcarbon.o)    \
285  $(MODEL_LIB)(stomate_turnover.o)      \
286  $(MODEL_LIB)(stomate_vmax.o)          \
287  $(MODEL_LIB)(stomate_resp.o)          \
288  $(MODEL_LIB)(stomate_wet_ch4_pt_ter_0.o)             \
289  $(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet1.o)          \
290  $(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet2.o)          \
291  $(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet3.o)          \
292  $(MODEL_LIB)(stomate_wet_ch4_pt_ter_wet4.o)          \
293  $(MODEL_LIB)(stomate_lcchange.o)      \
294  $(MODEL_LIB)(grassland_management.o)
295
Note: See TracBrowser for help on using the repository browser.