On Wed, 19 Jul 2000, Tom Tromey wrote:

> Mo> Has anyone come up a reason why setting the ${prefix} and
> Mo> ${exec_prefix} variables at the top of ./configure would be bad?
> 
> You want the directory variable to be defined in terms of each other
> in the Makefile if the user does not override them.  That makes the
> "make prefix=..." trick easier for the end user.
> 
> Tom

Yes, but what I am asking for is to actually set the prefix and
exec_prefix variables after reading the command line options
in ./configure, and then pass them correctly to ./config.status.

I want the following configure.in to print the
values the user passed in.

AC_INIT(foo.c)

AC_PROG_CC

echo "prefix is \"$prefix\""
echo "exec_prefix is \"$exec_prefix\""

AC_OUTPUT([Makefile])

Here is what is currently printed:

% ./configure
...
prefix is "NONE"
exec_prefix is "NONE"
creating ./config.status
creating Makefile

% ./configure --prefix=/tmp
...
prefix is "/tmp"
exec_prefix is "NONE"

This should print:
% ./configure --prefix=/tmp
...
prefix is "/tmp"
exec_prefix is "/tmp"

and then subst @exec_prefix@ with ${prefix}.

Mo DeJong
Red Hat Inc

Reply via email to