fix: gstreamer is supposed to be optional.
authorFelix Domke <tmbinc@elitedvb.net>
Fri, 17 Mar 2006 16:43:33 +0000 (16:43 +0000)
committerFelix Domke <tmbinc@elitedvb.net>
Fri, 17 Mar 2006 16:43:33 +0000 (16:43 +0000)
acinclude.m4
configure.ac

index e58d27518bf679bda0caa8acaa2a4662ffb2aac1..a2a623c4144134e9feed1be92091a02531a9571d 100644 (file)
@@ -246,6 +246,18 @@ AC_SUBST($1_CFLAGS)
 AC_SUBST($1_LIBS)
 ])
 
+AC_DEFUN(_TUXBOX_APPS_LIB_PKGCONFIG_OPTIONAL,[
+PKG_CHECK_MODULES($1,$2,$3="yes",$3="no")
+if test "x$3" = "xyes"; then
+       AC_DEFINE($3, 1, [$2 available])
+else
+       $1_CFLAGS=""
+       $1_LIBS=""
+fi
+AC_SUBST($1_CFLAGS)
+AC_SUBST($1_LIBS)
+])
+
 AC_DEFUN(TUXBOX_APPS_LIB_PKGCONFIG,[
 _TUXBOX_APPS_LIB_PKGCONFIG($1,$2)
 if test -z "$$1_CFLAGS" ; then
index c3bb9e55145a495f68bab44f778e1d3317e9ce40..59e7c539fc48ed881648b0c863f5a4d2dd52bd55 100644 (file)
@@ -27,13 +27,7 @@ TUXBOX_APPS_LIB_PKGCONFIG(MAD,mad)
 TUXBOX_APPS_LIB_PKGCONFIG(PNG,libpng)
 TUXBOX_APPS_LIB_PKGCONFIG(SIGC,sigc++-1.2)
 TUXBOX_APPS_LIB_PKGCONFIG(DVBSI,libdvbsi++)
-_TUXBOX_APPS_LIB_PKGCONFIG(GSTREAMER,gstreamer)
-
-if test -z "$GSTREAMER_CFLAGS" ; then
-  AC_MSG_WARN([could not find package GSTREAMER]);
-else
-       AC_DEFINE_UNQUOTED([HAVE_GSTREAMER],1,[Define to 1 if you have gstreamer])
-fi
+_TUXBOX_APPS_LIB_PKGCONFIG_OPTIONAL(GSTREAMER,gstreamer >= 0.10,HAVE_GSTREAMER)
 
 if test "$withsdl" = "yes" ; then
        TUXBOX_APPS_LIB_CONFIG(SDL,sdl-config)