diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -4,6 +4,7 @@ BUILD_DIR := build CFLAGS := -Wall -Wextra -pedantic -std=c11 -ggdb SRCS := $(wildcard $(SRC_DIR)/*.c) +HEADERS := $(wildcard $(SRC_DIR)/*.h) OBJS := $(patsubst $(SRC_DIR)/%.c, $(BUILD_DIR)/%.o, $(SRCS)) .PHONY: all @@ -15,6 +16,11 @@ $(TARGET): $(BUILD_DIR) $(OBJS) $(BUILD_DIR): @mkdir -p $@ +.PHONY: linter +linter: $(SRCS) $(HEADERS) + clang-format --dry-run --Werror $? + $(MAKE) -C test linter + .PHONY: test test: $(TARGET) $(MAKE) -C test |