MinGW include error
BlitzMax Forums/BlitzMax Beginners Area/MinGW include error
| ||
Hi, I am on Win 7 Home Premium 64 bit with BLIDE pro. My MinGW is in d:\MinGW with and environmental variable pointing to the bin dir there and GCC_EXEC_PREFIX set also. When I compile a mod that includes string.h or stdio.h (I assume standard header files) I get an error that the files can not be found. Looks like compiler is not looking in the MingW include dir. Same thing happens if I try to use Maxide. Anyone else have this problem - or better tell me how to fix it........... Thanks greatly Matthew |
| ||
In order to get things to work properly on my PC, I had to add two more environment variables:CPLUS_INCLUDE_PATH=C:\MinGW\include;C:\MinGW\lib\gcc\mingw32\4.5.1\include;C:\MinGW\lib\gcc\mingw32\4.5.1\include\c++ C_INCLUDE_PATH=C:\MinGW\include;C:\MinGW\lib\gcc\mingw32\4.5.1\include |
| ||
Before setting any variable or anything, did you tried telling BLIde what was your MinGW location? And also, are you sure you did install all the required packages? You can do this. Download this version of MinGW from the BLIde website: http://www.blide.org/backup/MinGW.rar Unrar it to any folder (c:\MinGW as instance). Launch BLIde and go to Tools / configure MinGW compiler. You can set there the MinGW location. Once this is done, module compilation should work and, if you need a console enviroment, you can also launch a prepared working console from BLIde. |
| ||
I had set the location in Blide but to check, I deleted the MinGW dir, downloaded your .rar file and extracted it to D:\MinGW. I reset this location in Blide and removed the environmental variables in computer setup (except the bin directory is still in the PATH). When I tried to compile a module I get D:/BlitzMax/mod/warner.mod/engine.mod/Terrain/roamstep4d.c:62: string.h: No such file or directory Build Error: failed to compile D:/BlitzMax/mod/warner.mod/engine.mod/Terrain/roamstep4d.c So the header file is not being found and I don't know what to do next?? Matthew Last edited 2011 |
| ||
Do other third-party modules (which require C/C++ compilation) build okay? Maybe it's something specific with Warner's module? |
| ||
Oooh... double post... the site seems to act a bit odd sometimes since its rebuild... Last edited 2011 |
| ||
No. For instance trying to compile bah.libxml results in the following ar: creating D:/BlitzMax/mod/brl.mod/filesystem.mod/filesystem.debug.win32.x86.a ar: creating D:/BlitzMax/mod/brl.mod/filesystem.mod/filesystem.release.win32.x86.a In file included from D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:13: D:\BlitzMax\mod\bah.mod\libxml.mod\src\libxml.h:44: stdio.h: No such file or directory D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:18: stdlib.h: No such file or directory D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:20: string.h: No such file or directory In file included from D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:22: D:\BlitzMax\mod\bah.mod\libxml.mod\src\libxml\tree.h:15: stdio.h: No such file or directory In file included from D:\BlitzMax\mod\bah.mod\libxml.mod\src\libxml\tree.h:17, from D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:22: D:\BlitzMax\mod\bah.mod\libxml.mod\src\libxml\xmlstring.h:14: stdarg.h: No such file or directory In file included from D:\BlitzMax\mod\bah.mod\libxml.mod\src\libxml\tree.h:1248, from D:/BlitzMax/mod/bah.mod/libxml.mod/src/c14n.c:22: Again standard c and c++ headers ignored. I did try setting the variables as metioned above but error given was something to do with cc1.exe. I do have visual studio installed so I don't know if this is affecting things. Thanks Matthew |
| ||
Sounds like a bad install or setup of MinGW... that it can't find any of the headers. I've got it running on Windows 7 64-bit, and I only have to use the standard PATH and MINGW environment variables. I think the second one (MINGW) is the one that will get your includes working properly. It should point to the base MINGW folder... for example : C:\MinGW because then I expect it will look for the include/ folder in there. |