-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
33 lines (24 loc) · 764 Bytes
/
Makefile
File metadata and controls
33 lines (24 loc) · 764 Bytes
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
CXX = clang++
CXXFLAGS = -O2 -std=c++20 -I./include -I/opt/homebrew/include -I/opt/homebrew/opt/openssl/include -pthread
LDFLAGS = -L/opt/homebrew/lib -L/opt/homebrew/opt/openssl/lib
LDLIBS = -lssl -lcrypto -lboost_system -lboost_json -lcurl
SOURCES = core.cpp \
src/simdjson.cpp \
src/corecomponent.cpp \
src/websockets/coinbase_ws.cpp \
src/websocket.cpp \
src/orderbook.cpp \
src/positionmanager.cpp
OBJECTS = $(patsubst %.cpp,build/%.o,$(SOURCES))
DEPS = $(OBJECTS:.o=.d)
.PHONY: all clean
all: core
build/%.o: %.cpp
@mkdir -p $(dir $@)
$(CXX) $(CXXFLAGS) -MMD -MP -c $< -o $@
core: $(OBJECTS)
$(CXX) $(OBJECTS) $(LDFLAGS) $(LDLIBS) -o $@
clean:
rm -f core
rm -rf build
-include $(DEPS)