glamor_egl: Reject OpenGL < 2.1 early on

The Etnaviv driver on GC2000 reports desktop OpenGL 1.3 but also OpenGL ES 2.0.
However, with the modesetting driver, GLES2 never gets a chance:

  [ 11233.393] Require OpenGL version 2.1 or later.
  [ 11233.393] (EE) modeset(0): Failed to initialize glamor at ScreenInit() time.
  [ 11233.393] (EE)
  Fatal server error:
  [ 11233.395] (EE) AddScreen/ScreenInit failed for driver 0

Let's reject old desktop GL early on, just like XWayland seems to do.

This is perhaps a slightly bit more complicated that one would expect, since we
need to call eglMakeCurrent() before we query the GL version.

Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
3 jobs for lr/modesetting-gles2 in 11 minutes and 42 seconds (queued for 1 second)
Status Job ID Name Coverage
  Docker Image
passed #1300381
debian-testing

00:01:39

 
  Build And Test
passed #1300382
autotools-build-and-test

00:10:02

passed #1300383
meson-build-and-test

00:03:20