-
Notifications
You must be signed in to change notification settings - Fork 0
/
makefile
43 lines (31 loc) · 1.34 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
# Turn on warnings and C++ 11 features
CPPFLAGS += -W -Wall -std=c++11
# Turn of "unused parameter" in g++
CPPFLAGS += -Wno-unused-parameter
# Add the ./include directory to the header search path
CPPFLAGS += -I include
# Make it run fast
CPPFLAGS += -DNDEBUG=1 -O3
# Enable pthreads
CPPFLAGS += -pthread
# Link in the TBB libraries
LDLIBS += -ltbb
# Define the sources for the various julia engines
JULIA_ENGINE_SRCS = \
src/julia_frame_reference.cpp \
src/julia_frame_parallel_inner.cpp \
src/julia_frame_parallel_outer.cpp \
src/julia_frame_parallel_both.cpp
# Explain how to create bin/julia from sources in $(JULIA_SRCS)
bin/julia : $(JULIA_ENGINE_SRCS) src/julia_driver.cpp
mkdir -p bin
$(CXX) -o bin/julia $(CPPFLAGS) $(JULIA_ENGINE_SRCS) src/julia_driver.cpp $(LDFLAGS) $(LDLIBS)
# Alternate curses based interface. This will only build if curses is available.
# You may need to do `sudo apt-get install libncurses-dev` or equivalent first.
bin/julia_curses : $(JULIA_ENGINE_SRCS) src/julia_driver.cpp
mkdir -p bin
$(CXX) -o bin/julia_curses $(CPPFLAGS) $(JULIA_ENGINE_SRCS) src/julia_driver_curses.cpp $(LDFLAGS) -lcurses $(LDLIBS)
# A "clean" target. Originally missing, thanks to @lynx5120 for pointing out it was gone
# The '-' preceding the command is to indicate that we don't mind if it fails.
clean :
rm -f bin/julia bin/julia_curses