Hi again,
I've tried compiling with mingw64 in both
windows and
linux (sudo apt-get install mingw-w64) using the downloaded SDL2 and GLFW... github master and 2.0.1
and they all compile horde3d libs but fails in the same place:
c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw
32/bin/ld.exe: ../../../Horde3D/Samples/Framework/libSampleFramework.a(GLFWFrame
work.cpp.obj):GLFWFramework.cpp:(.text+0xac2):
undefined reference to `__imp_h3d
utLoadResourcesFromDisk'I'm cmake noob, but it looks like should just work, the horde3dutils main.cpp compiles fine.
Looks like it should find the function
Horde3D-2.0.1/bin/Extensions/Terrain/Sample/CMakeFiles/Terrain.dir/linklibs.rsp:
../../../Horde3D/Source/Horde3DUtils/libHorde3DUtils.dll.a ../../../Horde3D/Samples/Framework/libSampleFramework.a -lmingw32 "../../../project_glfw-prefix/lib/libglfw3.a" ../../../Horde3D/Source/Horde3DEngine/libHorde3D.dll.a -lopengl32 ../../Overlays/Source/libHorde3DOverlays.a ../Source/libHorde3DTerrain.a -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32
Anyone else use mingw? or any tips as to where to look?
Code:
C:\Horde3D-2.0.1\bin>cmake -G "Unix Makefiles" ..
-- The C compiler identification is GNU 10.2.0
-- The CXX compiler identification is GNU 10.2.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/mingw64/bin/gcc.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/mingw64/bin/c++.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for strncpy_s
-- Looking for strncpy_s - found
-- Preparing external GLFW project
-- External GLFW project done
-- Found GLFW: TRUE
-- Found OpenGL: opengl32
-- Configuring done
-- Generating done
-- Build files have been written to: C:/Horde3D-2.0.1/bin
C:\Horde3D-2.0.1\bin>make
C:\Horde3D-2.0.1\bin>make
[ 1%] Creating directories for 'project_glfw'
[ 2%] Performing download step (download, verify and extract) for 'project_glfw
'
-- project_glfw download command succeeded. See also C:/Horde3D-2.0.1/bin/proje
ct_glfw-prefix/src/project_glfw-stamp/project_glfw-download-*.log
[ 4%] No update step for 'project_glfw'
[ 5%] No patch step for 'project_glfw'
[ 7%] Performing configure step for 'project_glfw'
-- project_glfw configure command succeeded. See also C:/Horde3D-2.0.1/bin/proj
ect_glfw-prefix/src/project_glfw-stamp/project_glfw-configure-*.log
[ 8%] Performing build step for 'project_glfw'
-- project_glfw build command succeeded. See also C:/Horde3D-2.0.1/bin/project_
glfw-prefix/src/project_glfw-stamp/project_glfw-build-*.log
[ 10%] Performing install step for 'project_glfw'
-- project_glfw install command succeeded. See also C:/Horde3D-2.0.1/bin/projec
t_glfw-prefix/src/project_glfw-stamp/project_glfw-install-*.log
[ 11%] Completed 'project_glfw'
[ 11%] Built target project_glfw
[ 13%] Building CXX object Extensions/Overlays/Source/CMakeFiles/Horde3DOverlays
.dir/extension.cpp.obj
[ 14%] Building CXX object Extensions/Overlays/Source/CMakeFiles/Horde3DOverlays
.dir/overlays.cpp.obj
[ 15%] Linking CXX static library libHorde3DOverlays.a
[ 15%] Built target Horde3DOverlays
[ 17%] Building CXX object Extensions/Terrain/Source/CMakeFiles/Horde3DTerrain.d
ir/extension.cpp.obj
[ 18%] Building CXX object Extensions/Terrain/Source/CMakeFiles/Horde3DTerrain.d
ir/terrain.cpp.obj
[ 20%] Linking CXX static library libHorde3DTerrain.a
[ 20%] Built target Horde3DTerrain
[ 21%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gAnimatables.cpp.obj
[ 23%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gAnimation.cpp.obj
[ 24%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gCamera.cpp.obj
[ 26%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gCom.cpp.obj
[ 27%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gComputeNode.cpp.obj
[ 28%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gComputeBuffer.cpp.obj
[ 30%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gExtensions.cpp.obj
[ 31%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gGeometry.cpp.obj
[ 33%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gLight.cpp.obj
[ 34%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gMain.cpp.obj
[ 36%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gMaterial.cpp.obj
[ 37%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gModel.cpp.obj
[ 39%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gModules.cpp.obj
[ 40%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gParticle.cpp.obj
[ 42%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gPipeline.cpp.obj
[ 43%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gPrimitives.cpp.obj
[ 44%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gRenderer.cpp.obj
[ 46%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gResource.cpp.obj
[ 47%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gScene.cpp.obj
[ 49%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gSceneGraphRes.cpp.obj
[ 50%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gShader.cpp.obj
[ 52%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gTexture.cpp.obj
[ 53%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/u
tImage.cpp.obj
[ 55%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gRendererBaseGL2.cpp.obj
[ 56%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/e
gRendererBaseGL4.cpp.obj
[ 57%] Building CXX object Horde3D/Source/Horde3DEngine/CMakeFiles/Horde3D.dir/u
tOpenGL.cpp.obj
[ 59%] Linking CXX shared library ../../../Binaries/Windows/Release/libHorde3D.d
ll
[ 59%] Built target Horde3D
[ 60%] Building CXX object Horde3D/Source/Horde3DUtils/CMakeFiles/Horde3DUtils.d
ir/main.cpp.obj
[ 62%] Linking CXX shared library ../../../Binaries/Windows/Release/libHorde3DUt
ils.dll
[ 62%] Built target Horde3DUtils
[ 63%] Building CXX object Horde3D/Samples/Framework/CMakeFiles/SampleFramework.
dir/sampleapp.cpp.obj
[ 65%] Building CXX object Horde3D/Samples/Framework/CMakeFiles/SampleFramework.
dir/GLFWFramework.cpp.obj
[ 66%] Linking CXX static library libSampleFramework.a
[ 66%] Built target SampleFramework
[ 68%] Built target GLFW_LIBRARY_EXTERN
[ 69%] Building CXX object Extensions/Terrain/Sample/CMakeFiles/Terrain.dir/app.
cpp.obj
[ 71%] Building CXX object Extensions/Terrain/Sample/CMakeFiles/Terrain.dir/main
.cpp.obj
[ 72%] Linking CXX executable ../../../Binaries/Windows/Release/Terrain.exe
c:/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw
32/bin/ld.exe: ../../../Horde3D/Samples/Framework/libSampleFramework.a(GLFWFrame
work.cpp.obj):GLFWFramework.cpp:(.text+0xac2): undefined reference to `__imp_h3d
utLoadResourcesFromDisk'
collect2.exe: error: ld returned 1 exit status
Extensions/Terrain/Sample/CMakeFiles/Terrain.dir/build.make:121: recipe for targ
et 'Binaries/Windows/Release/Terrain.exe' failed
make[2]: *** [Binaries/Windows/Release/Terrain.exe] Error 1
CMakeFiles/Makefile2:600: recipe for target 'Extensions/Terrain/Sample/CMakeFile
s/Terrain.dir/all' failed
make[1]: *** [Extensions/Terrain/Sample/CMakeFiles/Terrain.dir/all] Error 2
makefile:90: recipe for target 'all' failed
make: *** [all] Error 2