Commit 986475fa by Yuly Novikov Committed by Commit Bot

Fix native EGL library loading on Android.

Takes care of non-component Clank build and 64 bit. BUG=angleproject:1362 TEST=angle_end2end_tests Change-Id: Ib338734960c6ac378ae49028ae30416bff31ac2a Reviewed-on: https://chromium-review.googlesource.com/352710Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
parent 1d688763
......@@ -16,6 +16,18 @@
#include "libANGLE/renderer/gl/egl/PbufferSurfaceEGL.h"
#include "libANGLE/renderer/gl/egl/WindowSurfaceEGL.h"
namespace
{
const char *GetEGLPath()
{
#if defined(__LP64__)
return "/system/lib64/libEGL.so";
#else
return "/system/lib/libEGL.so";
#endif
}
} // namespace
namespace rx
{
......@@ -31,7 +43,7 @@ egl::Error DisplayAndroid::initialize(egl::Display *display)
{
FunctionsEGLDL *egl = new FunctionsEGLDL();
mEGL = egl;
ANGLE_TRY(egl->initialize(display->getNativeDisplayId(), "libEGL.so"));
ANGLE_TRY(egl->initialize(display->getNativeDisplayId(), GetEGLPath()));
gl::Version eglVersion(mEGL->majorVersion, mEGL->minorVersion);
ASSERT(eglVersion >= gl::Version(1, 4));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment