-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.gcc
39 lines (29 loc) · 892 Bytes
/
Makefile.gcc
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
# defines
CXX=g++
SPEEDFLAGS=-O3 -mavx
CXXFLAGS=-Wall -std=c++11 -fopenmp $(SPEEDFLAGS)
LDFLAGS=-lrt -lgomp $(SPEEDFLAGS)
TARGET = solution reference_bfs gen_RMAT gen_random gen_valid_info validation
all: $(TARGET)
# your own implementation
solution: main.o solution.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
# reference implementation with bfs
reference_bfs: main.o reference_bfs.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
# RMAT generator
gen_RMAT: gen_RMAT.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
# Erdos-Renyi (random) graph generator
gen_random: gen_random.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
# gen_valid_info
gen_valid_info: gen_valid_info.o reference_bfs.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
# validation
validation: validation.o reference.o graph_tools.o
$(CXX) $^ -o $@ $(LDFLAGS)
.cpp.o:
$(CXX) $(CXXFLAGS) -o $@ -c $<
clean:
rm -rf *.o $(TARGET)