Blame view

src/makefile 705 Bytes
81dede1c   Jérémy Baudry   first commit
1
2
3
4
COMPILER= gfortran

OPTION= -O3 

d380ec6c   Jérémy Baudry   second commit
5
6
7
NETCDFinc=-I/usr/include
NETCDFLIB=-L/usr/lib64 -lnetcdff
NETCDFMOD=-I/usr/lib64/gfortran/modules
4e5b4414   Jérémy Baudry   ajout commentaire...
8

81dede1c   Jérémy Baudry   first commit
9
10
11
12
OBJ= *.o

SRC= *.f90

68586e03   Jérémy Baudry   new release
13
MOD= *.mod
81dede1c   Jérémy Baudry   first commit
14

68586e03   Jérémy Baudry   new release
15
EXEC= WIM
81dede1c   Jérémy Baudry   first commit
16

c5b6a1a5   Jérémy Baudry   makefile and disp...
17
18
MODIR=modules
OBJDIR=obj
81dede1c   Jérémy Baudry   first commit
19

c5b6a1a5   Jérémy Baudry   makefile and disp...
20
21
WIM2: $(OBJDIR)/$(OBJ)
	$(COMPILER) $(OPTION) $(NETCDFinc) $(NETCDFMOD) -o $(EXEC) $(OBJDIR)/$(OBJ) $(NETCDFLIB) 
68586e03   Jérémy Baudry   new release
22
	mv WIM ../
81dede1c   Jérémy Baudry   first commit
23

c5b6a1a5   Jérémy Baudry   makefile and disp...
24
25
26
27
$(MODIR)/$(MOD): parameters.f90 
	$(COMPILER)  -c $< 
	mkdir -p $(MODIR)
	mv $(MOD) $(MODIR)
81dede1c   Jérémy Baudry   first commit
28

c5b6a1a5   Jérémy Baudry   makefile and disp...
29
30
31
32
33
$(OBJDIR)/$(OBJ): $(SRC) $(MODIR)/$(MOD) 
	$(COMPILER) $(NETCDFinc) $(NETCDFMOD) -I./$(MODIR) -c $(SRC) $(NETCDFLIB) 
	mkdir -p $(OBJDIR)
	mv $(OBJ) $(OBJDIR)
	mv $(MOD) $(MODIR)
81dede1c   Jérémy Baudry   first commit
34
35
36


clean:
c5b6a1a5   Jérémy Baudry   makefile and disp...
37
	rm -rf *.o *.mod $(OBJDIR) $(MODIR)
81dede1c   Jérémy Baudry   first commit
38
39

mrproper:
c5b6a1a5   Jérémy Baudry   makefile and disp...
40
	rm -rf *.o *.mod ../WIM $(OBJDIR) $(MODIR)