From 61894c4588eb2b85e342a6f923eeb7ac97c3fe64 Mon Sep 17 00:00:00 2001 From: JDierkse Date: Fri, 7 Feb 2020 13:37:32 +0100 Subject: [PATCH] Don't build folders without Makefile --- Makefile | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/Makefile b/Makefile index 1f914f7..f327d0d 100644 --- a/Makefile +++ b/Makefile @@ -148,21 +148,23 @@ $(ARNAME): $(SUBDIRS) $(LOCALOBJECTS) .PHONY: $(SUBDIRS) $(SUBDIRS): - @depth=$(MAKELEVEL); \ - while [ $${depth} -gt 0 ] ; do \ - echo -n " "; \ - depth=`expr $$depth - 1`; \ - done; \ - true - @echo " <$@>" - @$(MAKE) -s -S -C $@ artifacts $(ARCH) - @depth=$(MAKELEVEL); \ - while [ $${depth} -gt 0 ] ; do \ - echo -n " "; \ - depth=`expr $$depth - 1`; \ - done; \ - true - @echo " " + @if [ -e "$@/Makefile" ]; then \ + depth=$(MAKELEVEL); \ + while [ $${depth} -gt 0 ] ; do \ + echo -n " "; \ + depth=`expr $$depth - 1`; \ + done; \ + true; \ + echo " <$@>"; \ + $(MAKE) -s -S -C $@ artifacts $(ARCH); \ + depth=$(MAKELEVEL); \ + while [ $${depth} -gt 0 ] ; do \ + echo -n " "; \ + depth=`expr $$depth - 1`; \ + done; \ + true; \ + echo " "; \ + fi .PHONY: all all: $(TARGETS)