diff mbox

Makefile: Fix tag file generation targets

Message ID 1465495115-24665-1-git-send-email-sergey.fedorov@linaro.org
State New
Headers show

Commit Message

sergey.fedorov@linaro.org June 9, 2016, 5:58 p.m. UTC
From: Sergey Fedorov <serge.fdrv@gmail.com>

"ctags" produces a file named "tags", not "ctags". It doesn't look
reasonable to use phony target name as a file name to remove. Just use
exact file names to remove in "ctags" and "TAGS" target receipts.

Signed-off-by: Sergey Fedorov <serge.fdrv@gmail.com>
Signed-off-by: Sergey Fedorov <sergey.fedorov@linaro.org>
---
 Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Paolo Bonzini June 13, 2016, 9:30 a.m. UTC | #1
On 09/06/2016 19:58, Sergey Fedorov wrote:
> From: Sergey Fedorov <serge.fdrv@gmail.com>
> 
> "ctags" produces a file named "tags", not "ctags". It doesn't look
> reasonable to use phony target name as a file name to remove. Just use
> exact file names to remove in "ctags" and "TAGS" target receipts.
> 
> Signed-off-by: Sergey Fedorov <serge.fdrv@gmail.com>
> Signed-off-by: Sergey Fedorov <sergey.fedorov@linaro.org>
> ---
>  Makefile | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index b8563db68677..61bf1bf9e2bb 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -478,12 +478,12 @@ test speed: all
>  
>  .PHONY: ctags
>  ctags:
> -	rm -f $@
> +	rm -f tags
>  	find "$(SRC_PATH)" -name '*.[hc]' -exec ctags --append {} +
>  
>  .PHONY: TAGS
>  TAGS:
> -	rm -f $@
> +	rm -f TAGS
>  	find "$(SRC_PATH)" -name '*.[hc]' -exec etags --append {} +
>  
>  cscope:
> 

Queued, thanks.

Paolo
diff mbox

Patch

diff --git a/Makefile b/Makefile
index b8563db68677..61bf1bf9e2bb 100644
--- a/Makefile
+++ b/Makefile
@@ -478,12 +478,12 @@  test speed: all
 
 .PHONY: ctags
 ctags:
-	rm -f $@
+	rm -f tags
 	find "$(SRC_PATH)" -name '*.[hc]' -exec ctags --append {} +
 
 .PHONY: TAGS
 TAGS:
-	rm -f $@
+	rm -f TAGS
 	find "$(SRC_PATH)" -name '*.[hc]' -exec etags --append {} +
 
 cscope: