From e4d989af088bc3ac727689f892142030d07119a3 Mon Sep 17 00:00:00 2001 From: Nicholas Sharp Date: Mon, 27 Jan 2025 23:39:48 -0800 Subject: [PATCH] try more filenames for egl loading --- src/render/opengl/gl_engine_egl.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/render/opengl/gl_engine_egl.cpp b/src/render/opengl/gl_engine_egl.cpp index 0eaaa875..7280f7b5 100644 --- a/src/render/opengl/gl_engine_egl.cpp +++ b/src/render/opengl/gl_engine_egl.cpp @@ -290,11 +290,17 @@ void GLEngineEGL::resolveEGL() { std::cout << polyscope::options::printPrefix << "Attempting to dlopen libEGL.so" << std::endl; } void* handle = dlopen("libEGL.so", RTLD_LAZY); + if (handle && options::verbosity > 5) { + std::cout << polyscope::options::printPrefix << " ...loaded libEGL.so" << std::endl; + } if (!handle) { - error("EGL: Could not open libEGL.so."); + handle = dlopen("libEGL.so.1", RTLD_LAZY); // try it while we're at it, happens on OSMesa without dev headers } - if (options::verbosity > 5) { - std::cout << polyscope::options::printPrefix << " ...loaded libEGL.so" << std::endl; + if (handle && options::verbosity > 5) { + std::cout << polyscope::options::printPrefix << " ...loaded libEGL.so.1" << std::endl; + } + if (!handle) { + error("EGL: Could not open libEGL.so"); } // Get EGL functions