lunixbochs / glshim

OpenGL 1.x driver shim for OpenGL ES devices.
https://boards.openpandora.org/topic/11506-glshim/
MIT License
159 stars 32 forks source link

Can't compile it ? (Intel Atom x86 - OpenGL on chrooted Linux with Android - Asus Zenfone 2 ze551ml) #130

Open Tikilou opened 8 years ago

Tikilou commented 8 years ago

Hi, i'm using Ubuntu 15.04 32bits with a chroot+X11/VNC solution, on a mobile device withe Intel Atom Z3580 and GPU PowerVR G6430 .

I'm trying to compile glshim (because i want be able to use OpenGL acceleration), but when i want to compile it, i have errors, any idea ?

camille@localhost:~/temp/glshim$ cmake .; make GL -- Configuring done -- Generating done -- Build files have been written to: /home/camille/temp/glshim [ 0%] Building C object src/CMakeFiles/GL.dir/gl/matrix.c.o In file included from /home/camille/temp/glshim/src/gl/wrap/../types.h:9:0, from /home/camille/temp/glshim/src/gl/wrap/glpack.h:1, from /home/camille/temp/glshim/src/gl/loader.h:10, from /home/camille/temp/glshim/src/gl/matrix.c:2: /home/camille/temp/glshim/src/util/extypes.h:5:22: fatal error: X11/Xlib.h: No such file or directory

include <X11/Xlib.h>

                  ^

compilation terminated. src/CMakeFiles/GL.dir/build.make:54: recipe for target 'src/CMakeFiles/GL.dir/gl/matrix.c.o' failed make[3]: * [src/CMakeFiles/GL.dir/gl/matrix.c.o] Error 1 CMakeFiles/Makefile2:79: recipe for target 'src/CMakeFiles/GL.dir/all' failed make[2]: * [src/CMakeFiles/GL.dir/all] Error 2 CMakeFiles/Makefile2:91: recipe for target 'src/CMakeFiles/GL.dir/rule' failed make[1]: * [src/CMakeFiles/GL.dir/rule] Error 2 Makefile:151: recipe for target 'GL' failed make: * [GL] Error 2

lunixbochs commented 8 years ago

You need X11 headers. In Ubuntu, that's probably apt-get install libx11-dev

Tikilou commented 8 years ago

Thank you very much !!! =D It work, i have libGL.so libGL.so.1 and libGL.so.1.2.0 for my Smartphone Asus Zenfone 2 ze551ml with Android CyanogenMod 12.1 host, now :)

Tikilou commented 8 years ago

Ho... After putting libs in /usr/lib, i'm trying "glxgears", and segfault :(

glxgears libGL: warning, gles is NULL libGL:loaded: libEGL.so.1 libGL: built on Aug 15 2015 23:06:18 libGL: warning, gles_glLightfv is NULL stub glLightfv(0x4000, 0x1203, 0x804d150); Segmentation fault

lunixbochs commented 8 years ago

Does es2gears work?

It couldn't find your libGLESv1 library. If it has a weird path, try setting LIBGL_GLES=/path/to/libGLESv1.so (or v1_CM.so)

Tikilou commented 8 years ago

Where i need to put in ? On Android host system, or Ubuntu chrooted system ?

I'm gonna try it with es2gears

lunixbochs commented 8 years ago

I have no Android test systems set up and have never personally tried glshim on Android. It should definitely work outside the chroot as glshim was used in the Minecraft launcher release for Android.

es2gears isn't for glshim, it's to make sure you have OpenGL ES working inside your chroot at all.

mittorn commented 8 years ago

Try use libhybris for gles in chroot.

lunixbochs commented 8 years ago

glshim remote rendering is another option.

Arucard1983 commented 8 years ago

Debian Wheezy and Jessie will install libglesv2-mesa by default when installs and configures the X11 Server libraries, so just install the legacy packge libglesv1-mesa.

lunixbochs commented 8 years ago

libglesv1-mesa will just give you software rendering, which is probably not what you want.