[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Wrong order of preprocessor and compiler flags
From: |
Jan Engelhardt |
Subject: |
Re: Wrong order of preprocessor and compiler flags |
Date: |
Mon, 28 Mar 2022 00:00:19 +0200 (CEST) |
User-agent: |
Alpine 2.25 (LSU 592 2021-09-18) |
On Sunday 2022-03-27 23:22, Karl Berry wrote:
>It seems the basic inconsistency is whether CPPFLAGS is considered a
>"user variable" or not. In earlier eras, it wasn't [...]
In earlier eras of what exactly?
As for make, it never made a distinction between user variables or otherwise,
at least that's the way make comes across. Some software will just
break on `make CFLAGS=-O3` and others will work to compile.
As for automake, AM_CPPFLAGS was introduced at the same time as AM_CFLAGS as
per the git log. So CPPFLAGS always was a user variable.
>[more on CFLAGS<->CPPFLAGS order]
I went to the GNU make git repo to check on CPPFLAGS; it appeared first in
documentation rather than source (which seems like a history import mishap),
but even back then in '94, the documentation was inconsistent, sometimes
providing example descriptions where CPPFLAGS comes after CFLAGS/FFLAGS/etc.,
and sometimes reversed.