diff options
| author | Anders Betts <anders.betts@gmail.com> | 2026-09-20 22:08:08 +0200 |
|---|---|---|
| committer | Anders Betts <anders.betts@gmail.com> | 2026-09-20 22:08:08 +0200 |
| commit | 6ff31279d38bd3b814f19b1fb63933544139f6cf (patch) | |
| tree | e0a64a48df9d484b52829371d648698471895ffe /Makefile | |
| parent | 29969ad294d1654f6eca23a16c83b84bbf7f9bfe (diff) | |
| download | bokf-6ff31279d38bd3b814f19b1fb63933544139f6cf.tar.gz bokf-6ff31279d38bd3b814f19b1fb63933544139f6cf.zip | |
build: make gate with WERROR and a pre-push hook
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -5,6 +5,7 @@ VERSION ?= $(shell git describe --tags --always --dirty 2>/dev/null \ WARN = -Wall -Wextra -Wshadow -Wstrict-prototypes -Wmissing-prototypes \ -Wpointer-arith -Wvla -Wformat=2 +WARN += $(if $(WERROR),-Werror) DEPFLAGS = -MMD -MP CPPFLAGS = -Isrc -Iclients -Ivendor -Ivendor/argon2 DEFS = -D_GNU_SOURCE -DARGON2_NO_THREADS -DBOKF_VERSION=\"$(VERSION)\" @@ -109,6 +110,11 @@ test-asan: test-ubsan: $(MAKE) BUILD=build-ubsan CFLAGS="$(SAN_CFLAGS) -fsanitize=undefined" test-core +gate: + $(MAKE) clean + $(MAKE) WERROR=1 test + $(MAKE) WERROR=1 test-asan + $(BUILD)/vendor/%.o: vendor/%.c @mkdir -p $(dir $@) $(CC) $(CFLAGS) $(DEPFLAGS) $(CPPFLAGS) $(DEFS) -w -c $< -o $@ @@ -140,5 +146,5 @@ install: all clean: rm -rf $(BUILD) build-asan build-ubsan -.PHONY: all backend test test-core test-pty check test-asan test-ubsan \ +.PHONY: all backend test test-core test-pty check test-asan test-ubsan gate \ install clean |
