Include path confusion

Earl Olsen earl.olsen@dilithiumnetworks.com
Wed Mar 15 15:07:00 GMT 2006


I tried this with 0.42, same result.  So I went back to 0.37
and took a hard look at what people were trying to compile.
I turns out they were going out of their way to include kernel 
headers in user applications, and compiling it with c++ to boot.

So to fix my problem was a combination of fixing those includes
and using LINUX_SANITIZED_HEADER_DIR.

Thanks

-----Original Message-----
From: daniel.r.kegel@gmail.com [mailto:daniel.r.kegel@gmail.com] On
Behalf Of Dan Kegel
Sent: Tuesday, March 14, 2006 3:09 PM
To: Earl Olsen
Cc: crossgcc maillist
Subject: Re: Include path confusion

On 3/14/06, Earl Olsen <earl.olsen@dilithiumnetworks.com> wrote:
> I have built two [gcc-3.2.2] compilers with cross tools, one for Linux

>2.4.21 and  one for Linux 2.6.10.
>...
> When we compile a user module that includes <linux/i2c.h> with the
> 2.4.21 compiler,
> it correctly picks up the header from i386-linux/include/linux  
>directory.
> The 2.6.10 compiler gets it from i386-linux/sys-include/linux 
>directory,  and we get an error:
> 
>/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/sys-include/linux/con
>fig.h:4:28: linux/autoconf.h: No such file or directory

Sounds like in the case with the error, you're not using sanitized
kernel headers.  Try setting

LINUX_SANITIZED_HEADER_DIR=linux-libc-headers-2.6.12.0

in the toolchain .dat file when running crosstool.

Which version of crosstool are you using?

--
For unsubscribe information see http://sourceware.org/lists.html#faq



More information about the crossgcc mailing list