simplify clobber behavior with out-of-tree builds
authorMike Frysinger <vapier@gentoo.org>
Fri, 24 Jun 2011 18:37:55 +0000 (18:37 +0000)
committerWolfgang Denk <wd@denx.de>
Tue, 26 Jul 2011 14:53:23 +0000 (16:53 +0200)
The targets/prerequisites are the same here; the rules only differ in
the recipes.  So move the if logic protection to the recipe part so we
can keep the rest the same.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Makefile

index 0707036699a2fe5bc5ae9ece1abd91a09d11afe3..869755ac65252dfe531c5533ae86037e6c0e4792 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1105,12 +1105,9 @@ clobber: clean
        @[ ! -d $(obj)onenand_ipl ] || find $(obj)onenand_ipl -name "*" -type l -print | xargs rm -f
        @[ ! -d $(obj)mmc_spl ] || find $(obj)mmc_spl -name "*" -type l -print | xargs rm -f
 
-ifeq ($(OBJTREE),$(SRCTREE))
-mrproper \
-distclean:     clobber unconfig
-else
 mrproper \
 distclean:     clobber unconfig
+ifneq ($(OBJTREE),$(SRCTREE))
        rm -rf $(obj)*
 endif