[PATCH 1/1] libweston: fix building issue when EGL support is not enabled
Giulio Camuffo
giuliocamuffo at gmail.com
Tue Nov 1 17:51:30 UTC 2016
2016-10-11 13:47 GMT+02:00 Vincent Abriou <vincent.abriou at st.com>:
> weston-egl-ext.h has been include in compositor-xx.c file in order to
> define EGL_PLATFORM_xxx_KHR extensions used by the compositors.
> But in case EGL support is not enabled, all EGL related definition must
> be skipped except EGL_PLATFORM_xxx_KHR that must be still defined to
> allow compositor-xx.c to build.
Makes sense. Ifdeffing away the egl code in the backends would be
uglier imho, so
Reviewed-by: Giulio Camuffo <giuliocamuffo at gmail.com>
Cheers,
Giulio
>
> Signed-off-by: Vincent Abriou <vincent.abriou at st.com>
> Cc: Daniel Stone <daniel at fooishbar.org>
> ---
> libweston/weston-egl-ext.h | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/libweston/weston-egl-ext.h b/libweston/weston-egl-ext.h
> index 6e36996..70556fd 100644
> --- a/libweston/weston-egl-ext.h
> +++ b/libweston/weston-egl-ext.h
> @@ -28,6 +28,8 @@
> #ifndef WESTON_EGL_EXT_H
> #define WESTON_EGL_EXT_H
>
> +#ifdef ENABLE_EGL
> +
> #ifndef EGL_WL_bind_wayland_display
> #define EGL_WL_bind_wayland_display 1
>
> @@ -152,5 +154,13 @@ typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMPIXMAPSURFACEEXTPROC) (EGLD
> #define EGL_PLATFORM_X11_KHR 0x31D5
> #endif
>
> +#else /* ENABLE_EGL */
> +
> +/* EGL platform definition are keept to allow compositor-xx.c to build */
> +#define EGL_PLATFORM_GBM_KHR 0x31D7
> +#define EGL_PLATFORM_WAYLAND_KHR 0x31D8
> +#define EGL_PLATFORM_X11_KHR 0x31D5
> +
> +#endif /* ENABLE_EGL */
>
> #endif
> --
> 1.9.1
>
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/wayland-devel
More information about the wayland-devel
mailing list