-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
32 lines (25 loc) · 880 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
CC=g++-4.9
CFLAGS=-std=c++11 -rdynamic -Wl,--no-as-needed -pthread -g -Wall -pthread -I./
LDFLAGS= -ltbb -ldtranx -llogcabin -lpthread -lprotobuf -lzmq -lhyperdex-client\
-lboost_thread -lboost_system -lboost_chrono -lbtree -lrtree -lprofiler -lpmemlog -lleveldb -lcryptopp -lmetis
SUBDIRS=Core DB Scripts Util
SUBSRCS=$(wildcard Core/*.cc) $(wildcard DB/*.cc) $(wildcard DB/tabledb/*.cc) $(wildcard Util/*.cc)
SUBHEADERS=$(wildcard Core/*.h) $(wildcard DB/*.h) $(wildcard Util/*.h)
OBJECTS=$(SUBSRCS:.cc=.o)
EXEC=ycsbc
all: $(SUBDIRS) $(EXEC)
$(SUBDIRS):
$(MAKE) -C $@
$(EXEC): $(EXEC).cc $(OBJECTS) $(SUBHEADERS)
$(CC) $(CFLAGS) $(EXEC).cc $(OBJECTS) $(LDFLAGS) -o $@
clean:
for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir $@; \
done
cd Test/UnitTest && $(MAKE) clean
cd ../..
$(RM) $(EXEC)
.PHONY: $(SUBDIRS)
unit:
cd Test/UnitTest && $(MAKE)
.DEFUALT_GOAL = all