* xgcc and -isystem switch behavior
@ 2002-03-11 14:56 Matthieu Klein
0 siblings, 0 replies; only message in thread
From: Matthieu Klein @ 2002-03-11 14:56 UTC (permalink / raw)
To: gcc-help
Hi there,
target = arm-elf
host = solaris 2.6
Tools to be compiled = Gcc 3.04 (1st in native then the cross comp) + newlib 1.10 (like glibc) + binutils 2.11
Prefix = same for all the products
During the compilation of the cross compiler, we got : (I removed the -I -B -L arguments so its clear)
---> /home/mklein/gcc-3.0.4_build/gcc/xgcc [..vatious switch and dir.....] -isystem /home/mklein/gcc/arm-elf/include
../gcc-3.0.4_src/libstdc++-v3/libsupc++/eh_alloc.cc -o eh_alloc.o
Which gives an error
---> In file included from /home/mklein/gcc-3.0.4_build/arm-elf/libstdc++-v3/include/cstdlib:31,
---> from ../../../../gcc-3.0.4_src/libstdc++-v3/libsupc++/eh_alloc.cc:34:
--->/home/mklein/gcc-3.0.4_build/arm-elf/libstdc++-v3/include/bits/std_cstdlib.h:75: `div_t'
---> not declared
---> [ ....]
It happens obviously because the compiler doesn't use the good sdtlib.h
It uses the stdlib.h of gcc-3.0.4_build/gcc/include instead of using the one specified by the -isystem switch (this
switch was specified by the makefile of gcc)
Ok, it's easy to fix, I just rename
gcc-3.0.4_build/gcc/include/stdlib.h to
gcc-3.0.4_build/gcc/include/_stdlib.h so/home/mklein/gcc/arm-elf/include/ sdtlib.h is used instead.
Question is:
- Any idea how to fix that correctly so its done automatically by the main
makefiles ? (instead of stopping the makefile, hacking and changing the stdlib.h etc .. )
- Is that a bug or did I miss something ? Or maybe it's normal, I just fix it like I did and I
don't worry ?
Thanks for your opinion,
Best Regards.
--
Matthieu Klein
gnu@m-klein.com
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2002-03-11 22:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-03-11 14:56 xgcc and -isystem switch behavior Matthieu Klein
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).