diff options
author | Sreerenj Balachandran <sreerenj.balachandran@intel.com> | 2012-07-19 10:27:23 +0200 |
---|---|---|
committer | Gwenole Beauchesne <gwenole.beauchesne@intel.com> | 2012-07-25 15:31:42 +0200 |
commit | 621bb12be6ba82db701f505c38a0ebc25a3941c8 (patch) | |
tree | d1fc3b6ac4580500a9e68afe146cc14d1f2af05e /configure.ac | |
parent | 5a1293a27e714d0a417d4e32291f80a9d36b29ae (diff) |
Add initial support for VA/Wayland.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 7ef92f34..86c4f7b5 100644 --- a/configure.ac +++ b/configure.ac @@ -45,10 +45,12 @@ m4_define([gst_plugins_bad_version], m4_define([va_api_version], [0.30.4]) m4_define([va_api_x11_version], [0.31.0]) m4_define([va_api_glx_version], [0.32.0]) +m4_define([va_api_wld_version], [0.34.0]) # libva package version number m4_define([libva_x11_package_version], [1.0.3]) m4_define([libva_glx_package_version], [1.0.9]) +m4_define([libva_wld_package_version], [1.2.0]) # gtk-doc version number # XXX: introspection annotations require gtk-doc >= 1.12 @@ -110,6 +112,11 @@ AC_ARG_ENABLE(glx, [enable OpenGL/X11 output @<:@default=yes@:>@]), [], [enable_glx="yes"]) +AC_ARG_ENABLE(wayland, + AC_HELP_STRING([--enable-wayland], + [enable Wayland output @<:@default=yes@:>@]), + [], [enable_wayland="yes"]) + dnl Check for basic libraries AC_CHECK_LIB(m, tan) @@ -319,6 +326,20 @@ if test "$enable_glx" = "yes" -a $HAVE_GL -eq 1 -a $USE_X11 -eq 1; then LIBS="$saved_LIBS" fi +dnl Check for Wayland +USE_WAYLAND=0 +if test "$enable_wayland" = "yes"; then + PKG_CHECK_MODULES(WAYLAND, [wayland-client], + [USE_WAYLAND=1], [USE_WAYLAND=0]) + + if test $USE_WAYLAND -eq 1; then + saved_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $WAYLAND_CFLAGS" + AC_CHECK_HEADERS([wayland-client.h], [:], [USE_WAYLAND=0]) + CPPFLAGS="$saved_CPPFLAGS" + fi +fi + dnl --------------------------------------------------------------------------- dnl -- VA-API -- dnl --------------------------------------------------------------------------- @@ -382,11 +403,17 @@ AC_CACHE_CHECK([for JPEG decoding API], LIBS="$saved_LIBS" ]) +dnl VA/Wayland API +if test "$enable_wayland" = "yes"; then + PKG_CHECK_MODULES([LIBVA_WAYLAND], [libva-wayland >= va_api_wld_version], + [:], [USE_WAYLAND=0]) +fi + dnl --------------------------------------------------------------------------- dnl -- Generate files and summary -- dnl --------------------------------------------------------------------------- -case ":$USE_X11:$USE_GLX:" in +case ":$USE_X11:$USE_GLX:$USE_WAYLAND:" in *:1:*) ;; *) @@ -406,6 +433,10 @@ AC_DEFINE_UNQUOTED(USE_GLX, $USE_GLX, [Defined to 1 if GLX is enabled]) AM_CONDITIONAL(USE_GLX, test $USE_GLX -eq 1) +AC_DEFINE_UNQUOTED(USE_WAYLAND, $USE_WAYLAND, + [Defined to 1 if WAYLAND is enabled]) +AM_CONDITIONAL(USE_WAYLAND, test $USE_WAYLAND -eq 1) + pkgconfigdir=${libdir}/pkgconfig AC_SUBST(pkgconfigdir) @@ -456,6 +487,7 @@ yesno() { VIDEO_OUTPUTS="" AS_IF([test $USE_X11 -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS x11"]) AS_IF([test $USE_GLX -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS glx"]) +AS_IF([test $USE_WAYLAND -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS wayland"]) echo echo $PACKAGE configuration summary: |