From: Ian Campbell Subject: Re: [PATCH v2] tools/python: Improve .gitgnore and clean Makefile rule Date: Wed, 9 Jul 2014 17:49:48 +0100 Message-ID: <1404924588.26217.8.camel@hastur.hellion.org.uk> References: <1404728808-15223-1-git-send-email-andrew.cooper3@citrix.com> <1404920820.11945.45.camel@hastur.hellion.org.uk> <53BD68D9.9060400@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <53BD68D9.9060400@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: Ian Jackson , Xen-devel List-Id: xen-devel@lists.xenproject.org On Wed, 2014-07-09 at 17:07 +0100, Andrew Cooper wrote: > On 09/07/14 16:47, Ian Campbell wrote: > > On Mon, 2014-07-07 at 11:26 +0100, Andrew Cooper wrote: > >> Ignore all intermediate python files, and use find in the clean rule as there > >> are no Makefiles in subdirectories to participate in a recursive clean. > >> > >> Signed-off-by: Andrew Cooper > >> CC: Ian Campbell > >> CC: Ian Jackson > >> diff --git a/.gitignore b/.gitignore > >> index 562c262..cf9264f 100644 > >> --- a/.gitignore > >> +++ b/.gitignore > >> @@ -16,6 +16,7 @@ > >> *.spit > >> *.gcno > >> *.gcda > >> +*.py[ocd] > > FWIW there are a bunch of explicit foo.pyc listed which could now be > > removed I guess. > > True. > > > > >> - rm -f $(XENPATH) > >> - rm -rf build/ *.pyc *.pyo *.o *.a *~ xen/util/auxbin.pyc > >> - rm -f xen/lowlevel/xl/_pyxl_types.h > >> - rm -f xen/lowlevel/xl/_pyxl_types.c > >> - rm -f $(DEPS) > >> + find . \( -name "*.py[ocd]" -o -name "*~" -o -name "_*.[hc]" \) -delete > > I've assumed the lack of *.a in here is deliberate but *.o? > > > > Ian. > > > > No object files or libraries will be generated outside of build/ Ah, right. > If we wish to cater to devs doing out-of-band builds in subdirectires > then more than .o and .a should be included in this find. no need: Acked-by: Ian Campbell