[PATCH 2/3] build: add optional target parameter to quiet variable function

Jani Nikula jani at nikula.org
Wed Aug 30 08:10:33 PDT 2017


On Tue, 29 Aug 2017, David Bremner <david at tethera.net> wrote:
> Jani Nikula <jani at nikula.org> writes:
>
>> Sometimes using $@ as the target in the quiet build lines can be
>> confusing. Accept an optional second parameter in the quiet variable
>> function to specify the target.
>
> I'm OK with this, but I wondered about a simpler change: always use $<.
> I doesn't strictly make sense to write "CXX  -g -O2
> test/make-db-version.o". When is $@ better here?

For compiling C, C++, and elisp $< does seem better. However, for AR and
linking $@ seems like the way to go. $< only prints the first
dependency, which seems silly for them.

We could also remove the default, and have all callers of quiet pass in
$< or $@ or whatever as part of the first parameter. It's more verbose
everywhere, but I think simpler overall.

BR,
Jani.


More information about the notmuch mailing list