forked from duckdb/duckdb
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
53 lines (40 loc) · 1.16 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
44
45
46
47
48
49
50
51
52
53
.PHONY: all opt unit clean debug release test unittest allunit docs doxygen format sqlite
all: release
opt: release
unit: unittest
GENERATOR=
FORCE_COLOR=
ifeq ($(GEN),ninja)
GENERATOR=-G "Ninja"
FORCE_COLOR=-DFORCE_COLORED_OUTPUT=1
endif
clean:
rm -rf build
debug:
mkdir -p build/debug && \
cd build/debug && \
cmake $(GENERATOR) $(FORCE_COLOR) -DCMAKE_BUILD_TYPE=Debug ../.. && \
cmake --build .
release:
mkdir -p build/release && \
cd build/release && \
cmake $(GENERATOR) $(FORCE_COLOR) -DCMAKE_BUILD_TYPE=RelWithDebInfo ../.. && \
cmake --build .
unittest: debug
build/debug/test/unittest
allunit: release # uses release build because otherwise allunit takes forever
build/release/test/unittest "*"
docs:
mkdir -p build/docs && \
doxygen Doxyfile
doxygen: docs
open build/docs/html/index.html
format:
python format.py
third_party/sqllogictest:
git clone --depth=1 https://github.com/cwida/sqllogictest.git third_party/sqllogictest
sqlite: release | third_party/sqllogictest
git --git-dir third_party/sqllogictest/.git pull
./build/release/test/unittest "[sqlitelogic]"
sqlsmith: debug
./build/debug/third_party/sqlsmith/sqlsmith --duckdb=:memory: