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] |
On 12/6/05, Robert P. J. Day <rpjday@mindspring.com> wrote: > oh, man. i just figured out why i couldn't cross-compile a source > file with my newly-generated toolchain. from the source tree i > inherited, i had a source file that included > > #include <errno.h> > > ok, that looks reasonable enough. but i hadn't noticed that the > actual compile command included the option "-I./include", where that > local include directory included (you guessed it) a file called > "errno.h" Gaaah! I've also been bitten in the past by creating a directory named 'new'. That caused #include <new> to fail in C++ programs. Two tricks can help figure these things out: 1. use the -H option to gcc. This prints out the exact header files used! 2. run the compiler under strace -f -olog, then grep through 'log' for stat and open calls. Works when trick #1 doesn't, e.g. when figuring out linker problems. - Dan -- Why won't Johnny run Linux? See http://kegel.com/linux/comfort ------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |