Results 1 to 1 of 1
Enjoy an ad free experience by logging in. Not a member yet? Register.
- Join Date
- Jun 2009
GCC can't find standard headers even though they are present
I am trying to build an application (AVRDude 5.6) in Cygwin. I have downloaded a minimal number of packages and have sucessfully run the configure script but on building I encounter some errors:
make all-recursive make: Entering directory `/cygdrive/c/avrdude' Making all in windows make: Entering directory `/cygdrive/c/avrdude/windows' if gcc -DHAVE_CONFIG_H -I. -I. -I.. -g -O2 -mno-cygwin -DWIN32NATIVE -MT loa ddrv.o -MD -MP -MF ".deps/loaddrv.Tpo" -c -o loaddrv.o loaddrv.c; \ then mv -f ".deps/loaddrv.Tpo" ".deps/loaddrv.Po"; else rm -f ".deps/loa ddrv.Tpo"; exit 1; fi In file included from /usr/lib/gcc/../../include/w32api/windef.h:253, from /usr/lib/gcc/../../include/w32api/windows.h:48, from loaddrv.c:9: /usr/lib/gcc/../../include/w32api/winnt.h:37:20: string.h: No such file or direc tory In file included from /usr/lib/gcc/../../include/w32api/ole2.h:9, from /usr/lib/gcc/../../include/w32api/windows.h:114, from loaddrv.c:9: /usr/lib/gcc/../../include/w32api/objbase.h:12:20: stdlib.h: No such file or dir ectory loaddrv.c:10:19: stdio.h: No such file or directory loaddrv.c:13:20: unistd.h: No such file or directory
I've searched around and in all cases it seems to be that the standard header files are missing - but they aren't - im looking at stdlib.h right now in my /usr/include folder!
I've added the folder to the PATH environment variable but it doesnt help.
I tried to link the string.h file from usr/include to the gcc include folder, and re-run make, which resulted in this:
/usr/lib/gcc/i686-pc-cygwin/3.4.4/include/string.h:22: error: parse error before "_PTR" /usr/lib/gcc/i686-pc-cygwin/3.4.4/include/string.h:22: error: parse error before '(' token /usr/lib/gcc/i686-pc-cygwin/3.4.4/include/string.h:23: error: parse error before '(' token
So now I am very confused...
One thing though, when I linked string.h after I recieved an error sys/string.h not found, of course in /usr/include there is a sys folder containing string.h so I am thinking that gcc is completely ignoring my /usr/include but I have no idea why?
BTW, in the cmd output it shows all the files it can find as being in /usr/lib/gcc...../]file.ext], however, gcc is installed in [cygwin root]/lib/gcc/.....
Where has the initial /usr/ directory come from?