Restore GLES2-X11 back-end to working order

Port the GLES2-X11 back-end to the new back-end interface,
supporting OpenGL-ES 2.0 devices with X11 support. Tested on a
Mali-400 based device.

A few bugs were fixed that might also have affected OpenGL
(PC) platforms.

Signed-off-by: Harm Hanemaaijer <fgenfb@yahoo.com>