On Mon, 26 Aug 2019, Sébastien Hinderer wrote:
For instance, regarding variables such as CC or CFLAGS, when they are
passed to configure, should they be recorded somewhere so that a future
invocation of make takes them into account?
Yes, they should normally be recorded in the Makefile so that they are used
in the build.
Okay. Still, I guess if make is invoked with a different value of CC it
is then expected that this new value takes precedence over then one
stored in the Makefile, right?
I would expect that to be true, but I would also expect that the new
CC or CFLAGS might not be compatible with what configure figured out
using the original settings.
Similarly, I kind of remember that if, say, make install is invoked with
a different value of PREFIX that value must be taken into acocunt and
that it is required that PREFIX can have different values during make
and make isntall. I am wondering whether there is a document which
specifies clearly for which variable this is expected to work that way
and couldn't find anything relevant on the web site of the FSF.
You are likely thinking of 'DESTDIR', which is different than prefix.
DESTDIR comes from the build environment and not from the Makefile or
configure script.
Otherwise you need to make sure that the necessary
artifacts are in Makefile.in.
I don't mind taking care of this, I am just unsure at the moment about
what exactly is expected.
If you are preparing your own Makefile, then following the GNU coding
standards as well as the standard definitions documented in the GNU
make manual will help quite a lot. The standard INSTALL text file
documents many of these conventions.
You will find available substitutions stored in the generated
config.status script.
Bob
--
Bob Friesenhahn
bfrie...@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
Public Key, http://www.simplesystems.org/users/bfriesen/public-key.txt
_______________________________________________
Autoconf mailing list
Autoconf@gnu.org
https://lists.gnu.org/mailman/listinfo/autoconf