[1/1] Makefile: updated the rule TAG

Submitted by Bique Alexandre on Aug. 6, 2009, 7:14 p.m.

Details

Message ID 200908062014.20709.alexandre.bique@citrix.com
State Superseded
Headers show

Commit Message

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...

Comments

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 hide | download patch | download mbox

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.*