I am trying to compile a hello world code using MingW tool chain:
#include <stdio.h>
#include <stdlib.h>
int main(void) {
puts("!!!Hello World!!!"); /* prints !!!Hello World!!! */
return EXIT_SUCCESS;
}
but I get this error message:
fatal error: stdio.h: No such file or directory helloC.c /helloC/src line 11
I searched for stdio.h file in my MinGW installation folder (C:\MinGW) and I find two copies in these folders:
C:\MinGW\lib\gcc\mingw32\4.6.1\include\ssp (Related to Stack Smashing Protection)
C:\MinGW\lib\gcc\mingw32\4.6.1\include\c++\tr1
I am using Eclipse CDT and non of these folders are in default include directories for Eclipse. I am using a 64 bit system, Windows 7.
My assumption is I need to have a third copy of stdio.h in this folder:
C:\MinGW\lib\gcc\mingw32\4.6.1\include
Am I missing a MinGW package needed to be installed for standard C library or do I need to add either ssp or tr1 folder to include search path?