-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
26 lines (23 loc) · 746 Bytes
/
Makefile
File metadata and controls
26 lines (23 loc) · 746 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
#不生成.o文件,一步到位得到可执行文件
cc = g++
target = database
INCLUDE = -I ./log -I ./core -I ./index -I ./index/BPlusTree -I ./storage -I ./operator -I ./executor -I ./lib -I ./sqlparser -I ./window
# debug mode default
ver = debug
ifeq ($(ver), debug)
# ALL: database_d
target = database_d
CXXFLAGS = -pthread -g -Ddebug -fpermissive
else
# ALL: database_r $(head)
target = database_r
CXXFLAGS = -pthread -O3 -fpermissive
endif
head = $(shell find ./log ./core ./storage -name "*.h")
src = $(shell find ./log ./core ./storage ./operator ./index ./executor ./sqlparser ./lib -name "*.cpp")
$(target): $(src)
$(cc) $(CXXFLAGS) $(INCLUDE) ./main.cpp $(src) -o $(target)
# ./$(target)
# rm $(target)
clear:
rm $(target)