I'm in the process of upgrading a ogre 1.8 project into 2.0 and have upgraded cegui as well.
For that we have a setup script that compiles ogre, cegui as well as a number of other things on windows.
I'm compiling using mingw 4.7.3. I'm using CEGUI from here: https://github.com/OpenTechEngine/CEGUI
I get a number of errors looking like this error:
Code: Select all
In file included from c:\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.3/include/xmmintrin.h:36:0,
from C:/mingw/OgreSDK/include/OGRE/OgreCommon.h:35,
from C:/mingw/OgreSDK/include/OGRE/OgreMath.h:34,
from D:/Users/jacob/Documents/git/ThriveDirectReview2/src/engine/serialization.h:7,
from D:\Users\jacob\Documents\git\ThriveDirectReview2\src\engine\engine.cpp:8:
c:\mingw\bin../lib/gcc/i686-w64-mingw32/4.7.3/include/mmintrin.h:53:1: error: previous declaration of 'void _m_empty()' with 'C++' linkage
In file included from C:/mingw/install/include/glm/core/setup.hpp:549:0,
from C:/mingw/install/include/glm/glm.hpp:89,
from C:/mingw/install/include/cegui-9999/CEGUI/../CEGUI/Size.h:37,
from C:/mingw/install/include/cegui-9999/CEGUI/../CEGUI/Rect.h:33,
from C:/mingw/install/include/cegui-9999/CEGUI/../CEGUI/Image.h:33,
from C:/mingw/install/include/cegui-9999/CEGUI/../CEGUI/BitmapImage.h:30,
from C:/mingw/install/include/cegui-9999/CEGUI/../CEGUI/CEGUI.h:37,
from D:\Users\jacob\Documents\git\ThriveDirectReview2\src\engine\engine.cpp:21:
Looking at /glm/core/setup.hpp:549:0 we have:
Code: Select all
if defined(MINGW32) && (GLM_ARCH != GLM_ARCH_PURE)
include intrin.h
endif
So it seems like ogre 2.0 is using xmmintrin from gcc, and cegui is using intrin.h from GLM and both of these headers define pretty much the same interface.
All of the the relevant source code can be found here: https://github.com/Revolutionary-Games/ ... ee/ogre2.0
The powershell scripts that are responsible for downloading and compiling ogre and cegui themselves can be found here:
https://github.com/Revolutionary-Games/ ... ingw_setup
Note that this is NOT where the compilation fails, the compilation fails when trying to compile the actual game and not ogre/cegui.
An issue with comments explaining the process that have been gone through in attempting to get this working on windows can be found here: https://github.com/Revolutionary-Games/ ... t-97486668
So can anyone help me figure out what's going wrong? Should both intrin and mmintrin be included and if so, what causes the definition collisions?
Hope you can help, thanks!