xkb_free_keymap(display->xkb);
}
+#ifdef HAVE_CAIRO_EGL
static int
init_egl(struct display *d)
{
eglTerminate(display->dpy);
eglReleaseThread();
}
+#endif
static int
event_mask_update(uint32_t mask, void *data)
/* Process connection events. */
wl_display_iterate(d->display, WL_DISPLAY_READABLE);
+#ifdef HAVE_CAIRO_EGL
if (init_egl(d) < 0)
return NULL;
+#endif
d->image_target_texture_2d =
(void *) eglGetProcAddress("glEGLImageTargetTexture2DOES");
cairo_surface_destroy(display->shadow);
destroy_pointer_surfaces(display);
+#ifdef HAVE_CAIRO_EGL
fini_egl(display);
+#endif
if (display->shell)
wl_shell_destroy(display->shell);