SmartAudio/package/multimedia/gst1-plugins-base/patches/0002-gl-only-enable-gbm-bac...

49 lines
1.4 KiB
Diff

From ba50f6959e26f51171ebafdd44e16481ddfc7835 Mon Sep 17 00:00:00 2001
From: xielinfei <xielinfei@allwinnertech.com>
Date: Thu, 8 Mar 2018 15:52:15 +0800
Subject: [PATCH] gl: only enable gbm backend if gudev is available
Signed-off-by: xielinfei <xielinfei@allwinnertech.com>
---
configure.ac | 4 ++--
m4/gst-gl.m4 | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index 380413a..a01122c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -295,14 +295,14 @@ GST_PREFIX="`$PKG_CONFIG --variable=prefix gstreamer-$GST_API_VERSION`"
AC_SUBST(GLIB_PREFIX)
AC_SUBST(GST_PREFIX)
-AG_GST_GL_CHECKS
-
dnl check for gudev
PKG_CHECK_MODULES(G_UDEV, gudev-1.0 , [
AC_DEFINE([HAVE_GUDEV], 1, [Define if gudev is installed])
HAVE_GUDEV="yes" ],
[HAVE_GUDEV="no"])
+AG_GST_GL_CHECKS
+
dnl GTK is optional and only used in examples
HAVE_GTK=no
HAVE_GTK_X11=no
diff --git a/m4/gst-gl.m4 b/m4/gst-gl.m4
index bd6d173..1e97240 100644
--- a/m4/gst-gl.m4
+++ b/m4/gst-gl.m4
@@ -176,7 +176,7 @@ case $host in
PKG_CHECK_MODULES(DRM, libdrm >= 2.4.55, HAVE_DRM=yes, HAVE_DRM=no)
AC_SUBST(DRM_CFLAGS)
AC_SUBST(DRM_LIBS)
- if test "x$HAVE_DRM" = "xyes"; then
+ if test "x$HAVE_DRM" = "xyes" -a "x$HAVE_GUDEV" = "xyes"; then
PKG_CHECK_MODULES(GBM, gbm, HAVE_GBM_EGL=yes, HAVE_GBM_EGL=no)
AC_SUBST(GBM_CFLAGS)
AC_SUBST(GBM_LIBS)
--
1.9.1