-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
42 lines (29 loc) · 843 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
# Warnings
WFLAGS := -Wall -Wextra -Wsign-conversion -Wsign-compare
# Optimization and architecture
OPT := -O3
ARCH := -march=native
# Language standard
CCSTD := -std=c99
CXXSTD := -std=c++11
# Linker options
LDOPT := $(OPT)
LDFLAGS := -fopenmp -lpthread -mavx
BIN = "/usr/local/gcc/6.4.0/bin/gcc"
# Names of executables to create
EXEC := par_walk
# Includes
Linked_Libs := ~/opt/moab/include
.DEFAULT_GOAL := all
.PHONY: debug
debug : OPT := -O0 -g -fno-omit-frame-pointer -fsanitize=address
debug : LDFLAGS := -fsanitize=address
debug : ARCH :=
debug : $(EXEC)
all : $(EXEC) par_tally
par_walk: par_tally.cu
module load cuda;nvcc -g -o par_tally $(OPT) $(CXXSTD) par_tally.cu -ccbin $(BIN)
# TODO: add targets for building executables
.PHONY: clean
clean:
@ rm -f $(EXEC) $(OBJS) *.out event_history.txt