diff mbox series

[PULL,05/30] Makefile: wrap ctags in quiet-command calls

Message ID 20210115130828.23968-6-alex.bennee@linaro.org (mailing list archive)
State New, archived
Headers show
Series [PULL,01/30] tests/docker: Remove Debian 9 remnant lines | expand

Commit Message

Alex Bennée Jan. 15, 2021, 1:08 p.m. UTC
For prettier output.

Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Willian Rampazzo <willianr@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>

Comments

Philippe Mathieu-Daudé Jan. 18, 2021, 6:36 p.m. UTC | #1
Hi Alex,

On Fri, Jan 15, 2021 at 2:08 PM Alex Bennée <alex.bennee@linaro.org> wrote:
>
> For prettier output.
>
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> Reviewed-by: Willian Rampazzo <willianr@redhat.com>
> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>
>
> diff --git a/Makefile b/Makefile
> index 0c509a7704..bbab640b31 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -250,8 +250,13 @@ find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
>
>  .PHONY: ctags
>  ctags:
> -       rm -f "$(SRC_PATH)/"tags
> -       $(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
> +       $(call quiet-command,                   \
> +               rm -f "$(SRC_PATH)/"tags,       \
> +               "CTAGS", "Remove old tags")
> +       $(call quiet-command, \
> +               $(find-src-path) -exec ctags            \
> +               -f "$(SRC_PATH)/"tags --append {} +,    \
> +               "CTAGS", "Re-index $(SRC_PATH)")
>
>  .PHONY: gtags
>  gtags:
> --
> 2.20.1
>

Build now fails if ctags is not installed:

$ if test -n "$MAKE_CHECK_ARGS"; then make -j"$JOBS" $MAKE_CHECK_ARGS ; fi
CTAGS Remove old tags
CTAGS Re-index /builds/philmd/qemu
find: 'ctags': No such file or directory
find: 'ctags': No such file or directory
find: 'ctags': No such file or directory
make: *** [Makefile:254: ctags] Error 1
make: *** Waiting for unfinished jobs....
Alex Bennée Jan. 19, 2021, 10 a.m. UTC | #2
Philippe Mathieu-Daudé <philmd@redhat.com> writes:

> Hi Alex,
>
> On Fri, Jan 15, 2021 at 2:08 PM Alex Bennée <alex.bennee@linaro.org> wrote:
>>
>> For prettier output.
>>
>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
>> Reviewed-by: Willian Rampazzo <willianr@redhat.com>
>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>> Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>
>>
>> diff --git a/Makefile b/Makefile
>> index 0c509a7704..bbab640b31 100644
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -250,8 +250,13 @@ find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
>>
>>  .PHONY: ctags
>>  ctags:
>> -       rm -f "$(SRC_PATH)/"tags
>> -       $(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
>> +       $(call quiet-command,                   \
>> +               rm -f "$(SRC_PATH)/"tags,       \
>> +               "CTAGS", "Remove old tags")
>> +       $(call quiet-command, \
>> +               $(find-src-path) -exec ctags            \
>> +               -f "$(SRC_PATH)/"tags --append {} +,    \
>> +               "CTAGS", "Re-index $(SRC_PATH)")
>>
>>  .PHONY: gtags
>>  gtags:
>> --
>> 2.20.1
>>
>
> Build now fails if ctags is not installed:
>
> $ if test -n "$MAKE_CHECK_ARGS"; then make -j"$JOBS" $MAKE_CHECK_ARGS ; fi
> CTAGS Remove old tags
> CTAGS Re-index /builds/philmd/qemu
> find: 'ctags': No such file or directory
> find: 'ctags': No such file or directory
> find: 'ctags': No such file or directory
> make: *** [Makefile:254: ctags] Error 1
> make: *** Waiting for unfinished jobs....

Wait what, how? Have you got ctags in your MAKE_CHECK_ARGS? How did it
not fail before?

I suppose we could add checks for all the tooling in meson but it seems
a little overkill for a developer convenience.
Philippe Mathieu-Daudé Jan. 19, 2021, 2:24 p.m. UTC | #3
+Daniel

On 1/19/21 11:00 AM, Alex Bennée wrote:
> Philippe Mathieu-Daudé <philmd@redhat.com> writes:
>> On Fri, Jan 15, 2021 at 2:08 PM Alex Bennée <alex.bennee@linaro.org> wrote:
>>>
>>> For prettier output.
>>>
>>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
>>> Reviewed-by: Willian Rampazzo <willianr@redhat.com>
>>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>>> Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>
>>>
>>> diff --git a/Makefile b/Makefile
>>> index 0c509a7704..bbab640b31 100644
>>> --- a/Makefile
>>> +++ b/Makefile
>>> @@ -250,8 +250,13 @@ find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
>>>
>>>  .PHONY: ctags
>>>  ctags:
>>> -       rm -f "$(SRC_PATH)/"tags
>>> -       $(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
>>> +       $(call quiet-command,                   \
>>> +               rm -f "$(SRC_PATH)/"tags,       \
>>> +               "CTAGS", "Remove old tags")
>>> +       $(call quiet-command, \
>>> +               $(find-src-path) -exec ctags            \
>>> +               -f "$(SRC_PATH)/"tags --append {} +,    \
>>> +               "CTAGS", "Re-index $(SRC_PATH)")
>>>
>>>  .PHONY: gtags
>>>  gtags:
>>> --
>>> 2.20.1
>>>
>>
>> Build now fails if ctags is not installed:
>>
>> $ if test -n "$MAKE_CHECK_ARGS"; then make -j"$JOBS" $MAKE_CHECK_ARGS ; fi
>> CTAGS Remove old tags
>> CTAGS Re-index /builds/philmd/qemu
>> find: 'ctags': No such file or directory
>> find: 'ctags': No such file or directory
>> find: 'ctags': No such file or directory
>> make: *** [Makefile:254: ctags] Error 1
>> make: *** Waiting for unfinished jobs....
> 
> Wait what, how? Have you got ctags in your MAKE_CHECK_ARGS? How did it
> not fail before?
> 
> I suppose we could add checks for all the tooling in meson but it seems
> a little overkill for a developer convenience.  

I figured out I was still using the Docker images generated after
testing Daniel's 'start using libvirt-ci's "lcitool" for dockerfiles'
series:
https://www.mail-archive.com/qemu-devel@nongnu.org/msg772839.html

Daniel, lcitool's ansible/vars/projects/qemu.yml apparently has
a strong dependency on ctags.

Regards,

Phil.
Daniel P. Berrangé Jan. 19, 2021, 2:27 p.m. UTC | #4
On Tue, Jan 19, 2021 at 03:24:56PM +0100, Philippe Mathieu-Daudé wrote:
> +Daniel
> 
> On 1/19/21 11:00 AM, Alex Bennée wrote:
> > Philippe Mathieu-Daudé <philmd@redhat.com> writes:
> >> On Fri, Jan 15, 2021 at 2:08 PM Alex Bennée <alex.bennee@linaro.org> wrote:
> >>>
> >>> For prettier output.
> >>>
> >>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> >>> Reviewed-by: Willian Rampazzo <willianr@redhat.com>
> >>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> >>> Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>
> >>>
> >>> diff --git a/Makefile b/Makefile
> >>> index 0c509a7704..bbab640b31 100644
> >>> --- a/Makefile
> >>> +++ b/Makefile
> >>> @@ -250,8 +250,13 @@ find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
> >>>
> >>>  .PHONY: ctags
> >>>  ctags:
> >>> -       rm -f "$(SRC_PATH)/"tags
> >>> -       $(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
> >>> +       $(call quiet-command,                   \
> >>> +               rm -f "$(SRC_PATH)/"tags,       \
> >>> +               "CTAGS", "Remove old tags")
> >>> +       $(call quiet-command, \
> >>> +               $(find-src-path) -exec ctags            \
> >>> +               -f "$(SRC_PATH)/"tags --append {} +,    \
> >>> +               "CTAGS", "Re-index $(SRC_PATH)")
> >>>
> >>>  .PHONY: gtags
> >>>  gtags:
> >>> --
> >>> 2.20.1
> >>>
> >>
> >> Build now fails if ctags is not installed:
> >>
> >> $ if test -n "$MAKE_CHECK_ARGS"; then make -j"$JOBS" $MAKE_CHECK_ARGS ; fi
> >> CTAGS Remove old tags
> >> CTAGS Re-index /builds/philmd/qemu
> >> find: 'ctags': No such file or directory
> >> find: 'ctags': No such file or directory
> >> find: 'ctags': No such file or directory
> >> make: *** [Makefile:254: ctags] Error 1
> >> make: *** Waiting for unfinished jobs....
> > 
> > Wait what, how? Have you got ctags in your MAKE_CHECK_ARGS? How did it
> > not fail before?
> > 
> > I suppose we could add checks for all the tooling in meson but it seems
> > a little overkill for a developer convenience.  
> 
> I figured out I was still using the Docker images generated after
> testing Daniel's 'start using libvirt-ci's "lcitool" for dockerfiles'
> series:
> https://www.mail-archive.com/qemu-devel@nongnu.org/msg772839.html
> 
> Daniel, lcitool's ansible/vars/projects/qemu.yml apparently has
> a strong dependency on ctags.

Huh ?  It doesn't mention ctags at all.  If it is present, it is only as
a side-effect of a dependancy from some other package we genuinely do need.

Regards,
Daniel
Philippe Mathieu-Daudé Jan. 19, 2021, 2:42 p.m. UTC | #5
On 1/19/21 3:27 PM, Daniel P. Berrangé wrote:
> On Tue, Jan 19, 2021 at 03:24:56PM +0100, Philippe Mathieu-Daudé wrote:
>> +Daniel
>>
>> On 1/19/21 11:00 AM, Alex Bennée wrote:
>>> Philippe Mathieu-Daudé <philmd@redhat.com> writes:
>>>> On Fri, Jan 15, 2021 at 2:08 PM Alex Bennée <alex.bennee@linaro.org> wrote:
>>>>>
>>>>> For prettier output.
>>>>>
>>>>> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
>>>>> Reviewed-by: Willian Rampazzo <willianr@redhat.com>
>>>>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>>>>> Message-Id: <20210114165730.31607-6-alex.bennee@linaro.org>
>>>>>
>>>>> diff --git a/Makefile b/Makefile
>>>>> index 0c509a7704..bbab640b31 100644
>>>>> --- a/Makefile
>>>>> +++ b/Makefile
>>>>> @@ -250,8 +250,13 @@ find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
>>>>>
>>>>>  .PHONY: ctags
>>>>>  ctags:
>>>>> -       rm -f "$(SRC_PATH)/"tags
>>>>> -       $(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
>>>>> +       $(call quiet-command,                   \
>>>>> +               rm -f "$(SRC_PATH)/"tags,       \
>>>>> +               "CTAGS", "Remove old tags")
>>>>> +       $(call quiet-command, \
>>>>> +               $(find-src-path) -exec ctags            \
>>>>> +               -f "$(SRC_PATH)/"tags --append {} +,    \
>>>>> +               "CTAGS", "Re-index $(SRC_PATH)")
>>>>>
>>>>>  .PHONY: gtags
>>>>>  gtags:
>>>>> --
>>>>> 2.20.1
>>>>>
>>>>
>>>> Build now fails if ctags is not installed:
>>>>
>>>> $ if test -n "$MAKE_CHECK_ARGS"; then make -j"$JOBS" $MAKE_CHECK_ARGS ; fi
>>>> CTAGS Remove old tags
>>>> CTAGS Re-index /builds/philmd/qemu
>>>> find: 'ctags': No such file or directory
>>>> find: 'ctags': No such file or directory
>>>> find: 'ctags': No such file or directory
>>>> make: *** [Makefile:254: ctags] Error 1
>>>> make: *** Waiting for unfinished jobs....
>>>
>>> Wait what, how? Have you got ctags in your MAKE_CHECK_ARGS? How did it
>>> not fail before?
>>>
>>> I suppose we could add checks for all the tooling in meson but it seems
>>> a little overkill for a developer convenience.  
>>
>> I figured out I was still using the Docker images generated after
>> testing Daniel's 'start using libvirt-ci's "lcitool" for dockerfiles'
>> series:
>> https://www.mail-archive.com/qemu-devel@nongnu.org/msg772839.html
>>
>> Daniel, lcitool's ansible/vars/projects/qemu.yml apparently has
>> a strong dependency on ctags.
> 
> Huh ?  It doesn't mention ctags at all.  If it is present, it is only as
> a side-effect of a dependancy from some other package we genuinely do need.

Sorry, I meant QEMU as a strong dependency on ctags.

I'll send a patch to lcitool.

Regards,

Phil.
diff mbox series

Patch

diff --git a/Makefile b/Makefile
index 0c509a7704..bbab640b31 100644
--- a/Makefile
+++ b/Makefile
@@ -250,8 +250,13 @@  find-src-path = find "$(SRC_PATH)/" -path "$(SRC_PATH)/meson" -prune -o \( -name
 
 .PHONY: ctags
 ctags:
-	rm -f "$(SRC_PATH)/"tags
-	$(find-src-path) -exec ctags -f "$(SRC_PATH)/"tags --append {} +
+	$(call quiet-command, 			\
+		rm -f "$(SRC_PATH)/"tags, 	\
+		"CTAGS", "Remove old tags")
+	$(call quiet-command, \
+		$(find-src-path) -exec ctags 		\
+		-f "$(SRC_PATH)/"tags --append {} +,	\
+		"CTAGS", "Re-index $(SRC_PATH)")
 
 .PHONY: gtags
 gtags: