This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Include path confusion


Hi,

I have built two compilers with cross tools, one for Linux 2.4.21 and
one for Linux 2.6.10.
Here are the gcc -v commands from them:

$ /data/dntools/gnu-i386-linux-2.4.21-v2/bin/i386-linux-g++ -v
Reading specs from
/data/dntools/gnu-i386-linux-2.4.21-v2/lib/gcc-lib/i386-linux/3.2.2/spec
s
Configured with:
/data/dntools/toolmaker/crosstool-0.37/build/i386-linux/gcc-3.2.2-glibc-
2.3.2/gcc-3.2.2/configure --target=i386-linux
--host=i686-host_pc-linux-gnu
--prefix=/data/dntools/gnu-i386-linux-2.4.21-v2
--with-headers=/data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux/include
--with-local-prefix=/data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux
--disable-nls --enable-threads=posix --enable-symvers=gnu
--enable-__cxa_atexit --enable-languages=c,c++ --enable-shared
--enable-c99 --enable-long-long
Thread model: posix
gcc version 3.2.2
$ /data/dntools/gnu-i386-linux-2.6.10-v2/bin/i386-linux-g++ -v
Reading specs from
/data/dntools/gnu-i386-linux-2.6.10-v2/lib/gcc-lib/i386-linux/3.2.2/spec
s
Configured with:
/data/dntools/toolmaker/crosstool-0.37/build/i386-linux/gcc-3.2.2-glibc-
2.3.2/gcc-3.2.2/configure --target=i386-linux
--host=i686-host_pc-linux-gnu
--prefix=/data/dntools/gnu-i386-linux-2.6.10-v2
--with-headers=/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/include
--with-local-prefix=/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux
--disable-nls --enable-threads=posix --enable-symvers=gnu
--enable-__cxa_atexit --enable-languages=c,c++ --enable-shared
--enable-c99 --enable-long-long
Thread model: posix
gcc version 3.2.2

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:

The 2.4.21 compiler:

Reading specs from
/data/dntools/gnu-i386-linux-2.4.21-v2/lib/gcc-lib/i386-linux/3.2.2/spec
s
Configured with:
/data/dntools/toolmaker/crosstool-0.37/build/i386-linux/gcc-3.2.2-glibc-
2.3.2/gcc-3.2.2/configure --target=i386-linux
--host=i686-host_pc-linux-gnu
--prefix=/data/dntools/gnu-i386-linux-2.4.21-v2
--with-headers=/data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux/include
--with-local-prefix=/data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux
--disable-nls --enable-threads=posix --enable-symvers=gnu
--enable-__cxa_atexit --enable-languages=c,c++ --enable-shared
--enable-c99 --enable-long-long
Thread model: posix
gcc version 3.2.2
 
/data/dntools/gnu-i386-linux-2.4.21-v2/lib/gcc-lib/i386-linux/3.2.2/cc1p
lus -v -I/home/siribarne/siribarne_DTG-2.1_int//dtg/common/include
-I/home/siribarne/siribarne_DTG-2.1_int//dtg/apps/HWMgr/include
-I/home/siribarne/siribarne_DTG-2.1_int//dtg/common/include
-I/home/siribarne/siribarne_DTG-2.1_int//pts/Linux/C6410HostLibs/include
-D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=2
-D__GXX_ABI_VERSION=102 -D__ELF__ -Dunix -D__gnu_linux__ -Dlinux
-D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__ -D__unix -D__linux
-Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -D_GNU_SOURCE
-Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i686__
-D__tune_pentiumpro__ -D__DTG2000__ -DLINUX x.cpp -D__GNUG__=3
-D__DEPRECATED -D__EXCEPTIONS -quiet -dumpbase x.cpp -march=i386
-mcpu=i686 -gdwarf-2 -Wall -Wall -version -o /tmp/ccSJUzJO.s
GNU CPP version 3.2.2 (cpplib) (i386 Linux/ELF)
GNU C++ version 3.2.2 (i386-linux)
	compiled by GNU C version 3.2.3 20030502 (Red Hat Linux
3.2.3-52).
ignoring duplicate directory
"/home/siribarne/siribarne_DTG-2.1_int/dtg/common/include"
#include "..." search starts here:
#include <...> search starts here:
 /home/siribarne/siribarne_DTG-2.1_int/dtg/common/include
 /home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include
 /home/siribarne/siribarne_DTG-2.1_int/pts/Linux/C6410HostLibs/include
 /data/dntools/gnu-i386-linux-2.4.21-v2/include/c++/3.2.2
 /data/dntools/gnu-i386-linux-2.4.21-v2/include/c++/3.2.2/i386-linux
 /data/dntools/gnu-i386-linux-2.4.21-v2/include/c++/3.2.2/backward
 /data/dntools/gnu-i386-linux-2.4.21-v2/include
 
/data/dntools/gnu-i386-linux-2.4.21-v2/lib/gcc-lib/i386-linux/3.2.2/incl
ude
 /data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux/sys-include
 /data/dntools/gnu-i386-linux-2.4.21-v2/i386-linux/include
End of search list.
 
/data/dntools/gnu-i386-linux-2.4.21-v2/lib/gcc-lib/i386-linux/3.2.2/../.
./../../i386-linux/bin/as -V -Qy -o x.o /tmp/ccSJUzJO.s
GNU assembler version 2.14 (i386-linux) using BFD version 2.14 20030612

The 2.6.10 compiler:

Reading specs from
/data/dntools/gnu-i386-linux-2.6.10-v2/lib/gcc-lib/i386-linux/3.2.2/spec
s
Configured with:
/data/dntools/toolmaker/crosstool-0.37/build/i386-linux/gcc-3.2.2-glibc-
2.3.2/gcc-3.2.2/configure --target=i386-linux
--host=i686-host_pc-linux-gnu
--prefix=/data/dntools/gnu-i386-linux-2.6.10-v2
--with-headers=/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/include
--with-local-prefix=/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux
--disable-nls --enable-threads=posix --enable-symvers=gnu
--enable-__cxa_atexit --enable-languages=c,c++ --enable-shared
--enable-c99 --enable-long-long
Thread model: posix
gcc version 3.2.2
 
/data/dntools/gnu-i386-linux-2.6.10-v2/lib/gcc-lib/i386-linux/3.2.2/cc1p
lus -v -I/home/siribarne/siribarne_DTG-2.1_int//dtg/common/include
-I/home/siribarne/siribarne_DTG-2.1_int//dtg/apps/HWMgr/include
-I/home/siribarne/siribarne_DTG-2.1_int//dtg/common/include
-I/home/siribarne/siribarne_DTG-2.1_int//pts/Linux/C6410HostLibs/include
-D__GNUC__=3 -D__GNUC_MINOR__=2 -D__GNUC_PATCHLEVEL__=2
-D__GXX_ABI_VERSION=102 -D__ELF__ -Dunix -D__gnu_linux__ -Dlinux
-D__ELF__ -D__unix__ -D__gnu_linux__ -D__linux__ -D__unix -D__linux
-Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1 -D_GNU_SOURCE
-Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i686__
-D__tune_pentiumpro__ -D__DTG2000__ -DLINUX x.cpp -D__GNUG__=3
-D__DEPRECATED -D__EXCEPTIONS -quiet -dumpbase x.cpp -march=i386
-mcpu=i686 -gdwarf-2 -Wall -Wall -version -o /tmp/ccMUPYIz.s
GNU CPP version 3.2.2 (cpplib) (i386 Linux/ELF)
GNU C++ version 3.2.2 (i386-linux)
	compiled by GNU C version 3.2.3 20030502 (Red Hat Linux
3.2.3-52).
ignoring duplicate directory
"/home/siribarne/siribarne_DTG-2.1_int/dtg/common/include"
#include "..." search starts here:
#include <...> search starts here:
 /home/siribarne/siribarne_DTG-2.1_int/dtg/common/include
 /home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include
 /home/siribarne/siribarne_DTG-2.1_int/pts/Linux/C6410HostLibs/include
 /data/dntools/gnu-i386-linux-2.6.10-v2/include/c++/3.2.2
 /data/dntools/gnu-i386-linux-2.6.10-v2/include/c++/3.2.2/i386-linux
 /data/dntools/gnu-i386-linux-2.6.10-v2/include/c++/3.2.2/backward
 /data/dntools/gnu-i386-linux-2.6.10-v2/include
 
/data/dntools/gnu-i386-linux-2.6.10-v2/lib/gcc-lib/i386-linux/3.2.2/incl
ude
 /data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/sys-include
 /data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/include
End of search list.
In file included from
/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/sys-include/linux/modu
le.h:9,
                 from
/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/sys-include/linux/i2c.
h:31,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_SMBu
s.h:36,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_GNPC
hassis.h:31,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_Syst
emStats.h:29,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_Host
Card_C5370.h:31,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_Eqpt
HldrTask.h:38,
                 from
/home/siribarne/siribarne_DTG-2.1_int/dtg/apps/HWMgr/include/DN_HWM_Appl
ication.h:45,
                 from x.cpp:2:
/data/dntools/gnu-i386-linux-2.6.10-v2/i386-linux/sys-include/linux/conf
ig.h:4:28: linux/autoconf.h: No such file or directory


Any clues what is wrong?

Thanks


--
Earl Olsen
Senior Software Engineer
Dilithium Networks, Inc.
TEL:+1 707-792-3925
earl.olsen@dilithiumnetworks.com
www.dilithiumnetworks.com

Communications for a Borderless World

This electronic message from Dilithium Networks contains information
which may be privileged or confidential. It is intended to be for the
use of the recipient(s) named above. If you are not the intended
recipient please return the message to the sender by replying to it and
then delete the message from your computer. Dilithium Networks shall not
be held liable to any person resulting from the use of any information
contained in this e-mail and shall not be liable to any person who acts
or omits to do anything in reliance upon it. Dilithium Networks does not
accept responsibility for changes made to this message after it was
sent.

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]