From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:59656) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Si0Lu-0005N0-Gk for qemu-devel@nongnu.org; Fri, 22 Jun 2012 05:40:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Si0Lo-00059z-6b for qemu-devel@nongnu.org; Fri, 22 Jun 2012 05:40:30 -0400 Received: from e06smtp14.uk.ibm.com ([195.75.94.110]:45787) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Si0Ln-00057c-SV for qemu-devel@nongnu.org; Fri, 22 Jun 2012 05:40:24 -0400 Received: from /spool/local by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 22 Jun 2012 10:40:20 +0100 Received: from d06av02.portsmouth.uk.ibm.com (d06av02.portsmouth.uk.ibm.com [9.149.37.228]) by d06nrmr1707.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q5M9eH0G2244646 for ; Fri, 22 Jun 2012 10:40:17 +0100 Received: from d06av02.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av02.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q5M9eGPU009864 for ; Fri, 22 Jun 2012 03:40:17 -0600 From: Stefan Hajnoczi Date: Fri, 22 Jun 2012 10:40:07 +0100 Message-Id: <1340358009-16033-11-git-send-email-stefanha@linux.vnet.ibm.com> In-Reply-To: <1340358009-16033-1-git-send-email-stefanha@linux.vnet.ibm.com> References: <1340358009-16033-1-git-send-email-stefanha@linux.vnet.ibm.com> Subject: [Qemu-devel] [PATCH 10/12] Makefile.hw: avoid overly large 'make clean' rm command List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Peter Maydell , qemu-devel@nongnu.org, Stefan Hajnoczi From: Peter Maydell Avoid 'make clean' producing an 'rm' command which has a lot of duplicate 'hw//*.o' arguments, by using $(sort $(dir ..)) rather than $(dir $(sort ..)) so Make's sort function will remove the duplicates for us. We can also remove the double '//' safely because $(dir ..) is guaranteed to return a string ending in '/'. Signed-off-by: Peter Maydell Signed-off-by: Stefan Hajnoczi --- Makefile.hw | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.hw b/Makefile.hw index 2bcbaff..28fe100 100644 --- a/Makefile.hw +++ b/Makefile.hw @@ -19,8 +19,8 @@ all: $(hw-obj-y) @true clean: - rm -f $(addsuffix /*.o, $(dir $(sort $(hw-obj-y)))) - rm -f $(addsuffix /*.d, $(dir $(sort $(hw-obj-y)))) + rm -f $(addsuffix *.o, $(sort $(dir $(hw-obj-y)))) + rm -f $(addsuffix *.d, $(sort $(dir $(hw-obj-y)))) # Include automatically generated dependency files -include $(patsubst %.o, %.d, $(hw-obj-y)) -- 1.7.10