-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefile
More file actions
57 lines (46 loc) · 1.11 KB
/
Makefile
File metadata and controls
57 lines (46 loc) · 1.11 KB
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
DIR_BASE = $(shell pwd)
EXE = $(DIR_BASE)/test
include Makefile.in
all: build_dir build_src #build_ana
build_src:
cd $(DIR_SRC) && make
build_ana: build_src
for subdir in $(DIR_ANA_SUB) ; do \
cd $(DIR_ANA)/$$subdir && make ; \
done
build_dir:
if [ ! -d "./res" ] ; then \
mkdir res; \
fi
if [ ! -d "./fig" ] ; then \
mkdir fig; \
fi
clean:
cd $(DIR_SRC) && make clean
$(RM) $(DIR_INC)/*~
$(RM) $(DIR_CFG)/*~
$(RM) $(DIR_PKG)/*~ $(DIR_PKG)/*.pyc
$(RM) $(DIR_BASE)/*~ $(DIR_BASE)/*.pyc
run:
mkdir -p res
nohup mpirun -n 20 ./test &
clean_exe:
$(RM) $(EXE)
clean_dat:
$(RM) res/*.dat
$(RM) nohup.out
clean_fig:
$(RM) $(DIR_FIG)/*.png $(DIR_FIG)/*.svg
cleanall: clean_exe clean_dat clean_fig clean
for subdir in $(DIR_ANA_SUB) ; do \
cd $(DIR_ANA)/$$subdir && make cleanall ; \
done
dist:
$(RM) -r dist
rsync -az \
--exclude='*.o' --exclude='*.pyc' --exclude='test' \
--exclude='*.dat' --exclude='*.log' --exclude='*.out' \
--exclude='*~' --exclude='res/' --exclude='fig/' \
$(DIR_INC) $(DIR_SRC) $(DIR_PKG) $(DIR_CFG) $(DIR_ANA) \
Makefile Makefile.in *.py LICENSE README.md \
dist/