-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathMakefile
110 lines (92 loc) · 3.11 KB
/
Makefile
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
97
98
99
100
101
102
103
104
105
106
107
108
109
default : GITM
include Makefile.def
include Makefile.test
ABDIR = srcSphereAB
MAINDIR = src
GLDIR = srcGlow
PLANET=Mars
src/ModSize.f90:
cp src/ModSize.f90.orig src/ModSize.f90
install: src/ModSize.f90
@(if [ ! -d srcData ]; then ln -s data/input srcData; fi)
help:
@echo Makefile targets:
@echo "help - this help message"
@echo "install - used by Config.pl -install"
@echo "GITM - compile GITM.exe"
@echo "POST - compile PostProcess.exe"
@echo "LIB - compile UA library for SWMF"
@echo "test - should execute all tests, it does not"
@echo "test_gitm_mars_3d - run 3D Mars test"
@echo "test_gitm_mars_3d_compile - compile GITM.exe for 3D Mars test"
@echo "test_gitm_mars_3d_rundir - create run directory or 3D Mars test"
@echo "test_gitm_mars_3d_run - run 3D Mars test on 4 cores"
@echo "test_gitm_mars_3d_check - check 3D Mars test results"
@echo "nompirun - run GITM.exe serially"
@echo "clean - clean object files etc."
@echo "allclean - used by Config.pl -uninstall"
@echo "distclean - run Config.pl -uninstall"
NOMPI:
@echo "will make NOMPI"
@echo ${NOMPIDIR}
@cd ${NOMPIDIR}; make LIB
GITM:
@cd ${SHAREDIR}; make LIB
@cd $(ABDIR); make -j1 LIB
@cd $(EMPIRICALIEDIR); make LIB
@cd ${EMPIRICALUADIR}; make LIB
@cd $(DATAREADINDICESDIR); make LIB
@cd $(GLDIR); make -j1 LIB
@cd $(MAINDIR); make GITM
POST:
@cd $(MAINDIR); make POST
MGITM = ${MYDIR}
LIB:
cd $(ABDIR) ; make LIB
cd $(GLDIR) ; make LIBPREV=${MGITM}/${ABDIR}/libSphere.a LIBADD
cd $(MAINDIR) ; make LIBPREV=${MGITM}/${GLDIR}/libUPTOGL.a libGITM.a
cd srcInterface ; make LIBPREV=${MGITM}/${MAINDIR}/libUA.a LIB
nompirun:
make GITM
cd ${RUNDIR}; ./GITM.exe
clean:
@cd $(ABDIR); make clean
@cd $(MAINDIR); make clean
@cd $(GLDIR); make clean
@cd srcInterface;make clean
@(if [ -d share ]; then cd share; make clean; fi);
@(if [ -d util ]; then cd util; make clean; fi);
distclean:
./Config.pl -uninstall
allclean:
@cd $(ABDIR); make clean
@cd $(MAINDIR); make distclean
@cd srcInterface;make distclean
rm -f *~ srcData/UAM.in
#
# Create run directories
#
rundir:
mkdir -p ${RUNDIR}/UA
@(cd ${RUNDIR}; \
if [ ! -e "EIE/README" ]; then \
ln -s ${EMPIRICALIEDIR}/data EIE;\
fi;)
cd ${RUNDIR}; rm -f ./PostGITM.exe ; ln -s ${BINDIR}/PostProcess.exe ./PostGITM.exe
cd ${RUNDIR}/UA; \
mkdir restartOUT data DataIn; \
ln -s restartOUT restartIN; \
ln -s ${BINDIR}/pGITM .; \
ln -s ${MYDIR}/srcData/* DataIn; rm -f DataIn/CVS;
@(if [ "$(STANDALONE)" != "NO" ]; then \
cd ${RUNDIR} ; \
ln -s ${BINDIR}/GITM.exe . ; \
touch core ; chmod 444 core ; \
ln -s UA/* .; \
cp DataIn/UAM.in.${PLANET} UAM.in ; \
fi);
dist:
make distclean
tar cvzf gitm_`date "+%y%m%d"`.tgz Makefile* Config.pl get_info.pl \
share util src srcData srcDoc srcGlow srcIDL srcInterface \
srcPython srcMake srcSphereAB srcUser Copyright