changeset 5598:d9ced9ad7de2

Android: RT-33855 eglGetDisplay method not found. libglesv2 must be also dlopened otherwise gl functions were not found. Reviewed: petr.vasenda@oracle.com
author tb115823 <Tomas.Brandalik@oracle.com>
date Thu, 31 Oct 2013 12:35:38 +0100
parents 024eca0e0e8c
children a630648b31c2
files modules/graphics/src/main/native-prism-es2/eglfb/wrapped_egl.c
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/modules/graphics/src/main/native-prism-es2/eglfb/wrapped_egl.c	Thu Oct 31 14:51:58 2013 +0400
+++ b/modules/graphics/src/main/native-prism-es2/eglfb/wrapped_egl.c	Thu Oct 31 12:35:38 2013 +0100
@@ -90,6 +90,12 @@
     }
 
     _eglGetDisplay = dlsym(libegl, "eglGetDisplay");
+    
+    libglesv2 = dlopen("libGLESv2.so", RTLD_LAZY | RTLD_GLOBAL);
+    if (!libglesv2) {
+        fprintf(stderr, "Did not find libGLESv2.so %s\n", dlerror());
+        return 0;
+    }
 #else
     
     Dl_info dlinfo;