On Mon, Oct 22 2018, Marc Espie <espie@nerim.net> wrote:
> On Mon, Oct 22, 2018 at 09:26:21AM +0200, Jeremie Courreges-Anglas wrote:
>> Some people prefer no space before '=' and afaik no consensus has been
>> reached. The formatting in this port is consistent, so please avoid
>> needless churn unless you really can't stand the current Makefile. ;)
>
> There are some technical reasons to put a space before the =, because
> it DOES let things be unambiguous for make.
>
> Specifically, we have "augmented operators" := += ?= != and combinations
> thereof.
>
> Especially for variables built on the fly, e.g., PKGNAME${S}, having the
> space prevents errors.
>
> (say, if S=-c++, PKGNAME${S}=somevalue will NOT do what you expect)
>
> So this is something that's 100% needed for tricky infrastructure and ports
> and I really really prefer things to be consistent throughout the tree,
> especially since I have to put the space in everything I do.
Makes sense.
Still, I don't like people completely changing the whitespace in
a Makefile while also introducing semantic changes in the same commit.
It makes diffs and cvs history hard to review, which is BAD. :)
--
jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE
No comments:
Post a Comment