gdkgl: Check for GLsync before using it
Copy what we do in GTK4: Check for GL >= 3.2 or GLES >= 3.0 or the
GL_ARB_sync extension.
Then store that info for a (private) gdk_gl_context_has_sync()
function.
And then check that function before using GLsync objects as introduced
by commit
9811485990b.
Bug: https://gitlab.gnome.org/GNOME/gtk/-/issues/5749
Forwarded: https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/6162
Origin: 3.24.39, commit:
cf7decae1a1a2af825caca8da018ce09cd9ce31a
Gbp-Pq: Name gdkgl-Check-for-GLsync-before-using-it.patch