Patchwork [1/1] Makefile: updated the rule TAG

login
register
mail settings
Submitter Bique Alexandre
Date Aug. 6, 2009, 7:14 p.m.
Message ID <200908062014.20709.alexandre.bique@citrix.com>
Download mbox | patch
Permalink /patch/30876/
State Superseded
Headers show

Comments

Bique Alexandre - Aug. 6, 2009, 7:14 p.m.
Better rule TAG:
 - still works if the build dir is not the src dir
 - use find instead of *.c block/*.c etc...
Bique Alexandre - Aug. 7, 2009, 2:43 p.m.
On Thursday 06 August 2009 20:14:20 Bique Alexandre wrote:
> Better rule TAG:
>  - still works if the build dir is not the src dir
>  - use find instead of *.c block/*.c etc...
I discard this patch. I resend it correctly.

Sorry.

Patch

diff --git a/Makefile b/Makefile
index 2a4b3f3..df5b5c4 100644
--- a/Makefile
+++ b/Makefile
@@ -300,8 +300,9 @@  endif
 test speed: all
 	$(MAKE) -C tests $@
 
+.PHONY: TAGS
 TAGS:
-	etags *.[ch] tests/*.[ch] block/*.[ch] hw/*.[ch]
+	find "$(SRC_PATH)" -name '*.[hc]' -print0 | xargs -0 etags
 
 cscope:
 	rm -f ./cscope.*