mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Mingw-cross-env-list] Specifying --build (was: make curl fails)


From: Tony Theodore
Subject: Re: [Mingw-cross-env-list] Specifying --build (was: make curl fails)
Date: Tue, 29 Nov 2011 04:14:13 +1100

On 29 November 2011 03:06, Volker Grabsch <address@hidden> wrote:
> Tony Theodore schrieb:
[...]
>> Okay, so creating a config.site in binutils.mk like this:
>>
>>     # install site-wide autotools config files
>>     $(INSTALL) -d '$(PREFIX)/share'
>>     echo ac_cv_build=`'$(1)/config.sub' $$($(1)/config.guess)` > 
>> '$(PREFIX)/share/config.site'
>>     $(INSTALL) -d '$(PREFIX)/$(TARGET)/share'
>>     cp '$(PREFIX)/share/config.site' '$(PREFIX)/$(TARGET)/share/config.site'
>
> Since config.sub is supposed to return its argument unmodified
> (on success), we can simplify the second line to:
>
>     echo "ac_cv_build=`$(1)/config.guess`" > '$(PREFIX)/share/config.site'

Nice, I didn't know that - it seemed strange that the output would
have to be immediately validated, but I picked that up from reading a
./configure script.

> Also, do we really have to install the "config.site" file
> into two locations? I'd prefer to install it only once,
> into '$(PREFIX)/$(TARGET)/share/config.site'.
>
> (I prefer $(PREFIX)/$(TARGET) over $(PREFIX) because we
>  might want to add TARGET-specific stuff here in the future.)

It's not currently necessary to have $(PREFIX), that is only used for
native builds, but I put it in since you mentioned it might be "good
style". ./configure will use the value passed to it with "--prefix" to
determine which config.site to use.

>> The above doesn't require config.sub to be installed, so we could
>> remove that step.
>
> I'd prefer it if we could install a system-wide config.sub
> and "trick" the ./configure script into using that instead
> of its local ./config.sub.
>
> If we can't trick ./configure into using it, there's indeed
> no need to install config.sub at all, as there's no need to
> call it at all. :-)  (see above)

I couldn't find a way to do this, you can set "ac_aux_dir", but that
has other files in it also (ltmain.sh, *.m4 etc.).

>> I can't test if this technique also solves the wine detection problem,
>> though I suspect it may, possibly with the addition of "build=" to the
>> config.site file. If it does, we wouldn't need to install config.guess
>> either.
>
> Indeed. That could be a good alternative, although
> replacing "config.sub" with "echo" might do the
> trick as well. ;-)

True! The only other place it's used is to validate host/target and we
know they're always going to be well-formed.

Cheers,

Tony



reply via email to

[Prev in Thread] Current Thread [Next in Thread]