Re: [dev] Special target ".POSIX" in Makefiles

From: <craekz7_AT_gmail.com>
Date: Thu, 30 Dec 2021 17:49:23 +0100

>I agree that it shall be added to all Makefile, because
>otherwise the behavior of make is unspecified.
>(Quote from the POSIX specifications)
I'm sure you meant it like that, but just to clarify it:
It is only unspecified if it doesn't appear as the first non-comment line,
has prerequisites or commands.

>.POSIX can be used as long a the makefile does not
>use any feature that conflicts with POSIX. But I think
>it would mislead people into thinking the non-POSIX
>features are POSIX feature, so it would be best skip
>it in that case.
I agree with that.

As far as I can see, we could add `.POSIX` to the following programs:
dwm, dmenu, dwmstatus, sent and tabbed
I've just looked over the Makefiles very briefly, so I may have overseen something.
Note: I just picked out the "biggest" programs.

>I do however think some Makefile here that use the _AT_
>macro in the prerequisite. This is not a POSIX feature,
>is seldom needed, and should be removed assuming it
>is redundant given the inferred prerequisite of
>inference rules.
sbase does it but I haven't looked closer.

--
craekz
Received on Thu Dec 30 2021 - 17:49:23 CET

This archive was generated by hypermail 2.3.0 : Thu Dec 30 2021 - 18:00:08 CET