Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
#- Creation des elements relatifs a AGRIF (lib, config)
#---------------------------------------------------------------------
SHELL = /bin/sh
#---------------------------------------------------------------------
DIR_OBJS = AGRIF_OBJS
DIR_FILES = AGRIF_FILES
DIR_YOURFILES = AGRIF_YOURFILES
FILENAMES = modprocs modseq modbc modcluster modinit modinitvars modinterp modinterpbasic \
modtypes modgrids modbcfunction modutil modcurgridfunctions \
modmask modsauv modupdate modmpp \
modupdatebasic modlinktomodel modarrays modvariables
OBJS=$(addsuffix .o,$(addprefix $(DIR_OBJS)/,$(FILENAMES)))
FILES=$(addsuffix .F90,$(addprefix $(DIR_FILES)/,$(FILENAMES)))
all: conv libagrif.a
@echo
@echo ===================================================
@echo AGRIF is OK
@echo ===================================================
@echo
.PHONY: conv
conv:
@echo
@echo ===================================================
@echo Compile conv...
@echo ===================================================
$(MAKE) -C LIB conv
#mv -f LIB/conv .
libagrif.a : prep_lib $(OBJS)
$(AR) -r $@ $(OBJS)
ranlib $@
prep_lib:
@echo
@echo ===================================================
@echo Compile Agrif library...
@echo ===================================================
mkdir -p $(DIR_YOURFILES)
mkdir -p $(DIR_OBJS)
$(DIR_OBJS)/%.o : $(DIR_FILES)/%.F90
$(RM) $(DIR_YOURFILES)/$(*F).f90
$(CPP) $(CPPFLAGS) $(DIR_FILES)/$(*F).F90 > $(DIR_YOURFILES)/$(*F).f90
$(FC) $(FFLAGS) -I.. -c $(DIR_YOURFILES)/$(*F).f90 -o $(DIR_OBJS)/$(*F).o
$(DIR_OBJS)/modarrays.o: $(DIR_OBJS)/modgrids.o
$(DIR_OBJS)/modbc.o: $(DIR_OBJS)/modinterp.o
$(DIR_OBJS)/modbcfunction.o: $(DIR_OBJS)/modupdate.o \
$(DIR_OBJS)/modbc.o \
$(DIR_OBJS)/modinterp.o \
$(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modcluster.o: $(DIR_OBJS)/modtypes.o \
$(DIR_OBJS)/modlinktomodel.o \
$(DIR_OBJS)/modsauv.o \
$(DIR_OBJS)/modinitvars.o \
$(DIR_OBJS)/modseq.o \
$(DIR_OBJS)/modcurgridfunctions.o
$(DIR_OBJS)/modcurgridfunctions.o: $(DIR_OBJS)/modinit.o \
$(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modinit.o: $(DIR_OBJS)/modlinktomodel.o \
$(DIR_OBJS)/modtypes.o \
$(DIR_OBJS)/modmpp.o
$(DIR_OBJS)/modinitvars.o: $(DIR_OBJS)/modlinktomodel.o \
$(DIR_OBJS)/modgrids.o
$(DIR_OBJS)/modinterpbasic.o: $(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modinterp.o: $(DIR_OBJS)/modcurgridfunctions.o \
$(DIR_OBJS)/modmask.o \
$(DIR_OBJS)/modarrays.o \
$(DIR_OBJS)/modmpp.o \
$(DIR_OBJS)/modinterpbasic.o
$(DIR_OBJS)/modlinktomodel.o: $(DIR_OBJS)/modgrids.o
$(DIR_OBJS)/modgrids.o: $(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modmask.o: $(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modsauv.o: $(DIR_OBJS)/modarrays.o $(DIR_OBJS)/modlinktomodel.o \
$(DIR_OBJS)/modtypes.o $(DIR_OBJS)/modvariables.o
$(DIR_OBJS)/modupdatebasic.o: $(DIR_OBJS)/modtypes.o
$(DIR_OBJS)/modupdate.o: $(DIR_OBJS)/modmask.o \
$(DIR_OBJS)/modcurgridfunctions.o \
$(DIR_OBJS)/modarrays.o \
$(DIR_OBJS)/modmpp.o \
$(DIR_OBJS)/modupdatebasic.o
$(DIR_OBJS)/modutil.o: $(DIR_OBJS)/modtypes.o \
$(DIR_OBJS)/modcurgridfunctions.o \
$(DIR_OBJS)/modlinktomodel.o \
$(DIR_OBJS)/modsauv.o \
$(DIR_OBJS)/modcluster.o \
$(DIR_OBJS)/modseq.o
$(DIR_OBJS)/modmpp.o: $(DIR_OBJS)/modgrids.o \
$(DIR_OBJS)/modarrays.o
$(DIR_OBJS)/modseq.o: $(DIR_OBJS)/modinit.o \
$(DIR_OBJS)/modarrays.o \
$(DIR_OBJS)/modprocs.o
.PHONY: doc doc_user
doc:
(cd doc ; doxygen Doxyfile )
doc_user:
(cd doc ; doxygen Doxyfile_user )
clean: clean-conv
$(RM) libagrif.a *.mod $(DIR_OBJS)/* $(DIR_YOURFILES)/*
clean-all: clean
$(MAKE) -C LIB clean-all
clean-conv:
$(MAKE) -C LIB clean
$(RM) conv