From 0d2bfe5c65b0820c84d77039b2b720194f44e68a Mon Sep 17 00:00:00 2001 From: joshua stein Date: Tue, 25 Feb 2020 11:21:28 -0600 Subject: [PATCH] Build: Only look at SUBDIRS with Makefiles If a directory is renamed or deleted before 'make clean', git will delete the Makefile but leave all of the object and dependency files around. When make would try to recurse into that directory from the wildcard, it would error out since there is no Makefile. --- Applications/Makefile | 2 +- Demos/Makefile | 2 +- DevTools/Makefile | 2 +- Games/Makefile | 2 +- Libraries/Makefile | 2 +- MenuApplets/Makefile | 2 +- Servers/Makefile | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Applications/Makefile b/Applications/Makefile index 6a7b80e895..0025ae2061 100644 --- a/Applications/Makefile +++ b/Applications/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/Demos/Makefile b/Demos/Makefile index 6a7b80e895..0025ae2061 100644 --- a/Demos/Makefile +++ b/Demos/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/DevTools/Makefile b/DevTools/Makefile index 6a7b80e895..0025ae2061 100644 --- a/DevTools/Makefile +++ b/DevTools/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/Games/Makefile b/Games/Makefile index 6a7b80e895..0025ae2061 100644 --- a/Games/Makefile +++ b/Games/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/Libraries/Makefile b/Libraries/Makefile index 6a7b80e895..0025ae2061 100644 --- a/Libraries/Makefile +++ b/Libraries/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/MenuApplets/Makefile b/MenuApplets/Makefile index 6a7b80e895..0025ae2061 100644 --- a/MenuApplets/Makefile +++ b/MenuApplets/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir diff --git a/Servers/Makefile b/Servers/Makefile index 6a7b80e895..0025ae2061 100644 --- a/Servers/Makefile +++ b/Servers/Makefile @@ -1,3 +1,3 @@ -SUBDIRS := $(wildcard */.) +SUBDIRS := $(patsubst %/Makefile,%/,$(wildcard */Makefile)) include ../Makefile.subdir