Missing Headers While Building For WebAssembly

Problems building or running the engine, queries about how to use features etc.
Post Reply
Burbach
Gnoblar
Posts: 3
Joined: Wed Aug 12, 2020 6:24 pm
x 1

Missing Headers While Building For WebAssembly

Post by Burbach »

Ogre Version: :1.12:
Operating System: :Windows:
Render System: :OpenGl/WebGL:

Hello,

I am struggling to Build for WebAssembly (using Emscripten). The Ogre EGL support headers cannot locate EGL/egl.h when running emmake make

Code: Select all

C:/Users/Public/ogre-1.12.12/RenderSystems/GLSupport/include/EGL/OgreEGLSupport.h:35:10: fatal error: EGL/egl.h: No such file or directory
 #include <EGL/egl.h>
Here is my process for build from source:

1) I configure and generate, using CMAKE-GUI, the 1.12 source. I'm generating MinGW makefiles using a mingw-w64 posix compiler.

2) In my build folder I make a build-wasm directory

3) I navigate to the build-wasm directory and run:

Code: Select all

emcmake cmake .. -DCMAKE_BUILD_TYPE=Release
4) I navigate one level up from the build-wasm directory (top level of the build directory) and run:

Code: Select all

emmake make
Here the build fails with the above error on:

Code: Select all

[ 49%] Building CXX object RenderSystems/GLSupport/CMakeFiles/OgreGLSupport.dir/src/EGL/Emscripten/OgreEmscriptenEGLSupport.cpp.obj
I've tried both the 1.12.12 source and the 1.11.6 source. I get the same error for both.

I traditionally use the windows SDK. I'm not very experienced building from source.
paroj
OGRE Team Member
OGRE Team Member
Posts: 1994
Joined: Sun Mar 30, 2014 2:51 pm
x 1074
Contact:

Re: Missing Headers While Building For WebAssembly

Post by paroj »

seems your toolchain is not set-up correctly. The file should be there:
https://github.com/emscripten-core/emsc ... nclude/EGL

try compiling a small hello-world program first, before attempting to compile ogre.
Post Reply