Re: AX_PROG_CC_FOR_BUILD should use CFLAGS, etc. in non-crossbuilds

Ryan Lortie <[email protected]>
Newsgroups gmane.comp.sysutils.autoconf.archive-maintainers
Message-ID <[email protected]>
hi,

On Sat, Jan 11, 2014, at 10:48, Paolo Bonzini wrote:
> I think the second approach is wrong.  The $cross_compiling test is
> necessary.

I agree.  After patching this manually into the configure.ac of a couple
of affected projects I see that the cross-compile check is really the
only way.

>  But you can do: initialise the variables from their host
> counterparts in the non-cross-compiling case, but not in the case that
> they are already explicitly set.
> 
> What do you think?

I think that this would be OK except that I don't understand why anyone
would possibly want to change the CFLAGS_FOR_BUILD and not the CFLAGS in
the case that they are not cross-compiling.  That seems a bit strange to
me.

I guess I could imagine a case where they care that the produced
(installed) executables are made with a particular level of optimisation
or debugging and that the tools that are only used during buildtime are
made with different levels...

Cheers
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.