Received: from eggs.gnu.org ([208.118.235.92]:33932) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SwEh1-0003HU-Vh for qemu-devel@nongnu.org; Tue, 31 Jul 2012 11:49:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SwEh0-0005zH-VU for qemu-devel@nongnu.org; Tue, 31 Jul 2012 11:49:07 -0400 Message-ID: <5017FE6F.7090107@weilnetz.de> Date: Tue, 31 Jul 2012 17:49:03 +0200 From: Stefan Weil MIME-Version: 1.0 References: <1343739695-7757-1-git-send-email-peter.maydell@linaro.org> <87pq7c9fng.fsf@blackfin.pond.sub.org> <87k3xk577l.fsf@blackfin.pond.sub.org> <20120731143834.GJ2475@redhat.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] Makefile: Avoid explicit list of directories in clean target List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: patches@linaro.org, qemu-trivial@nongnu.org, Stefan Weil , Markus Armbruster , qemu-devel@nongnu.org, Jan Kiszka , Stefan Hajnoczi Am 31.07.2012 17:00, schrieb Peter Maydell: > On 31 July 2012 15:38, Daniel P. Berrange wrote: >> Isn't using 'find' somewhat overkill here really. QEMU only creates >> .o and .d files in 2 levels of directory, so sure we can just avoid >> find entirely >> >> rm -f *.[od] */*.[od] > > That's exactly the bug this change is addressing (in a more > general way than a couple of the proposed point fixes). There > are subdirectories of hw/, so for instance we have a hw/usb/bus.o > which your rm would not delete. > > -- PMM Yes, QEMU creates files in 3 levels. We could use rm -f *.[od] */*.[od] */*/*.[od] I suggest using the wrapper $(call quiet-command,...) to suppress printing of all removed file names. For me, your patch using find would also be sufficient. Only developers use "make clean", and they should know how to name files. Even if there are files with blanks in their name, in most cases nothing bad will happen (as long as they are not named "-rf .. .o" which would be the worst scenario I can imagine). Regards, Stefan W.