source:
trunk/UTIL/CFG_TOOLS/Makefile
@
2520
Last change on this file since 2520 was 1799, checked in by blelod, 14 years ago | |
---|---|
|
|
File size: 1.2 KB |
Rev | Line | |
---|---|---|
[1799] | 1 | # |
2 | # Makefile | |
3 | # | |
4 | #--------------------------------------------------------------------- | |
5 | ||
6 | EXEC_BIN1 = create_coordinates.exe | |
7 | ||
8 | NCDF_PATH= /usr/local/include | |
9 | NETCDF_LIB = -L/usr/local/lib -lnetcdf | |
10 | ||
11 | F_C = gfortran | |
12 | F_P = | |
13 | F_O = -ffixed-line-length-132 -fdefault-real-8 -c -I$(NCDF_PATH) $(F_P) $(NETCDF_LIB) | |
14 | ||
15 | OBJSET = \ | |
16 | agrif_types.o \ | |
17 | io_netcdf.o \ | |
18 | agrif_readwrite.o \ | |
19 | tools_brice.o \ | |
20 | ||
21 | ### Target | |
22 | all: $(EXEC_BIN1) | |
23 | @echo compilation is OK | |
24 | ||
25 | ||
26 | ### dependancies | |
27 | $(EXEC_BIN1) : $(OBJSET) create_coordinates.o | |
28 | $(F_C) -o $(EXEC_BIN1) create_coordinates.o $(OBJSET) $(NETCDF_LIB) | |
29 | ||
30 | ||
31 | ||
32 | agrif_readwrite.o : io_netcdf.o agrif_types.o agrif_readwrite.f90 | |
33 | $(F_C) $(F_O) agrif_readwrite.f90 | |
34 | ||
35 | create_coordinates.o : agrif_readwrite.o create_coordinates.f90 | |
36 | $(F_C) $(F_O) create_coordinates.f90 | |
37 | ||
38 | agrif_types.o : agrif_types.f90 | |
39 | $(F_C) $(F_O) agrif_types.f90 | |
40 | ||
41 | io_netcdf.o : agrif_types.o io_netcdf.f90 | |
42 | $(F_C) $(F_O) io_netcdf.f90 | |
43 | ||
44 | tools_brice.o : agrif_types.o tools_brice.f90 | |
45 | $(F_C) $(F_O) tools_brice.f90 | |
46 | ||
47 | ||
48 | ### cleaning objects, libraries and executables | |
49 | clean: | |
50 | rm -f *.o *.mod $(EXEC_BIN1) | |
51 | @echo \(.o .mod and executables are removed\) | |
52 | ||
53 | ### execution | |
54 | exe: | |
55 | ./$(EXEC_BIN1) namelist | |
56 | make clean | |
57 | @echo \(OK execution\) |
Note: See TracBrowser
for help on using the repository browser.