|
From: Keith M. <kei...@to...> - 2007-04-27 11:14:24
|
Jesper Quorning wrote: > The well known Hello-World program will not link when I set > include path. What do I do wrong ? ... > $ mingw32-gcc hello.c > $ mingw32-gcc hello.c -I/usr/include > /tmp/cco6QboP.o:hello.c:(.text+0x33): undefined reference to `_stderr' > collect2: ld returned 1 exit status A standard MinGW installation has its headers in /mingw/include. I'm guessing you've got a foreign stdio.h in /usr/include, and by overriding the default header, (your -I... path is searched first, so the search stops at the incompatible stdio.h there), you've generated a bad reference -- in this case it's an improper declaration for the `FILE stderr' reference. Regards, Keith. |