fix build in emscripten
Fix OpenGL port for desktop