Blame view

src/makefile 725 Bytes
c2c1e911   Dany Dumont   Renommage de vari...
1
2
#COMPILER= gfortran
COMPILER=ifort
81dede1c   Jérémy Baudry   first commit
3
4
5

OPTION= -O3 

c2c1e911   Dany Dumont   Renommage de vari...
6
7
8
NETCDFinc=-I/usr/local/include
NETCDFLIB=-L/usr/local/lib -lnetcdf
NETCDFMOD=-I/usr/local/lib/include
4e5b4414   Jérémy Baudry   ajout commentaire...
9

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

SRC= *.f90

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

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

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

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

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

c5b6a1a5   Jérémy Baudry   makefile and disp...
30
31
32
33
34
$(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
35
36
37


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

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