aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2015-01-08 14:35:00 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2015-01-08 14:35:00 -0800
commit11c8f01b423b2d9742ce21e44cb7da7b55429ad5 (patch)
treec4348f0c077960f10aa2c408e3d17ea9ea3a6a1a
parent90ac086bca100c654e84637d9990567f436cab23 (diff)
parenta16c5f99a28c9945165c46da27fff8e6f26f8736 (diff)
downloadgfs2-3.0-nmw-origin.tar.gz
Merge branch 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuildorigin
Pull kbuild fix from Michal Marek: "make mrproper / distclean stopped removing the generated debian/ directory in v3.16. This fixes it" * 'rc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: kbuild: Fix removal of the debian/ directory
-rw-r--r--scripts/Makefile.clean16
1 files changed, 8 insertions, 8 deletions
diff --git a/scripts/Makefile.clean b/scripts/Makefile.clean
index 1bca180db8ad0..627f8cbbedb88 100644
--- a/scripts/Makefile.clean
+++ b/scripts/Makefile.clean
@@ -42,19 +42,19 @@ __clean-files := $(extra-y) $(extra-m) $(extra-) \
__clean-files := $(filter-out $(no-clean-files), $(__clean-files))
-# as clean-files is given relative to the current directory, this adds
-# a $(obj) prefix, except for absolute paths
+# clean-files is given relative to the current directory, unless it
+# starts with $(objtree)/ (which means "./", so do not add "./" unless
+# you want to delete a file from the toplevel object directory).
__clean-files := $(wildcard \
- $(addprefix $(obj)/, $(filter-out /%, $(__clean-files))) \
- $(filter /%, $(__clean-files)))
+ $(addprefix $(obj)/, $(filter-out $(objtree)/%, $(__clean-files))) \
+ $(filter $(objtree)/%, $(__clean-files)))
-# as clean-dirs is given relative to the current directory, this adds
-# a $(obj) prefix, except for absolute paths
+# same as clean-files
__clean-dirs := $(wildcard \
- $(addprefix $(obj)/, $(filter-out /%, $(clean-dirs))) \
- $(filter /%, $(clean-dirs)))
+ $(addprefix $(obj)/, $(filter-out $(objtree)/%, $(clean-dirs))) \
+ $(filter $(objtree)/%, $(clean-dirs)))
# ==========================================================================