I'm trying to build a library named Ogre3d v1.8 using gcc 4.7 on MacOSX 10.6. I have tried to install the gcc version from both MacPorts and from gFortran webpage. Both have the same issue and I can't find much information about this on the internet.
My problem is that I get this error:
Scanning dependencies of target OgreMain
[ 0%] Building CXX object OgreMain/CMakeFiles/OgreMain.dir/src/OgreAlignedAllocator.cpp.o
In file included from /usr/local/gcc-4-7-svn/lib/gcc/x86_64-apple-darwin10/4.7.0/include/c++/bits/postypes.h:42:0,
from /usr/local/gcc-4-7-svn/lib/gcc/x86_64-apple-darwin10/4.7.0/include/c++/bits/char_traits.h:42,
from /usr/local/gcc-4-7-svn/lib/gcc/x86_64-apple-darwin10/4.7.0/include/c++/string:42,
from /Users/parwrange/Desktop/ogre/ogre_src_v1-8-1/OgreMain/include/OgrePrerequisites.h:33,
from /Users/parwrange/Desktop/ogre/ogre_src_v1-8-1/OgreMain/include/OgreArchive.h:31,
from /Users/parwrange/Desktop/ogre/ogre_src_v1-8-1/OgreMain/include/OgreStableHeaders.h:41,
from /Users/parwrange/Desktop/ogre/ogre_src_v1-8-1/OgreMain/src/OgreAlignedAllocator.cpp:28:
/usr/local/gcc-4-7-svn/lib/gcc/x86_64-apple-darwin10/4.7.0/include/c++/cwchar:46:19: fatal error: wchar.h: No such file or directory
compilation terminated.
make[2]: *** [OgreMain/CMakeFiles/OgreMain.dir/src/OgreAlignedAllocator.cpp.o] Error 1
make[1]: *** [OgreMain/CMakeFiles/OgreMain.dir/all] Error 2
make: *** [all] Error 2
In other words it looks like the header file wchar.h is missing.
I have been able to build other libraries with the gcc 4.7 installation. So I'm guessing that it is something specific with Ogre3d v1.8. Maybe something to do with inclusion order. But since I'm having problem finding other people with this issue I'm hoping that someone here have some good tips on what to do.