tools/python: Improve .gitignore and clean Makefile rule
authorAndrew Cooper <andrew.cooper3@citrix.com>
Mon, 7 Jul 2014 10:26:48 +0000 (11:26 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Thu, 10 Jul 2014 10:30:32 +0000 (11:30 +0100)
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 <andrew.cooper3@citrix.com>
CC: Ian Campbell <Ian.Campbell@citrix.com>
CC: Ian Jackson <Ian.Jackson@eu.citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
.gitignore
tools/python/Makefile

index 562c2629fab1513678060fbbe78a9f9bbf678155..cf9264f6e9bb42e650d5c2e0c9ea48e5dd1b4acf 100644 (file)
@@ -16,6 +16,7 @@
 *.spit
 *.gcno
 *.gcda
+*.py[ocd]
 TAGS
 GTAGS
 GRTAGS
index eee746da71044cb14f09a574809adaa18d8a0a5c..c9143322d91aca587e538a4a5863ca78c9c7edac 100644 (file)
@@ -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)