Ogre 1.11 fails to build on MinGW/Clang

Problems building or running the engine, queries about how to use features etc.
Post Reply
libolt
Halfling
Posts: 64
Joined: Wed Jan 19, 2005 4:48 am
x 1

Ogre 1.11 fails to build on MinGW/Clang

Post by libolt » Mon Feb 18, 2019 8:03 pm

Ogre Version: 1.11.5 :?:
Operating System: Windows 10 :?:
Render System: :?:

I'm attempting to build Ogre using Mingw-w64/Clang 7.0.1 and it gets pretty far before failing here. Using Ninja as the build program in place of mingw32-make.

Code: Select all

C:\Users\libolt\builds\build-mingw-clang-amd64\ogre-1.11-build>ninja -j1
[1/170] Linking CXX shared library bin\Codec_EXR.dll
FAILED: bin/Codec_EXR.dll lib/libCodec_EXR.dll.a
cmd.exe /C "cd . && C:\msys64\mingw64\bin\clang++.exe  -msse -fno-tree-slp-vectorize -Wno-error=cast-qual -Wno-unused-local-typedefs -O3 -DNDEBUG   -shared -o bin\Codec_EXR.dll -Wl,--out-implib,lib\libCodec_EXR.dll.a -Wl,--major-image-version,1,--minor-image-version,11 PlugIns/EXRCodec/CMakeFiles/Codec_EXR.dir/src/O_IStream.cpp.obj PlugIns/EXRCodec/CMakeFiles/Codec_EXR.dir/src/OgreEXRCodec.cpp.obj  lib/libOgreMain.dll.a C:/msys64/mingw64/lib/libIlmImf.dll.a C:/msys64/mingw64/lib/libIlmThread.dll.a C:/msys64/mingw64/lib/libHalf.dll.a C:/msys64/mingw64/lib/libIex.dll.a -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32 && cd ."
C:\msys64\mingw64\bin\ld: PlugIns/EXRCodec/CMakeFiles/Codec_EXR.dir/src/O_IStream.cpp.obj:(.rdata$_ZTIN7Iex_2_38InputExcE[_ZTIN7Iex_2_38InputExcE]+0x10): undefined reference to `typeinfo for Iex_2_3::BaseExc'
C:\msys64\mingw64\bin\ld: PlugIns/EXRCodec/CMakeFiles/Codec_EXR.dir/src/O_IStream.cpp.obj:(.rdata$_ZTIN4Ogre9O_IStreamE[_ZTIN4Ogre9O_IStreamE]+0x10): undefined reference to `typeinfo for Imf_2_3::IStream'
clang++.exe: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
0 x

paroj
OGRE Team Member
OGRE Team Member
Posts: 837
Joined: Sun Mar 30, 2014 2:51 pm
x 150
Contact:

Re: Ogre 1.11 fails to build on MinGW/Clang

Post by paroj » Tue Feb 19, 2019 12:58 am

try disabling the EXR codec. it is only rarely useful anyway.
0 x

libolt
Halfling
Posts: 64
Joined: Wed Jan 19, 2005 4:48 am
x 1

Re: Ogre 1.11 fails to build on MinGW/Clang

Post by libolt » Tue Feb 19, 2019 3:17 am

paroj,

Thanks but now it fails linking OgreTerrain.dll

Code: Select all

λ ninja -j1
[1/161] Linking CXX shared library bin\OgreTerrain.dll
FAILED: bin/OgreTerrain.dll lib/libOgreTerrain.dll.a
cmd.exe /C "cd . && C:\msys64\mingw64\bin\clang++.exe  -msse -fno-tree-slp-vectorize -Wno-error=cast-qual -Wno-unused-local-typedefs -O3 -DNDEBUG   -shared -o bin\OgreTerrain.dll -Wl,--out-implib,lib\libOgreTerrain.dll.a -Wl,--major-image-version,1,--minor-image-version,11 Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrain.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainAutoUpdateLod.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainGroup.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainLayerBlendMap.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainLodManager.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialGenerator.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialGeneratorA.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialShaderHelperCg.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialShaderHelperGLSL.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainQuadTreeNode.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainPaging.cpp.obj Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainPagedWorldSection.cpp.obj  lib/libOgrePaging.dll.a lib/libOgreMain.dll.a -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32 && cd ."
C:\msys64\mingw64\bin\ld: Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainPagedWorldSection.cpp.obj:(.rdata$_ZTIN4Ogre24TerrainPagedWorldSectionE[_ZTIN4Ogre24TerrainPagedWorldSectionE]+0x18): undefined reference to `typeinfo for Ogre::PagedWorldSection'
clang++.exe: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
0 x

Post Reply