Files
doos/Makefile
T
2026-10-23 23:42:00 +02:00

39 lines
1.4 KiB
Makefile

# Thin wrapper over the commands used to build, test and update the project. CMake does the building,
# scripts/ and docs/charts/ do the rest. `make help` lists the targets.
.DEFAULT_GOAL := help
BUILD ?= build
DOOS := $(BUILD)/doos
.PHONY: help build test audit check-docs bench charts docs release clean
help: ## list the targets
@grep -hE '^[a-z-]+:.*##' $(MAKEFILE_LIST) | sed -E 's/:.*## /\t/' | column -t -s "$$(printf '\t')"
build: ## configure and compile into build/
cmake -S . -B $(BUILD) >/dev/null
cmake --build $(BUILD)
test: build ## end-to-end suite (real downloads, needs network, pasta, gpg, cgroup v2)
tests/run.sh $(DOOS)
audit: build ## run the CVE regression checks under audit/ against build/doos (concurrent, -j)
$(MAKE) -C audit -j8 test DOOS=$(abspath $(DOOS))
check-docs: ## every document links to every other, every relative link resolves
scripts/check-docs.sh
bench: build ## re-measure startup, binary sizes and cpu limit into docs/charts/bench.json
scripts/bench.sh
charts: ## rebuild docs/charts/*.svg and the generated numbers in COMPARISON.md from bench.json
python3 docs/charts/make_charts.py
docs: charts check-docs ## charts plus the docs check
release: ## KIND=patch|minor|major MSG="subject": bump, build, test, commit, tag
@test -n "$(KIND)" -a -n "$(MSG)" || { echo 'usage: make release KIND=patch MSG="subject"'; exit 2; }
scripts/release.sh $(KIND) "$(MSG)"
clean: ## remove build/
rm -rf $(BUILD)