Blame SOURCES/gavl-1.1.1-system_libgdither.patch

5fd82f
diff -up gavl-1.1.1/configure.ac.gdither gavl-1.1.1/configure.ac
5fd82f
--- gavl-1.1.1/configure.ac.gdither	2009-07-13 22:42:38.000000000 +0200
5fd82f
+++ gavl-1.1.1/configure.ac	2009-10-28 00:02:31.461428785 +0100
5fd82f
@@ -217,6 +217,27 @@ TOP_SRCDIR=`cd ${srcdir} && pwd` 
5fd82f
 AC_SUBST(TOP_SRCDIR)
5fd82f
 
5fd82f
 dnl
5fd82f
+dnl System libraries
5fd82f
+dnl
5fd82f
+
5fd82f
+AC_ARG_ENABLE(libgdither,
5fd82f
+  [  --enable-libgdither	System libgdither (experimental)])
5fd82f
+if test "${enable_libgdither}" = "yes"
5fd82f
+then
5fd82f
+  PKG_CHECK_MODULES(LIBGDITHER, libgdither,
5fd82f
+    [
5fd82f
+      AC_DEFINE(HAVE_LIBGDITHER, 1, [Define to 1 if you have the `libgdither' library (-lgdither).])
5fd82f
+      have_libgdither="true"
5fd82f
+    ],
5fd82f
+    [
5fd82f
+      have_libgdither="false"
5fd82f
+    ]
5fd82f
+  )
5fd82f
+fi
5fd82f
+AM_CONDITIONAL(HAVE_LIBGDITHER, [test x$have_libgdither = xtrue])
5fd82f
+
5fd82f
+
5fd82f
+dnl
5fd82f
 dnl Output variables
5fd82f
 dnl
5fd82f
 
5fd82f
diff -up gavl-1.1.1/gavl/Makefile.am.gdither gavl-1.1.1/gavl/Makefile.am
5fd82f
--- gavl-1.1.1/gavl/Makefile.am.gdither	2009-05-13 17:10:37.000000000 +0200
5fd82f
+++ gavl-1.1.1/gavl/Makefile.am	2009-10-28 00:04:37.837435280 +0100
5fd82f
@@ -40,8 +40,15 @@ threednow_libs = 
5fd82f
 threednow_subdirs =
5fd82f
 endif
5fd82f
 
5fd82f
+if HAVE_LIBGDITHER
5fd82f
+  MAYBE_LIBGDITHER_LA = @LIBGDITHER_LIBS@
5fd82f
+else
5fd82f
+  MAYBE_LIBGDITHER = libgdither
5fd82f
+  MAYBE_LIBGDITHER_LA = libgdither/libgdither.la
5fd82f
+endif
5fd82f
+
5fd82f
 
5fd82f
-SUBDIRS = hq c libgdither libsamplerate $(mmx_subdirs) \
5fd82f
+SUBDIRS = hq c $(MAYBE_LIBGDITHER) libsamplerate $(mmx_subdirs) \
5fd82f
 $(sse_subdirs) \
5fd82f
 $(sse2_subdirs) \
5fd82f
 $(sse3_subdirs) \
5fd82f
@@ -109,7 +116,7 @@ $(sse3_libs) \
5fd82f
 $(threednow_libs) \
5fd82f
 c/libgavl_c.la \
5fd82f
 hq/libgavl_hq.la \
5fd82f
-libgdither/libgdither.la \
5fd82f
+$(MAYBE_LIBGDITHER_LA) \
5fd82f
 libsamplerate/libsamplerate.la \
5fd82f
 @LIBGAVL_LIBS@ \
5fd82f
 -lm