gpsd-dev
[Top][All Lists]
Advanced

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

Re: [gpsd-dev] build failure, again, due to endian.h issues


From: Greg Troxel
Subject: Re: [gpsd-dev] build failure, again, due to endian.h issues
Date: Wed, 06 Nov 2013 09:12:42 -0500
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/23.4 (berkeley-unix)

"Eric S. Raymond" <address@hidden> writes:

> Greg Troxel <address@hidden>:
>> @esr: I've said something like this several times, and you haven't
>> addressed it.  Please do.
>
> I have addresed it.  You must have missed that mail.

I think I misinterpreted your objection to host/target as not addressing
it, relative to what you meant :-)

>> Surely scons must be able to do the equivalent of AC_CHECK_HEADER.  It's
>> inconceivable that it's not a built-in feature.  What's going on?
>
> What's going on is that I'm thinking about the cross-compilation case.  I
> don't want to do a configure-like test if I can avoid it, because that
> will test the endiannes of the build *host*, not the build *target*.

I explained this.  autoconf's AC_CHECK_HEADER does check the target.
To do cross compilation, you have to have a DESTDIR/--sysroot with
target headers, and to see if a header is present to you try to compile
a test program with the target compiler.

A facility that explicitly checks for .h files on the host is just plain
broken and should be removed.

> As much as possible I want to do this sort of test inside the cross-compiler,
> so it will happen in the environment of the build *target*.

Of course.  But that can be done as a preparatory step to defining
HAVE_FOO, which is exactly what autoconf does.  And it's far easier
(finding endian.h in the right place) that what's going on with
probably-fragile preprocessor magic.

Attachment: pgpilkTNmZU7r.pgp
Description: PGP signature


reply via email to

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