source: lmdz_wrf/trunk/tools/Makefile.llamp @ 1784

Last change on this file since 1784 was 1682, checked in by lfita, 7 years ago

Fixing typo

File size: 3.4 KB
RevLine 
[1608]1# L. Fita, LMD. January 2017
2# Compilation of all required Fortran modules in `llamp' (debian 9) with gcc compilers
3# A following python 'library' creation is required
[1681]4## Compilation
5# make >& run_make.log
[1608]6
7FC              = gfortran
8FCF     = -c
9LIB_INC =
10RM              = rm -f
[1681]11F2PY    = /usr/bin/f2py
[1660]12DBGFLAGS = -g -Wall -Wextra -Warray-temporaries -Wconversion -fimplicit-none -fbacktrace -ffree-line-length-0 -fcheck=all -ffpe-trap=zero,overflow,underflow -finit-real=nan
[1608]13NCLIBFOLD       = /usr/lib/x86_64-linux-gnu
[1660]14NCINCFOLD       = /usr/include
15LIB_NETCDF      = -L$(NCLIBFOLD) -lnetcdff -lnetcdf -I$(NCINCFOLD)
[1608]16
17FCFLAGS = $(FCF) $(DBGFLAGS)
18
[1682]19# Sources for f2py
[1655]20srcs = module_definitions.f90 module_basic.f90 module_generic.f90 module_scientific.f90
21distrisrcs = $(srcs) module_DistriCorrection.f90
22diagsrcs = $(srcs) module_ForDiagnosticsVars.f90 module_ForDiagnostics.f90
23intsrcs = $(srcs) module_ForInterpolate.f90
24scisrcs = $(srcs)
[1678]25defsrcs = module_definitions.f90
[1608]26
27####### ###### ##### #### ### ## #
28
29MODULES = \
30        module_definitions.o \
[1655]31        module_basic.o \
32        module_generic.o \
[1664]33        module_NCgeneric.o \
[1608]34        module_scientific.o \
35        module_ForDiagnosticsVars.o \
36        module_ForDiagnostics.o \
37        module_DistriCorrection.o
38
39all : \
40        module_ForDiagnostics.o \
41        DistriCorrection.o \
42        interpolate.o \
43        pydistrimods.o \
44        pydiagmods.o \
[1613]45        pyintmods.o \
[1655]46        pyscimods.o \
[1678]47        pydefmods.o \
[1655]48        trajectories_overlap.o
[1608]49
50diags : \
51        module_ForDiagnostics.o
52
53clean :
[1678]54        $(RM) *.mod *.o interpolate module_ForDiag.so module_ForInt.so module_ForDistriCorrect.so module_ForSci.so module_ForDef.so
[1608]55
56########    #######
57##
58    ########
59
60module_definitions.o:
61        $(FC) $(FCFLAGS) module_definitions.f90
62
[1655]63module_basic.o: module_definitions.o
64        $(FC) $(FCFLAGS) module_basic.f90
65
66module_generic.o: module_definitions.o module_basic.o
[1664]67        $(FC) $(FCFLAGS) $(LIB_INC) module_generic.f90
[1608]68
[1664]69module_NCgeneric.o: module_definitions.o module_basic.o module_generic.o
70        $(FC) $(FCFLAGS) $(LIB_NETCDF) $(LIB_INC) module_NCgeneric.f90
71
[1655]72module_scientific.o: module_definitions.o module_basic.o module_generic.o
[1664]73        $(FC) $(FCFLAGS) module_scientific.f90
[1608]74
[1655]75module_ForDiagnosticsVars.o: module_definitions.o module_basic.o module_generic.o
[1664]76        $(FC) $(FCFLAGS) $(LIB_INC) module_ForDiagnosticsVars.f90
[1608]77
[1655]78module_ForDiagnostics.o: module_definitions.o module_basic.o module_generic.o module_ForDiagnosticsVars.o
[1664]79        $(FC) $(FCFLAGS) $(LIB_INC) module_ForDiagnostics.f90
[1608]80
[1655]81module_DistriCorrection.o: module_definitions.o module_basic.o module_generic.o module_scientific.o
[1664]82        $(FC) $(FCFLAGS) module_DistriCorrection.f90
[1608]83
84FCEXECFLAGS = $(MODULES) $(LIB_NETCDF) $(LIB_INC)
85
[1655]86interpolate.o: module_definitions.o module_basic.o module_generic.o module_scientific.o
[1608]87        $(FC) $(FCEXECFLAGS) interpolate.f90 -o interpolate
88
[1664]89DistriCorrection.o: module_definitions.o module_basic.o module_generic.o module_NCgeneric.o module_scientific.o module_DistriCorrection.o
[1608]90        $(FC) $(FCEXECFLAGS) DistriCorrection.f90 -o DistriCorrection
91
92pydistrimods.o:
[1681]93        $(F2PY) -c -I$(NCINCFOLD) -m module_ForDistriCorrect $(distrisrcs) -L$(NCLIBFOLD)
[1608]94
95pydiagmods.o:
[1681]96        $(F2PY) -c -I$(NCINCFOLD) -m module_ForDiag $(diagsrcs) -L$(NCLIBFOLD)
[1608]97
98pyintmods.o:
[1681]99        $(F2PY) -c -I$(NCINCFOLD) -m module_ForInt $(intsrcs) -L$(NCLIBFOLD)
[1608]100
[1613]101pyscimods.o:
[1681]102        $(F2PY) -c -I$(NCINCFOLD) -m module_ForSci $(scisrcs) -L$(NCLIBFOLD)
[1613]103
[1678]104pydefmods.o:
[1681]105        $(F2PY) -c -I$(NCINCFOLD) -m module_ForDef $(defsrcs) -L$(NCLIBFOLD)
[1678]106
[1664]107trajectories_overlap.o: module_definitions.o module_basic.o module_generic.o module_NCgeneric.o module_scientific.o
[1655]108        $(FC) $(FCEXECFLAGS) trajectories_overlap.f90 -o trajectories_overlap
109
Note: See TracBrowser for help on using the repository browser.