-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
47 lines (34 loc) · 887 Bytes
/
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
exe=imm_discrete
COMMFLAGS=-O3 --compiler-options -Wall -Xptxas -v
CUCC= "$(shell which nvcc)"
CUFLAGS= -arch=sm_35 ${COMMFLAGS}
CUFLAGS+= -ccbin=g++ -Xcompiler -fopenmp
MPC= "$(shell which mpicxx)"
MPCFLAGS= -Wall -I"$(shell dirname $(CUCC))/../include" -L"$(shell dirname $(CUCC))/../lib64" -lcudart -fopenmp
MPCFLAGS+= -O3 -std=c++0x
ifeq ($(enable_monitor), 1)
CUFLAGS+= -DENABLE_MONITORING
endif
ifeq ($(enable_check), 1)
CUFLAGS+= -DENABLE_CHECKING
endif
ifeq ($(enable_groupby), 1)
CUFLAGS += -DGROUBY
endif
DEPS= src/graph.h \
src/head.h \
src/iheap.h \
src/imm.h \
src/ibfs.h \
src/infgraph.h \
src/weibull.h
OBJS= src/imm.o \
src/ibfs.o
%.o: %.cpp ${DEPS}
${MPC} -c ${MPCFLAGS} $< -o $@
%.o: %.cu ${DEPS}
${CUCC} -c ${CUFLAGS} $< -o $@
${exe}: ${OBJS}
${MPC} ${OBJS} ${MPCFLAGS} src/sfmt/SFMT.c -o ${exe}
clean:
rm -rf ${exe} src/*.o