Akim Demaille wrote:
> 
> | > bug in `configure.in'.  Must we be bugward compatible?
> | bugward :)
> |
> | I think so, cf. below.
> 

> | > If so, we can
> | > set host to host_alias at the end of the handling of the options,
> | No, host and host_alias can differ, and configure script could
> | exploit this for whatever reason.
> 
> That's right, they are different, and I am not trying to erase the
> differences, on contrary: I want to keep them separate.  Let me
> rephrase my patch:

This would be OK, but my understanding of your sentence "set host to
host_alias at the end of the handling of the options" indicates the
opposite.

> 
>         In Autoconf 2.13 `$host' before AC_CANONICAL is what the user
>         gave for --host, that is `$host_alias' after AC_CANONICAL, and
>         `$host' becomes the normalized stuff after AC_CANON.
> 
>         My proposal says that `$host_alias' is what the user gave to
>         --host, before and after AC_CANON, and `$host' is the
>         *canonicalization* of `$host_alias' *after* AC_CANON was run,
>         as the name says.
> 
> As for the ``configure script could exploit this for whatever
> reason.'', I absolutely agree, but my claim is when `$host_alias' is
> wanted (i.e., *not* $host), then we really want what the *user* said,
> i.e., IMHO, it is right that host_alias='' when the user didn't
> --host.  Otherwise you meant something else.
> 
Let me try to clarify:

What I was actually talking about are configure script containing
things like this:

AC_CANONICAL_HOST
case $host_alias in
sh-rtems*) ...
i386-rtems*) ...
i386-linux*) ...
...

rsp.

AC_CANONICAL_HOST
case $host in
sh-*-rtems*) ...
i386-*-rtems*) ...
i386-*-linux*) ...
...

If you'd "set host to host_alias at the end of the handling of the
options", then host would change its contents in comparision to the
state we had with autoconf-2.13. Therefore I'd assume constructs
like the ones above would probably break.


> 
> | Another difference has been that host, build and target were present
> | all autoconf configure scripts by default, even if AC_CANONICAL_*
> | etc. had not been used in a configure.in. Therefore I assume, there
> | might exist configure scripts which rely on the values of host,
> | build, target without using AC_CANONICAL_*, esp. in packages not
> | using automake/config.guess/config.sub.
> 
> I can't find an example of this.
Neither did I :)

> I've looked in several packages
> though.  But really, it doesn't make sense to me to use $host
> etc. with AC_CANON.
[Typo? Did you mean "without AC_CANON"?]

Using $host with AC_CANONICAL_HOST is a fairly popular construct
(Cf. libiberty/configure.in, glibc2/configure.in).


Ralf.

-- 
Ralf Corsepius 
Forschungsinstitut fuer Anwendungsorientierte Wissensverarbeitung
(FAW)
Helmholtzstr. 16, 89081 Ulm, Germany     Tel: +49/731/501-8690
mailto:[EMAIL PROTECTED]           FAX: +49/731/501-999  
http://www.faw.uni-ulm.de

Reply via email to