From 4c35e6fe6734050b2e633aba330b0e389835fbc4 Mon Sep 17 00:00:00 2001 From: Daniel Hahler Date: Sun, 4 Aug 2019 17:13:04 +0200 Subject: [PATCH] Makefile: only use pattern rules with BUILD_TYPE=Ninja (#10687) While not doing any harm with "Unix Makefiles", they do not work there as-is. Therefore just do not use them then. Followup to #10366 (7f6ff829a). --- Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Makefile b/Makefile index 40d374b75f..e2cf4a3b29 100644 --- a/Makefile +++ b/Makefile @@ -184,10 +184,14 @@ appimage-%: lint: check-single-includes clint lualint pylint +# Generic pattern rules, allowing for `make build/bin/nvim` etc. +# Does not work with "Unix Makefiles". +ifeq ($(BUILD_TYPE),Ninja) build/%: $(BUILD_CMD) -C build $(patsubst build/%,%,$@) $(DEPS_BUILD_DIR)/%: $(BUILD_CMD) -C $(DEPS_BUILD_DIR) $(patsubst $(DEPS_BUILD_DIR)/%,%,$@) +endif .PHONY: test lualint pylint functionaltest unittest lint clint clean distclean nvim libnvim cmake deps install appimage checkprefix