From 86229197cfefac9934854510fd2b85602e8037b3 Mon Sep 17 00:00:00 2001 From: Andrew Cooper Date: Mon, 7 Jul 2014 11:26:48 +0100 Subject: [PATCH] tools/python: Improve .gitignore and clean Makefile rule 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 Acked-by: Ian Campbell --- .gitignore | 1 + tools/python/Makefile | 8 +++----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 562c2629fa..cf9264f6e9 100644 --- a/.gitignore +++ b/.gitignore @@ -16,6 +16,7 @@ *.spit *.gcno *.gcda +*.py[ocd] TAGS GTAGS GRTAGS diff --git a/tools/python/Makefile b/tools/python/Makefile index eee746da71..c9143322d9 100644 --- a/tools/python/Makefile +++ b/tools/python/Makefile @@ -29,10 +29,8 @@ test: .PHONY: clean clean: - 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 + rm -rf build/ + rm -f $(XENPATH) $(DEPS) -include $(DEPS) -- 2.30.2