On Fri, 31 Dec 2021 01:52:42 -0800
Arthur Williams <taapart...@disroot.org> wrote:

Dear Arthur,

> I too fell victim to the GNU trap and thought "?=" was standard and
> actually useful.

hehe this thread here feels like a self-help-thread of the newly
POSIX-make-awakened!

> Completely forgot about the -e flag. Now I need to go update all my
> projects and who knows what other GNU-isms I'm unknowingly using.

Just be careful that the standard explicitly states that environment
variables with null values also override macro assignments.
Additionally, you don't want some variables to be silently overridden
(e.g. file lists like SRC or something) by an unknown environment which
might as well just have this defined.
It's better to just explicitly override certain variables and stay
within the "usual" naming schemes (DESTDIR, PREFIX, CFLAGS, etc.).

> > that is exactly what I meant earlier on that the POSIX-intended good
> > practices get destroyed by the retarded GNU extensions.  
> 
> Yeah you make a strong argument. I too think a linting tool would be
> useful. I imagine it would function like shellcheck does for shells.
> If nothing else it would really help people identify GNU extensions vs
> portable behavior.

Exactly!

With best regards

Laslo

Reply via email to