summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorGwenole Beauchesne <gbeauchesne@splitted-desktop.com>2010-03-08 09:44:25 +0100
committerAustin Yuan <shengquan.yuan@gmail.com>2010-05-13 02:29:32 +0800
commit50c8ae8a5379a3aa6312edae6bb083936eaa43a6 (patch)
tree8ede74531c51d45a53c14330ff6a2378e2d0d6ce /configure.ac
parente734b66e657d92dbd29b216fc753d0c30c7df4f0 (diff)
Add OpenGL extensions (v3) and generic implementation with TFP and FBO.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac22
1 files changed, 22 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index a6d01ee..ebb06cf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -60,6 +60,11 @@ LIBVA_LT_LDFLAGS="-version-info $LIBVA_LT_VERSION"
AC_SUBST(LIBVA_LT_VERSION)
AC_SUBST(LIBVA_LT_LDFLAGS)
+AC_ARG_ENABLE(glx,
+ [AC_HELP_STRING([--enable-glx],
+ [build with OpenGL for X11 support])],
+ [], [enable_glx=yes])
+
AC_ARG_ENABLE(dummy-driver,
[AC_HELP_STRING([--enable-dummy-driver],
[build dummy video driver])],
@@ -113,6 +118,22 @@ if test x$libudev = xno; then
fi
AM_CONDITIONAL(BUILD_DUMMY_BACKEND, test x$enable_dummy_backend = xyes)
+# Check for OpenGL (X11)
+USE_GLX="no"
+GL_DEPS_CFLAGS=""
+GL_DEPS_LIBS=""
+if test x$enable_glx = xyes; then
+ AC_CHECK_HEADERS([GL/gl.h])
+ AC_CHECK_HEADERS([GL/glx.h])
+ AC_CHECK_LIB(GL, glXCreateContext, [
+ USE_GLX="yes"
+ GL_DEPS_LIBS="-lX11 -lGL"
+ ])
+fi
+AC_SUBST(GL_DEPS_CFLAGS)
+AC_SUBST(GL_DEPS_LIBS)
+AM_CONDITIONAL(USE_GLX, test "$USE_GLX" = "yes")
+
# We only need the headers, we don't link against the DRM libraries
LIBVA_CFLAGS="$DRM_CFLAGS"
AC_SUBST(LIBVA_CFLAGS)
@@ -146,5 +167,6 @@ AC_OUTPUT([
test/encode/Makefile
libva.pc
libva-x11.pc
+ libva-glx.pc
])