]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - scripts/Makefile.clean
Merge tag 'xfs-5.4-merge-8' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux
[linux.git] / scripts / Makefile.clean
index cbfbe13dc87d31f7d8a72b07872354829b78037c..e367eb95c5c0809ca57ac991c937df9696b583d0 100644 (file)
@@ -17,17 +17,8 @@ include $(if $(wildcard $(kbuild-dir)/Kbuild), $(kbuild-dir)/Kbuild, $(kbuild-di
 # Figure out what we need to build from the various variables
 # ==========================================================================
 
-__subdir-y     := $(patsubst %/,%,$(filter %/, $(obj-y)))
-subdir-y       += $(__subdir-y)
-__subdir-m     := $(patsubst %/,%,$(filter %/, $(obj-m)))
-subdir-m       += $(__subdir-m)
-__subdir-      := $(patsubst %/,%,$(filter %/, $(obj-)))
-subdir-                += $(__subdir-)
-
-# Subdirectories we need to descend into
-
-subdir-ym      := $(sort $(subdir-y) $(subdir-m))
-subdir-ymn      := $(sort $(subdir-ym) $(subdir-))
+subdir-ymn := $(sort $(subdir-y) $(subdir-m) $(subdir-) \
+               $(patsubst %/,%, $(filter %/, $(obj-y) $(obj-m) $(obj-))))
 
 # Add subdir path
 
@@ -59,7 +50,7 @@ quiet_cmd_clean = CLEAN   $(obj)
 
 __clean: $(subdir-ymn)
 ifneq ($(strip $(__clean-files)),)
-       +$(call cmd,clean)
+       $(call cmd,clean)
 endif
        @: