blob: 39097f354505842f4fd594d9385aeb981dd22512 (
plain) (
blame)
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
54
55
56
57
58
59
60
61
|
.PHONY: clean build build-release dev-setup build-dev install build-source test run check fmt docs
all: build-dev
PREFIX = "${PWD}/build/installdir"
LUA_PREFIX = ""
build-source:
@mkdir -p build
@cd build/ && cmake .. \
-G Ninja \
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
&& cmake --build . -j10
dev-setup:
@cp build/compile_commands.json .
build-dev: build-source dev-setup
build:
RELEASE=1 make build-source LUA_PREFIX="${PREFIX}/lua"
install:
cd build && cmake --install . --prefix "${PREFIX}"
test: build-source
cd build && QT_QPA_PLATFORM=offscreen ctest -V
clean:
ccache -C || true
rm -rf build/
rm -f compile_commands.json
run: build-dev
./build/null-browser $(ARGS)
debug:
DEBUG=1 make build-dev
gdb ./build/null-browser
fmt:
clang-format -i ./src/**/*.{hpp,cpp}
check: fmt
clang-tidy --config-file=.clang-tidy ./src/**/*.{hpp,cpp}
docs:
# API reference pages
ldoc -p null-browser -t "Null browser api" \
--merge --ignore --lls \
--dir ./docs/api \
./lua/null-browser/
# Symbols json
ldoc --merge --ignore --lls \
./lua/null-browser/ \
--dir ./docs/api \
--filter ldoc_json_filter.lua;
# appimage:
# nix bundle --bundler github:ralismark/nix-appimage
|