-
Notifications
You must be signed in to change notification settings - Fork 77
/
linkmake
97 lines (77 loc) · 2.68 KB
/
linkmake
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
REM This file must be given the extension .cmd to be run on Windows
REM It compiles OC with openMP amd the popup window for opening files.
REM *******************************************
REM ** OC graphics require GNUPLOT 5.2 or later
REM *******************************************
del *.o
del *.mod
REM tinyfiledialog files and interface
copy src\utilities\TINYFILEDIALOGS\tinyopen.c .
copy src\utilities\TINYFILEDIALOGS\tinyfiledialogs.c .
copy src\utilities\TINYFILEDIALOGS\tinyfiledialogs.h .
copy src\utilities\TINYFILEDIALOGS\ftinyopen.F90 .
gcc -c tinyopen.c
gcc -c tinyfiledialogs.c
gfortran -c ftinyopen.F90
del tinyopen.c
del tinyfiledialogs.c
del tinyfiledialogs.h
del ftinyopen.F90
REM NEW global constants mm
copy src\models\ocparam.F90 .
gfortran -c -O2 ocparam.F90
del ocparam.F90
REM some utilites and the command line interface
REM Changed to utiliy package metlib4
copy src\utilities\metlib4.F90 .
gfortran -c -O2 -Dtinyfd metlib4.F90
del metlib4.F90
REM some routines from LAPACK and BLAS
copy src\numlib\oclablas.F90 .
gfortran -c -O2 oclablas.F90
del oclablas.F90
REM some more numerical routines
REM NEW if no external LAPACK -DNOLAPACK needed
copy src\numlib\ocnum.F90 .
gfortran -c -DNOLAPACK -O2 ocnum.F90
del ocnum.F90
REM the MINPACK package for least square fitting and solving nonlinear eqs.
copy src\numlib\minpack1.F90
gfortran -c -O2 minpack1.F90
del minpack1.F90
REM the model routines
copy src\models\gtp3*.F90 .
gfortran -c -O2 gtp3.F90
del gtp3*.F90
REM the equilibrium calculation routines
copy src\minimizer\matsmin.F90 .
gfortran -c -O2 matsmin.F90
del matsmin.F90
REM the routines diagrams using STEP or MAP
copy src\stepmapplot\smp2*.F90 .
gfortran -c -O2 smp2.F90
del smp2*.F90
REM the user interface
REM set -Dqtplt to use the Qt terminal driver for screen
REM -Dwinhlp needed for online help on Windows
copy src\userif\pmon6.F90 .
gfortran -c -Dwinhlp pmon6.F90
del pmon6.F90
REM First installation create the libs directory
mkdir libs
del libs\liboceq.a
REM generating the library (needed also for TQ library)
ar sq libs\liboceq.a metlib4.o oclablas.o gtp3.o matsmin.o minpack1.o ocnum.o
REM What about the mod file liboceqplus.mod ?
REM Add linkdate to main program
REM New copy pmain1.F90 to pmain1-save.90 to modify linkdat, then delete it
copy src\pmain1.F90 src\pmain1-save.F90
gfortran -o linkocdate src/linkocdate.F90
linkocdate
del src\pmain1-save.F90
REM Finally linking all together
gfortran -o oc6A src\pmain1.F90 pmon6.o smp2.o ftinyopen.o tinyopen.o tinyfiledialogs.o libs\liboceq.a -lcomdlg32 -lole32
copy oc6A.exe bin\
REM *******************************************
REM ** OC graphics require GNUPLOT 5.2 or later
REM *******************************************