]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - glsdk/gst-plugins-ugly0-10.git/blobdiff - configure.ac
more mergeback from the latest release
[glsdk/gst-plugins-ugly0-10.git] / configure.ac
index b64ac1c404717a818ead5b2e20ca47939f57cb70..3ebe17d39e0d5c149b171126645881c934ceecc8 100644 (file)
@@ -1,54 +1,31 @@
-dnl autoconf configuration file for plugins 
+dnl autoconf configuration file for gst-plugins 
 AC_INIT
-dnl FIXME take something else ?
-AC_CONFIG_SRCDIR([COPYING])
-
 AC_CANONICAL_TARGET([])
 
-AM_CONFIG_HEADER(config.h)
-
-GST_VERSION_MAJOR=0
-GST_VERSION_MINOR=3
-GST_VERSION_MICRO=02
-
-dnl we use the release tag during CVS development
-GST_VERSION_RELEASE=`date +%Y%m%d`
-
-GST_VERSION=$GST_VERSION_MAJOR.$GST_VERSION_MINOR.$GST_VERSION_MICRO
-
-PACKAGE=gst-plugins
-VERSION=$GST_VERSION
+dnl We disable static building for development, for time savings
+dnl this goes before AS_LIBTOOL to appease autoconf
+dnl *NOTE*: dnl this line before release, so release does static too
+AM_DISABLE_STATIC
 
-AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
-AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
-AC_SUBST(PACKAGE)
-AC_SUBST(VERSION)
-AC_DEFINE_UNQUOTED(GST_VERSION_RELEASE, "$GST_VERSION_RELEASE")
-AC_SUBST(GST_VERSION_RELEASE)
+dnl when going to/from release please set the nano (fourth number) right !
+dnl We disable static building for development, for time savings
+AM_DISABLE_STATIC
+AS_VERSION(gst-plugins, GST_PLUGINS, 0, 3, 4, 0)
+AM_INIT_AUTOMAKE($PACKAGE,$VERSION)
+AS_LIBTOOL(GST_PLUGINS, 0, 0, 0, yes)
 
-dnl libtool
-GST_CURRENT=1
-GST_REVISION=0
-GST_AGE=0
-GST_LIBVERSION=$GST_CURRENT:$GST_REVISION:$GST_AGE
+dnl we'll move this to a configure option later on which will be turned on
+dnl by autogen
+dnl GST_ERROR="-Wall -Werror"
+GST_ERROR="-Werror"
 
-dnl check for gstreamer
-PKG_CHECK_MODULES(GST, gstreamer >= 0.3.0)
+dnl FIXME take something else ?
+AC_CONFIG_SRCDIR([gst/law/alaw.c])
+AM_CONFIG_HEADER(config.h)
 
-AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
 dnl Add parameters for aclocal
 dnl (This must come after AM_INIT_AUTOMAKE, since it modifies ACLOCAL)
-ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS"
-
-AC_SUBST(GST_VERSION_MAJOR)
-AC_SUBST(GST_VERSION_MINOR)
-AC_SUBST(GST_VERSION_MICRO)
-AC_SUBST(GST_VERSION)
-
-AC_SUBST(GST_CURRENT)
-AC_SUBST(GST_REVISION)
-AC_SUBST(GST_AGE)
-AC_SUBST(GST_LIBVERSION)
+ACLOCAL="$ACLOCAL -I m4 -I common/m4 $ACLOCAL_FLAGS"
 
 AM_MAINTAINER_MODE
 
@@ -60,12 +37,6 @@ AC_PROG_CXX
 AC_PROG_CXXCPP
 AC_ISC_POSIX
 
-dnl We disable static building for development, for time savings
-dnl *NOTE*: dnl this line before release, so release does static too
-AM_DISABLE_STATIC
-AC_LIBTOOL_DLOPEN
-AM_PROG_LIBTOOL
-
 AC_HEADER_STDC([])
 
 dnl ###########################################
@@ -78,23 +49,24 @@ GST_CHECK_FEATURE(EXPERIMENTAL, [enable building of experimental plugins],,
 [HAVE_EXPERIMENTAL=yes],disabled,
 [
   AC_MSG_WARN(building experimental plugins)
-  USE_LIBMIKMOD="yes"
-  USE_SMOOTHWAVE="yes"
+  USE_RTP="yes"
+  USE_TARKIN="yes"
 ],[
   AC_MSG_NOTICE(not building experimental plugins)
-  USE_LIBMIKMOD="no"
-  USE_SMOOTHWAVE="no"
+  USE_RTP="no"
+  USE_TARKIN="no"
 ])
 
 dnl broken plugins; stuff that doesn't seem to build at the moment
 GST_CHECK_FEATURE(BROKEN, [enable building of broken plugins],,
 HAVE_BROKEN=yes,disabled,
 [  
-  AC_MSG_WARN(building broken plugins)
+  AC_MSG_WARN([building broken plugins -- no bug reports on these, only patches :)])
+  USE_SMOOTHWAVE="yes"
   USE_VGA="yes"
   USE_XMMS="yes"
-  dnl AC_MSG_NOTICE(actually there are no broken plugins at the moment)
 ],[
+  USE_SMOOTHWAVE="no"
   USE_VGA="no"
   USE_XMMS="no"
   AC_MSG_NOTICE(not building broken plugins)
@@ -107,6 +79,11 @@ dnl ##############################
 dnl Check for tools:
 dnl ================
 
+dnl modify pkg-config path
+AC_ARG_WITH(pkg-config-path, 
+   AC_HELP_STRING([--with-pkg-config-path],[colon-separated list of pkg-config(1) dirs]),
+   [export PKG_CONFIG_PATH=${withval}])
+
 dnl Check for nasm
 AC_PATH_PROG(NASM_PATH, nasm, no)
 AC_SUBST(NASM_PATH)
@@ -118,72 +95,19 @@ else
   HAVE_NASM="yes"
 fi
 
-dnl fix pkg-config's broken default search path
-if test -z $PKG_CONFIG_PATH; then
-  PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/usr/lib/pkgconfig
+dnl check for gstreamer; uninstalled is selected preferentially -- see pkg-config(1)
+PKG_CHECK_MODULES(GST, gstreamer >= $GST_PLUGINS_MAJOR.$GST_PLUGINS_MINOR.$GST_PLUGINS_MICRO,
+  HAVE_GST="yes", HAVE_GST="no")
+
+if test "x$HAVE_GST" = "xno"; then
+  AC_MSG_ERROR(no GStreamer found)
 fi
-export PKG_CONFIG_PATH
-
-dnl Check for pkgconfig
-AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, true, false)
-
-dnl dnl check for gtk-doc
-dnl AC_ARG_WITH(html-dir, [  --with-html-dir=PATH path to installed docs ])
-dnl 
-dnl if test "x$with_html_dir" = "x" ; then
-dnl   HTML_DIR='${datadir}/gst/html'
-dnl else
-dnl   HTML_DIR=$with_html_dir
-dnl fi
-dnl 
-dnl AC_SUBST(HTML_DIR)
-dnl 
-dnl AC_CHECK_PROG(HAVE_GTK_DOC, gtkdoc-mkdb, true, false)
-dnl gtk_doc_min_version=0.6
-dnl if $HAVE_GTK_DOC ; then 
-dnl     gtk_doc_version=`gtkdoc-mkdb --version`
-dnl     AC_MSG_CHECKING([gtk-doc version ($gtk_doc_version) >= $gtk_doc_min_version])
-dnl     if perl <<EOF ; then
-dnl       exit (("$gtk_doc_version" =~ /^[[0-9]]+\.[[0-9]]+$/) &&
-dnl             ("$gtk_doc_version" >= "$gtk_doc_min_version") ? 0 : 1);
-dnl EOF
-dnl       AC_MSG_RESULT(yes)
-dnl    else
-dnl       AC_MSG_RESULT(no)
-dnl       HAVE_GTK_DOC=false
-dnl    fi
-dnl fi
-dnl GTK_DOC_SCANOBJ=gtkdoc-scanobj
-dnl 
-dnl AC_SUBST(HAVE_GTK_DOC)
-dnl AC_SUBST(GTK_DOC_SCANOBJ)
-dnl 
-dnl dnl check for docbook tools
-dnl AC_CHECK_PROG(HAVE_XSLTPROC, xsltproc, true, false)
-dnl AC_CHECK_PROG(HAVE_PDFTOPS, pdftops, true, false)
-dnl dnl this does not yet work properly, at least on debain -- wingo
-dnl HAVE_PDFXMLTEX=false
-dnl 
-dnl dnl check for image conversion tool
-dnl AC_CHECK_PROG(HAVE_FIG2DEV, fig2dev, true, false)
-dnl 
-dnl dnl The following is a hack: if fig2dev doesn't display an error message
-dnl dnl for the desired type, we assume it supports it.
-dnl HAVE_FIG2DEV_PNG=false
-dnl if test "x$HAVE_FIG2DEV" = "xtrue" ; then
-dnl   fig2dev_quiet=`fig2dev -L png </dev/null 2>&1 >/dev/null`
-dnl   if test "x$fig2dev_quiet" = "x" ; then
-dnl     HAVE_FIG2DEV_PNG=true
-dnl   fi
-dnl fi
-dnl HAVE_FIG2DEV_PDF=false
-dnl if test "x$HAVE_FIG2DEV" = "xtrue" ; then
-dnl   fig2dev_quiet=`fig2dev -L pdf </dev/null 2>&1 >/dev/null`
-dnl   if test "x$fig2dev_quiet" = "x" ; then
-dnl     HAVE_FIG2DEV_PDF=true
-dnl   fi
-dnl fi
-dnl 
+
+GST_TOOLS_DIR=`pkg-config --variable=toolsdir gstreamer`
+if test -z $GST_TOOLS_DIR; then
+  AC_MSG_ERROR([no tools dir defined in GStreamer pkg-config file; core upgrade needed.])
+fi
+AC_SUBST(GST_TOOLS_DIR)
 
 dnl Set up conditionals for (target) architecture:
 dnl ==============================================
@@ -196,7 +120,7 @@ case "x${target_cpu}" in
               dnl       (ie CPUID)
               case "x${target_cpu}" in
                 xi386 | xi486) ;;
-                *)             AC_DEFINE(HAVE_RDTSC) ;;
+                *)             AC_DEFINE(HAVE_RDTSC, 1, [Define if RDTSC is available]) ;;
               esac ;;
   xpowerpc)   HAVE_CPU_PPC=yes
               AC_DEFINE(HAVE_CPU_PPC, 1, [Define if the target CPU is a PPC]) ;;
@@ -215,64 +139,20 @@ esac
 dnl Determine endianness
 AC_C_BIGENDIAN
 
-dnl Check for MMX-capable compiler
-AC_MSG_CHECKING(for MMX-capable compiler)
-AC_TRY_RUN([
-#include "include/mmx.h"
-
-main()
-{ movq_r2r(mm0, mm1); return 0; }
-],
-[
-HAVE_LIBMMX="yes"
-AC_MSG_RESULT(yes)
-],
-HAVE_LIBMMX="no"
-AC_MSG_RESULT(no)
-,
-HAVE_LIBMMX="no"
-AC_MSG_RESULT(no)
-)
-
-dnl
-dnl We should really use AC_SYS_LARGEFILE, but the problem is
-dnl many of the plugins don't include "config.h".  To assure
-dnl binary compatibility, it is necessary that all gstreamer
-dnl code be compiled with the same sizeof(off_t), so we use
-dnl the following crude hack.
-dnl
-
-AC_MSG_CHECKING(for large file support)
-AC_TRY_RUN([
-#define _LARGEFILE_SOURCE
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
-int main () { return !(sizeof(off_t) == 8); }
-],
-[
-AC_MSG_RESULT(yes)
-GST_CFLAGS="$GST_CFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
-],
-[
-AC_MSG_RESULT(no)
-],
-[
-AC_MSG_RESULT(no)
-])
-
 dnl Check for essential libraries first:
 dnl ====================================
 
-dnl if test -n "`cat $GST_CFLAGS | grep USE_GLIB2`"; then
-dnl   HAVE_GLIB2=yes
-dnl else
-dnl   HAVE_GLIB2=no
-dnl fi
+GST_GLIB2_CHECK()
+PKG_CHECK_MODULES(GTK2, gtk+-2.0, HAVE_GTK=yes, HAVE_GTK=no)
+GTK_CFLAGS=$GTK2_CFLAGS
+GTK_LIBS=$GTK2_LIBS
+AC_SUBST(GTK_LIBS)
+AC_SUBST(GTK_CFLAGS)
 
 dnl Check for X11 extensions
 AC_PATH_XTRA
 if test "-DX_DISPLAY_MISSING" = "$X_CFLAGS"; then
-  AC_MSG_ERROR(can not find X11)
+  AC_MSG_NOTICE([cannot find X11, the build system needs fixage])
 fi
 AC_SUBST(X_CFLAGS)
 AC_SUBST(X_PRE_LIBS)
@@ -282,13 +162,15 @@ AC_SUBST(X_LIBS)
 dnl ==========================================================================
 dnl ============================= gst plugins ================================
 dnl ==========================================================================
+GST_PLUGIN_LDFLAGS='-module -avoid-version'
+AC_SUBST(GST_PLUGIN_LDFLAGS)
 
 GST_PLUGINS_ALL="\
         ac3parse adder audioscale auparse avi chart\
-        cutter deinterlace flx intfloat law level\
-        median mpeg1enc mpeg1sys mpeg2enc mpeg2sub\
-        mpegaudio mpegaudioparse mpegstream mpegtypes\
-        passthrough playondemand rtjpeg silence sine\
+        cutter deinterlace flx goom intfloat law level\
+        median mpeg1enc mpeg1sys mpeg1videoparse mpeg2enc mpeg2sub\
+        mpegaudio mpegaudioparse mpegstream mpegtypes modplug\
+        monoscope passthrough playondemand rtjpeg silence sine\
         smooth spectrum speed stereo stereomono\
         synaesthesia udp videoscale volenv volume vumeter wavparse y4m"
 
@@ -309,26 +191,17 @@ AC_ARG_WITH(plugins,
 
 AC_SUBST(GST_PLUGINS_SELECTED)
 
-dnl needed for smoothwave, FIXME!
-if test x$USE_GLIB2 = xno; then
-  AM_PATH_GTK(1.2.0,,
-              AC_MSG_ERROR(Cannot find gtk: Is gtk-config in path?))
-  HAVE_GTK=yes
-  # we have to have it
-else
-  PKG_CHECK_MODULES(GTK2, gtk+-2.0, HAVE_GTK=yes, HAVE_GTK=no)
-
-  GTK_CFLAGS=$GTK2_CFLAGS
-  GTK_LIBS=$GTK2_LIBS
-fi
-AC_SUBST(GTK_LIBS)
-AC_SUBST(GTK_CFLAGS)
-
 dnl ==========================================================================
 dnl ============================= sys plugins ================================
 dnl ==========================================================================
 
 
+dnl *** DXR3 card ***
+translit(dnm, m, l) AM_CONDITIONAL(USE_DXR3, true)
+GST_CHECK_FEATURE(DXR3, [DXR3 hardware mpeg video decoder], dxr3videosink, [
+  AC_CHECK_HEADER(linux/em8300.h, HAVE_DXR3="yes", HAVE_DXR3="no")
+])
+
 dnl *** OSS audio ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_OSS, true)
 GST_CHECK_FEATURE(OSS, [OSS audio], osssrc osssink, [
@@ -337,12 +210,21 @@ GST_CHECK_FEATURE(OSS, [OSS audio], osssrc osssink, [
 
 dnl *** QuickCam ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_QCAM, true)
-GST_CHECK_FEATURE(QCAM, [QuickCam], qcamsrc, HAVE_QCAM="yes")
+GST_CHECK_FEATURE(QCAM, [QuickCam], qcamsrc, [
+dnl this one is for hadess, no qcam when no nasm found
+  if test "x$HAVE_NASM" = "xno";
+  then
+    HAVE_QCAM="no"
+    AC_MSG_WARN([QuickCam needs nasm])
+  else
+    HAVE_QCAM="yes"
+  fi
+])
 
 dnl *** Video 4 Linux ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_V4L, true)
-GST_CHECK_FEATURE(V4L, [Video 4 Linux], v4lsrc, [
-  AC_CHECK_HEADER(linux/videodev.h, HAVE_V4L="yes", HAVE_V4L="no")
+GST_CHECK_FEATURE(V4L, [Video 4 Linux], v4lsrc v4lmjpegsrc v4lmjpegsink, [
+  AC_CHECK_DECL(VID_TYPE_MPEG_ENCODER, HAVE_V4L="yes", HAVE_V4L="no", [#include <linux/videodev.h>])
 ])
 
 dnl *** Video CD ***
@@ -358,13 +240,27 @@ GST_CHECK_FEATURE(VGA, [VGA], vgavideosink, [
 ])
 
 dnl *** XVideo ***
-dnl look for the PIC library first, debian likes it
-dnl yeah but redhat doesn't even *have* it and it works fine without
-dnl GST_CHECK_LIBHEADER(XVIDEO, Xv_pic, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h)
+dnl Look for the PIC library first, Debian requires it.
+dnl Check debian-devel archives for gory details.
+dnl 20020110:
+dnl At the moment XFree86 doesn't distribute shared libXv due
+dnl to unstable API.  On many platforms you CAN NOT link a shared
+dnl lib to a static non-PIC lib.  This is what the xvideo GStreamer
+dnl plugin wants to do.  So Debian distributes a PIC compiled
+dnl version of the static lib for plugins to link to when it is
+dnl inappropriate to link the main application to libXv directly.
+dnl FIXME: add check if this platform can support linking to a
+dnl        non-PIC libXv, if not then don not use Xv.
+dnl FIXME: perhaps warn user if they have a shared libXv since
+dnl        this is an error until XFree86 starts shipping one
 translit(dnm, m, l) AM_CONDITIONAL(USE_XVIDEO, true)
-GST_CHECK_FEATURE(XVIDEO, [X11 XVideo extensions], xvideosink, [
-  GST_CHECK_LIBHEADER(XVIDEO, Xv, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h)
-  XVIDEO_LIBS="-lXv -lXext"
+GST_CHECK_FEATURE(XVIDEO, [X11 XVideo extensions], xvideosink videosink, [
+  dnl check for PIC static lib
+  GST_CHECK_LIBHEADER(XVIDEO, Xv_pic, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h, XVIDEO_LIBS="-lXv_pic -lXext")
+  if test x$HAVE_XVIDEO = xno; then
+    dnl PIC lib not found, check for regular lib
+    GST_CHECK_LIBHEADER(XVIDEO, Xv, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h, XVIDEO_LIBS="-lXv -lXext")
+  fi
   AC_SUBST(XVIDEO_LIBS)
 ])
 
@@ -380,7 +276,7 @@ AC_MSG_NOTICE(Checking for plugin libraries)
 dnl *** a52dec ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_A52DEC, true)
 GST_CHECK_FEATURE(A52DEC, [a52dec], a52dec, [
-  GST_CHECK_LIBHEADER(A52DEC, a52, a52_init, -lm, a52dec/a52.h, A52DEC_LIBS="-la52")
+  AC_CHECK_A52DEC(HAVE_A52DEC=yes, HAVE_A52DEC=no)
 ])
 
 dnl *** aalib ***
@@ -396,10 +292,24 @@ GST_CHECK_FEATURE(ALSA, [alsa plugins], gstalsa, [
 ])
 
 dnl *** arts ***
+
+dnl if mcopidl can't be found there's no use in compiling it
+AC_CHECK_PROG(MCOPIDL, mcopidl, yes, no)
+if test "xHAVE_MCOPIDL" = "xno";
+then
+  USE_ARTS=no
+fi
+
 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTS, true)
 GST_CHECK_FEATURE(ARTS, [arts plugins], arts, [
   AM_PATH_ARTS(, HAVE_ARTS=yes, HAVE_ARTS=no)
 ])
+dnl if mcopidl can't be found there's no use in compiling it
+AC_PATH_PROG(MCOPIDL, mcopidl, yes, no)
+if test "xHAVE_MCOPIDL" = "xno";
+then
+  USE_ARTS=NO
+fi
 
 dnl *** artsc ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTSC, true)
@@ -431,7 +341,7 @@ GST_CHECK_FEATURE(AVIFILE, [avifile], windec winenc, [
 dnl *** CDParanoia ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_CDPARANOIA, true)
 GST_CHECK_FEATURE(CDPARANOIA, [CDParanoia], cdparanoia, [
-  GST_CHECK_LIBHEADER(CDPARANOIA, cdda_interface, cdda_open, , cdda_interface.h, CDPARANOIA_LIBS="-lcdda_interface -lcdda_paranoia")
+  GST_CHECK_LIBHEADER(CDPARANOIA, cdda_interface, cdda_open, -lm, cdda_interface.h, CDPARANOIA_LIBS="-lcdda_interface -lcdda_paranoia")
   AC_SUBST(CDPARANOIA_LIBS)
 ])
 dnl FIXME : add second check somehow if that is necessary
@@ -439,10 +349,9 @@ dnl AC_CHECK_LIB(cdda_paranoia, paranoia_init, : , HAVE_CDPARANOIA=no, -lcdda_in
 dnl AC_CHECK_HEADER(cdda_paranoia.h, :, HAVE_CDPARANOIA=no)
 
 dnl *** dv ***
-dnl FIXME : check if those GLIB thingies are ok
 translit(dnm, m, l) AM_CONDITIONAL(USE_DV, true)
 GST_CHECK_FEATURE(DV, [dv library], dv, [
-  GST_CHECK_LIBHEADER(DV, dv, dv_init, -lm $GLIB_LIBS $GLIB_CFLAGS, libdv/dv.h, DV_LIBS="-ldv")
+  GST_CHECK_LIBHEADER(DV, dv, dv_init, -lm $GST_CFLAGS $GST_LIBS, libdv/dv.h, DV_LIBS="-ldv")
   AC_SUBST(DV_LIBS)
 ])
 
@@ -455,32 +364,52 @@ GST_CHECK_FEATURE(DVDREAD, [dvdread library], dvdsrc, [
 
 dnl **** ESound ****
 translit(dnm, m, l) AM_CONDITIONAL(USE_ESD, true)
-GST_CHECK_FEATURE(ESD, [esound plugins], esdsrc esdsink, [
+GST_CHECK_FEATURE(ESD, [esound plugins], esdsink esdmon, [
   AM_PATH_ESD(0.2.12, HAVE_ESD=yes, HAVE_ESD=no)
 ])
 
+dnl **** festival ****
+translit(dnm, m, l) AM_CONDITIONAL(USE_FESTIVAL, true)
+GST_CHECK_FEATURE(FESTIVAL, [festival plugins], festivalsrc, [
+  dnl NOTE: just using local net connection now, add this lib check
+  dnl       in the future if needed
+  dnl AC_LANG_PUSH(C++)
+  dnl dnl FIXME: took out func to check for
+  dnl dnl This check puts festival_tidy_up in extern "C".
+  dnl dnl But, at least on Debian as of 20020110, it is compiled with name
+  dnl dnl mangling C++ nonsense and symbols can't resolve
+  dnl dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, festival_tidy_up, , festival/festival.h, FESTIVAL_LIBS="-lFestival")
+  dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, , , festival/festival.h, FESTIVAL_LIBS="-lFestival")
+  dnl AC_LANG_POP(C++)
+  dnl AC_SUBST(FESTIVAL_LIBS)
+  HAVE_FESTIVAL=yes
+])
+
 dnl *** FLAC ***
-dnl thomas : checking for compile with main instead of actual function,
-dnl since that made autoconf break (for version 2.13)
 translit(dnm, m, l) AM_CONDITIONAL(USE_FLAC, true)
 GST_CHECK_FEATURE(FLAC, [FLAC lossless audio], flacenc flacdec, [
-  GST_CHECK_LIBHEADER(FLAC, FLAC, main, -lm, FLAC/all.h, FLAC_LIBS="-lFLAC")
+  GST_CHECK_LIBHEADER(FLAC, FLAC, FLAC__stream_decoder_new, -lm, FLAC/all.h, FLAC_LIBS="-lFLAC")
   AC_SUBST(FLAC_LIBS)
 ])
 
 dnl *** Gnome VFS ***
-dnl this check uses the GST_CHECK_CONFIGPROG macro with gnome-config vfs
 translit(dnm, m, l) AM_CONDITIONAL(USE_GNOME_VFS, true)
 GST_CHECK_FEATURE(GNOME_VFS, [Gnome VFS], gnomevfssrc, [
-translit(dnm, m, l) AC_SUBST(GNOME_VFS_LIBS)
-translit(dnm, m, l) AC_SUBST(GNOME_VFS_CFLAGS)
-GST_CHECK_CONFIGPROG(GNOME_VFS, gnome-config vfs)
+  PKG_CHECK_MODULES(GNOME_VFS, gnome-vfs-2.0, HAVE_GNOME_VFS="yes", HAVE_GNOME_VFS="no")
+  AC_SUBST(GNOME_VFS_CFLAGS)
+  AC_SUBST(GNOME_VFS_LIBS)
 ])
 
 dnl *** gsm ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_GSM, true)
 GST_CHECK_FEATURE(GSM, [GSM library], gsmenc gsmdec, [
-  GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm/gsm.h, GSM_LIBS="-lgsm")
+  GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm.h, GSM_LIBS="-lgsm")
+  if test $HAVE_GSM != "yes"; then
+    GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm/gsm.h, GSM_LIBS="-lgsm")
+    if test $HAVE_GSM = "yes"; then 
+      AC_DEFINE(GSM_HEADER_IN_SUBDIR, 1, [Define if GSM header in gsm/ subdir])
+    fi
+  fi
   AC_SUBST(GSM_LIBS)
 ])
 
@@ -509,34 +438,57 @@ GST_CHECK_FEATURE(HTTP, [http plugins], gsthttpsrc, [
   AC_SUBST(GST_HTTPSRC_GET_TYPE)
 ])
 
+dnl *** Jack ***
+translit(dnm, m, l) AM_CONDITIONAL(USE_JACK, true)
+GST_CHECK_FEATURE(JACK, Jack, jack, [
+  PKG_CHECK_MODULES(JACK, jack, HAVE_JACK="yes", HAVE_JACK="no")
+  AC_SUBST(JACK_CFLAGS)
+  AC_SUBST(JACK_LIBS)
+])
+
+dnl *** jpeg ***
+dnl FIXME: we could use header checks here as well IMO
+translit(dnm, m, l) AM_CONDITIONAL(USE_JPEG, true)
+GST_CHECK_FEATURE(JPEG, [jpeg], jpegenc jpegdec, [
+  AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
+  JPEG_LIBS="-ljpeg"
+  AC_SUBST(JPEG_LIBS)
+])
+
 dnl *** lame ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_LAME, true)
 GST_CHECK_FEATURE(LAME, [lame mp3 encoder library], lame, [
-GST_CHECK_LIBHEADER(LAME, mp3lame, lame_init, -lm, lame/lame.h, LAME_LIBS="-lmp3lame")
+GST_CHECK_LIBHEADER(LAME, mp3lame, lame_init, -lm, lame/lame.h, HAVE_LAME="yes" LAME_LIBS="-lmp3lame")
 ])
 AC_SUBST(LAME_LIBS)
 
+dnl *** libcolorspace ***
+translit(dnm, m, l) AM_CONDITIONAL(USE_LCS, true)
+GST_CHECK_FEATURE(LCS, Lcs, lcs, [
+  PKG_CHECK_MODULES(LCS, lcs, HAVE_LCS="yes", HAVE_LCS="no")
+  AC_SUBST(LCS_CFLAGS)
+  AC_SUBST(LCS_LIBS)
+])
 
 dnl FIXME : check if these CPP flags can be dealt with otherwise
 dnl libdvcheck_save_CPPFLAGS="$CPPFLAGS"
-dnl CPPFLAGS="$CPPFLAGS $GLIB_CFLAGS"
+dnl CPPFLAGS="$CPPFLAGS $GST_CFLAGS"
 dnl AC_CHECK_HEADER(libdv/dv.h, :, HAVE_LIBDV=no)
 dnl CPPFLAGS="$libdvcheck_save_CPPFLAGS"
 
-dnl *** jpeg ***
-dnl FIXME: we could use header checks here as well IMO
-translit(dnm, m, l) AM_CONDITIONAL(USE_JPEG, true)
-GST_CHECK_FEATURE(JPEG, [jpeg], jpegenc jpegdec, [
-  AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
-  JPEG_LIBS="-ljpeg"
-  AC_SUBST(JPEG_LIBS)
-])
-
 dnl *** mad ***
 dnl FIXME: we could use header checks here as well IMO
 translit(dnm, m, l) AM_CONDITIONAL(USE_MAD, true)
 GST_CHECK_FEATURE(MAD, [mad mp3 decoder], mad, [
   AC_CHECK_LIB(mad, mad_decoder_finish, HAVE_MAD="yes" MAD_LIBS="-lmad")
+  if test "x$HAVE_MAD" = "xyes"; then
+    # installed with mad >= 0.14
+    HAVE_MAD="no"
+    save_libs=$LIBS
+    LIBS="-lz"
+    AC_CHECK_LIB(id3tag, id3_tag_query, HAVE_MAD="yes" MAD_LIBS="$MAD_LIBS -lid3tag")
+    LIBS=$save_LIBS
+  fi    
 ])
 AC_SUBST(MAD_LIBS)
 
@@ -548,11 +500,18 @@ GST_CHECK_FEATURE(MIKMOD, [mikmod plugin], mikmod, [
   AC_SUBST(MIKMOD_CFLAGS, "$LIBMIKMODCFLAGS")
 ])
 
+dnl *** mjpegtools ***
+translit(dnm, m, l) AM_CONDITIONAL(USE_MJPEGTOOLS, true)
+GST_CHECK_FEATURE(MJPEGTOOLS, [mjpegtools], jpegmmxenc jpegmmxdec, [
+  PKG_CHECK_MODULES(MJPEGTOOLS, mjpegtools, HAVE_MJPEGTOOLS="yes", HAVE_MJPEGTOOLS="no")
+  AC_SUBST(MJPEGTOOLS_LIBS)
+  AC_SUBST(MJPEGTOOLS_CFLAGS)
+])
+
 dnl *** mpeg2dec ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_MPEG2DEC, true)
 GST_CHECK_FEATURE(MPEG2DEC, [mpeg2dec], mpeg2dec, [
-  GST_CHECK_LIBHEADER(MPEG2DEC, mpeg2, mpeg2_init,, mpeg2dec/mpeg2.h, MPEG2DEC_LIBS="-lmpeg2 -lmpeg2dec")
-  AC_SUBST(MPEG2DEC_LIBS)
+  AC_CHECK_MPEG2DEC(HAVE_MPEG2DEC=yes, HAVE_MPEG2DEC=no)
 ])
 
 dnl *** openquicktime ***
@@ -565,7 +524,7 @@ GST_CHECK_FEATURE(OPENQUICKTIME, [Open Quicktime], quicktime_parser quicktime_de
 dnl *** raw1394 ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_RAW1394, true)
 GST_CHECK_FEATURE(RAW1394, [raw1394 library], dv1394src, [
-  GST_CHECK_LIBHEADER(RAW1394, raw1934, raw1934_get_handle,, libraw1394/raw1394.h, RAW1394_LIBS="-raw1394")
+  GST_CHECK_LIBHEADER(RAW1394, raw1394, raw1394_get_handle,, libraw1394/raw1394.h, RAW1394_LIBS="-raw1394")
   AC_SUBST(RAW1394_LIBS)
 ])
 
@@ -573,13 +532,13 @@ dnl *** rtp ***
 dnl FIXME : adapt and make it work
 translit(dnm, m, l) AM_CONDITIONAL(USE_RTP, true)
 GST_CHECK_FEATURE(RTP, [RTP library], rtpenc rtpdec,[
-  AC_CHECK_LIB(rtp, rtp_packet_new_take_data, HAVE_RTP=yes, HAVE_RTP=no, $GLIB_LIBS $GLIB_CFLAGS)
+  AC_CHECK_LIB(rtp, rtp_packet_new_take_data, HAVE_RTP=yes, HAVE_RTP=no, $GST_CFLAGS $GST_LIBS)
   RTP_LIBS="-lrtp"
   AC_SUBST(RTP_LIBS)
 ])
 
-
 dnl FIXME header check needs to use GLIB_CFLAGS in order to succeed for rtp
+dnl can use GST_* which should have GLIB_* info
 dnl AC_CHECK_HEADERS(rtp/rtp.h, HAVE_LIBRTP=yes, HAVE_LIBRTP=no)
 dnl AC_CHECK_HEADERS(rtp/rtp-packet.h, :, HAVE_LIBRTP=no)
 dnl AC_CHECK_HEADERS(rtp/rtcp-packet.h, :, HAVE_LIBRTP=no)
@@ -598,16 +557,25 @@ GST_CHECK_FEATURE(SHOUT, [shout plugin], icecastsend, [
   AC_SUBST(SHOUT_LIBS)
 ])
 
+dnl *** sidplay ***
+translit(dnm, m, l) AM_CONDITIONAL(USE_SIDPLAY, true)
+GST_CHECK_FEATURE(SIDPLAY, [sidplay plugin], sidplay, [
+  GST_PATH_SIDPLAY()
+])
+
 dnl *** smoothwave ***
 translit(dnm, m, l) AM_CONDITIONAL(USE_SMOOTHWAVE, true)
 GST_CHECK_FEATURE(SMOOTHWAVE, [smoothwave plugin], smoothwave, [
   if test $HAVE_GTK = "yes"; then HAVE_SMOOTHWAVE=yes; fi;
 ])
 
-dnl for sidplay
-dnl FIXME : make this work
-dnl AC_PATH_LIBSIDPLAY
-
+dnl *** tarkin ***
+dnl for now the sources are included in the plugin
+dnl and should be moved to ext-libs/ perhaps
+translit(dnm, m, l) AM_CONDITIONAL(USE_TARKIN, true)
+GST_CHECK_FEATURE(TARKIN, [tarkinenc tarkindec], tarkin, [
+  HAVE_TARKIN="yes"
+])
 
 dnl *** vorbis ***
 dnl AM_PATH_VORBIS only takes two options
@@ -648,6 +616,8 @@ dnl ######################################################################
 dnl # Check command line parameters, and set shell variables accordingly #
 dnl ######################################################################
 
+GST_DEBUGINFO
+
 AC_ARG_ENABLE(libmmx,
 [  --enable-libmmx              use libmmx, if available],
 [case "${enableval}" in
@@ -667,60 +637,6 @@ AC_ARG_ENABLE(atomic,
 esac], 
 [USE_ATOMIC_H=$HAVE_ATOMIC_H]) dnl Default value
 
-AC_ARG_ENABLE(plugin-builddir,
-[  --enable-plugin-builddir     allow tests/demos to use non-installed plugins ],
-[case "${enableval}" in
-  yes) PLUGINS_USE_BUILDDIR=yes ;;
-  no)  PLUGINS_USE_BUILDDIR=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-plugin-builddir) ;;
-esac], 
-[PLUGINS_USE_BUILDDIR=no]) dnl Default value
-
-AC_ARG_ENABLE(debug,
-[  --enable-debug               compile with -g debugging info],
-[case "${enableval}" in
-  yes) USE_DEBUG=yes ;;
-  no)  USE_DEBUG=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-debug) ;;
-esac], 
-[USE_DEBUG=no]) dnl Default value
-
-AC_ARG_ENABLE(DEBUG,
-[  --enable-DEBUG               compiles in a large number of debugging messages],
-[case "${enableval}" in
-  yes) ENABLE_DEBUG=yes ;;
-  no)  ENABLE_DEBUG=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-DEBUG) ;;
-esac], 
-[ENABLE_DEBUG=no]) dnl Default value
-if test x$ENABLE_DEBUG = xyes; then
-  AC_DEFINE(GST_DEBUG_ENABLED, 1, [Define if DEBUG statements should be compiled in])
-fi
-
-AC_ARG_ENABLE(INFO,
-[  --disable-INFO               disables compilation of informational messages],
-[case "${enableval}" in
-  yes) ENABLE_INFO=yes ;;
-  no)  ENABLE_INFO=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-INFO) ;;
-esac], 
-[ENABLE_INFO=yes]) dnl Default value
-if test x$ENABLE_INFO = xyes; then
-  AC_DEFINE(GST_INFO_ENABLED, 1, [Define if INFO statements should be compiled in])
-fi
-
-AC_ARG_ENABLE(debug-color,
-[  --disable-debug-color        disables color output of DEBUG and INFO output],
-[case "${enableval}" in
-  yes) ENABLE_DEBUG_COLOR=yes ;;
-  no)  ENABLE_DEBUG_COLOR=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-debug-color) ;;
-esac], 
-[ENABLE_DEBUG_COLOR=yes]) dnl Default value
-if test "x$ENABLE_DEBUG_COLOR" = xyes; then
-  AC_DEFINE(GST_DEBUG_COLOR, 1, [Define if debugging messages should be colorized])
-fi
-
 AC_ARG_ENABLE(profiling,
 [  --enable-profiling           adds -pg to compiler commandline, for profiling],
 [case "${enableval}" in
@@ -730,51 +646,6 @@ AC_ARG_ENABLE(profiling,
 esac], 
 [USE_PROFILING=no]) dnl Default value
 
-dnl default to building registry in the source tree if we are enabling plugin build dir
-if test "x$PLUGINS_USE_BUILDDIR"="xyes"; then
-  GST_CONFIG_DIR=`pwd`
-else
-  GST_CONFIG_DIR=/etc/gstreamer
-fi
-AC_ARG_WITH(configdir,
-[  --with-configdir             specify path to use for configdir],
-[case "${withval}" in
-  yes) AC_MSG_ERROR(bad value ${withval} for --with-configdir) ;;
-  no) AC_MSG_ERROR(bad value ${withval} for --with-configdir) ;;
-  *) GST_CONFIG_DIR="${withval}" ;;
-esac], 
-[:]) dnl Default value
-
-dnl Default value
-GST_WIN32_LIBDIR="/usr/lib/win32"
-AC_ARG_WITH(win32_libdir,
-[  --with-win32-libdir          specify location for win32 DLLs],
-[case "${withval}" in
-  yes) AC_MSG_ERROR(bad value ${withval} for --with-win32-libdir) ;;
-  no) AC_MSG_ERROR(bad value ${withval} for --with-win32-libdir) ;;
-  *) GST_WIN32_LIBDIR="${withval}" ;;
-esac],
-[:]) dnl Default value
-
-AC_ARG_ENABLE(docs-build,
-[  --enable-docs-build          enable building of documentation],
-[case "${enableval}" in
-  yes) if $HAVE_GTK_DOC; then BUILD_DOCS=yes; else AC_MSG_ERROR([you don't have gtk-doc, so don't use --docs-build]); fi; ;;
-  no)  BUILD_DOCS=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-docs-build) ;;
-esac], 
-[BUILD_DOCS=no]) dnl Default value
-
-AC_ARG_ENABLE(plugin-docs,
-[  --enable-plugin-docs         enable the building of plugin documentation
-                               (this is currently broken, so off by default)],
-[case "${enableval}" in
-  yes) BUILD_PLUGIN_DOCS=yes ;;
-  no)  BUILD_PLUGIN_DOCS=no ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-plugin-docs) ;;
-esac], 
-[BUILD_PLUGIN_DOCS=no]) dnl Default value
-
 AC_ARG_ENABLE(tests,
 [  --disable-tests              disable building test apps],
 [case "${enableval}" in
@@ -793,47 +664,6 @@ AC_ARG_ENABLE(examples,
 esac], 
 [BUILD_EXAMPLES=yes]) dnl Default value
 
-dnl Next, check for the optional components:
-dnl ========================================
-
-
-AC_DEFUN(GST_SUBSYSTEM_DISABLE,
-[dnl
-dnl Add a subsystem --disable flag and all the necessary symbols and substitions
-dnl
-AC_ARG_ENABLE(translit([$1], A-Z, a-z), 
-[  ]builtin(format, --disable-%-17s  disable %s, translit([$1], A-Z, a-z), $2),
-[ case "${enableval}" in
-    yes) GST_DISABLE_[$1]=no ;;
-    no) GST_DISABLE_[$1]=yes ;;
-    *) AC_MSG_ERROR(bad value ${enableval} for --enable-translit([$1], A-Z, a-z)) ;;
-  esac],
-[GST_DISABLE_[$1]=no]) dnl Default value
-if test x$GST_DISABLE_[$1] = xyes; then
-  AC_DEFINE(GST_DISABLE_[$1], 1, [Disable $2])
-  GST_DISABLE_[$1]_DEFINE=-DGST_DISABLE_[$1]
-fi
-AM_CONDITIONAL(GST_DISABLE_[$1], test x$GST_DISABLE_[$1] = xyes)
-AC_SUBST(GST_DISABLE_[$1]_DEFINE)
-GST_SUBSYSTEM_DISABLE_DEFINES="$GST_SUBSYTEM_DISABLE_DEFINES $GST_DISABLE_[$1]_DEFINE"
-])
-
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_LOADSAVE, true)
-GST_SUBSYSTEM_DISABLE(LOADSAVE,[pipeline XML load/save])
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_TYPEFIND, true)
-GST_SUBSYSTEM_DISABLE(TYPEFIND,[typefind plugin],)
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_AUTOPLUG, true)
-GST_SUBSYSTEM_DISABLE(AUTOPLUG,[autoplugger subsystem])
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_PARSE, true)
-GST_SUBSYSTEM_DISABLE(PARSE,[command-line parser])
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_TRACE, true)
-GST_SUBSYSTEM_DISABLE(TRACE,[tracing subsystem])
-translit(dnm, m, l) AM_CONDITIONAL(GST_DISABLE_REGISTRY, true)
-GST_SUBSYSTEM_DISABLE(REGISTRY,[plugin registry])
-
-GST_CFLAGS="$GST_CFLAGS $GST_SUBSYSTEM_DISABLE_DEFINES"
-
-
 dnl ################################################
 dnl # Set defines according to variables set above #
 dnl ################################################
@@ -847,10 +677,6 @@ if test "x$USE_ATOMIC_H" = xyes; then
   AC_DEFINE(HAVE_ATOMIC_H, 1, [Define if atomic.h header file is available])
 fi
 
-if test "x$PLUGINS_USE_BUILDDIR" = xyes; then
-  AC_DEFINE(PLUGINS_USE_BUILDDIR, 1, [Define if plugins should be loaded from the build tree - only developers should use this])
-fi
-
 dnl if test "x$USE_DEBUG" = xyes; then
 dnl   CFLAGS="$CFLAGS -g"
 dnl fi
@@ -866,14 +692,6 @@ dnl
 dnl AC_SUBST(FOMIT_FRAME_POINTER)
 dnl
 
-if test "x$HAVE_LIBMIKMOD" = xyes; then
-  AC_DEFINE(HAVE_LIBMIKMOD)
-fi
-
-if test "x$HAVE_LIBGSM" = xyes; then
-  AC_DEFINE(HAVE_LIBGSM)
-fi
-
 dnl #############################
 dnl # Set automake conditionals #
 dnl #############################
@@ -892,8 +710,6 @@ AM_CONDITIONAL(HAVE_ATOMIC_H,       test "x$USE_ATOMIC_H" = "xyes")
 AM_CONDITIONAL(EXPERIMENTAL,        test "$EXPERIMENTAL" = "$xyes")
 AM_CONDITIONAL(BROKEN,              test "$BROKEN" = "$xyes")
 
-AM_CONDITIONAL(HAVE_LIBMIKMOD,      test "x$HAVE_LIBMIKMOD" = "xyes")
-AM_CONDITIONAL(HAVE_LIBSDL,         test "x$HAVE_LIBSDL" = "xyes")
 AM_CONDITIONAL(HAVE_NASM,           test "x$HAVE_NASM" = "xyes")
 AM_CONDITIONAL(HAVE_LIBGLADE_GNOME, test "x$HAVE_LIBGLADE_GNOME" = "xyes")
 AM_CONDITIONAL(HAVE_GNOME,          test "x$HAVE_GNOME" = "xyes")
@@ -903,103 +719,25 @@ AM_CONDITIONAL(BUILD_DOCS,          test "x$BUILD_DOCS" = "xyes")
 AM_CONDITIONAL(BUILD_TESTS,         test "x$BUILD_TESTS" = "xyes")
 AM_CONDITIONAL(BUILD_EXAMPLES,      test "x$BUILD_EXAMPLES" = "xyes")
 AM_CONDITIONAL(BUILD_PLUGIN_DOCS,   test "x$BUILD_PLUGIN_DOCS" = "xyes")
-AM_CONDITIONAL(HAVE_PDFXMLTEX,      $HAVE_PDFXMLTEX)
-AM_CONDITIONAL(HAVE_PDFTOPS,        $HAVE_PDFTOPS)
-AM_CONDITIONAL(HAVE_XSLTPROC,       $HAVE_XSLTPROC)
 AM_CONDITIONAL(HAVE_FIG2DEV_PNG,    $HAVE_FIG2DEV_PNG)
 AM_CONDITIONAL(HAVE_FIG2DEV_PDF,    $HAVE_FIG2DEV_PDF)
-AM_CONDITIONAL(HAVE_LIBRTP,         test "x$HAVE_LIBRTP" = "xyes")
-AM_CONDITIONAL(HAVE_ARTS,           test "x$HAVE_ARTS" = "xyes")
 AM_CONDITIONAL(HAVE_RAW1394,        test "x$HAVE_RAW1394" = "xyes")
-AM_CONDITIONAL(HAVE_LIBDV,          test "x$HAVE_LIBDV" = "xyes")
-AM_CONDITIONAL(HAVE_GNOME_VFS,      test "x$HAVE_GNOME_VFS" = "xyes")
-AM_CONDITIONAL(HAVE_LIBGSM,         test "x$HAVE_LIBGSM" = "xyes")
-AM_CONDITIONAL(PLUGINS_USE_BUILDDIR,  test "x$PLUGINS_USE_BUILDDIR" = "xyes")
-AM_CONDITIONAL(HAVE_SIDPLAY,        test "x$have_sidplay" = "xyes")
 
-
-dnl ############################
-dnl # Set up some more defines #
-dnl ############################
-
-dnl Set location of configuration dir.
-AC_DEFINE_UNQUOTED(GST_CONFIG_DIR,"$GST_CONFIG_DIR")
-AC_SUBST(GST_CONFIG_DIR)
-
-dnl Set location of windows dll dir.
-AC_DEFINE_UNQUOTED(GST_WIN32_LIBDIR,"$GST_WIN32_LIBDIR")
-AC_SUBST(GST_WIN32_LIBDIR)
-
-dnl Set location of plugin directory
-if test "x${prefix}" = "xNONE"; then
-  PLUGINS_DIR=${ac_default_prefix}/lib/gst
-else
-  PLUGINS_DIR=${prefix}/lib/gst
-fi
-AC_DEFINE_UNQUOTED(PLUGINS_DIR,"$PLUGINS_DIR")
-AC_SUBST(PLUGINS_DIR)
-
-dnl Set location of uninstalled plugin directory
-PLUGINS_BUILDDIR=`pwd`
-AC_DEFINE_UNQUOTED(PLUGINS_BUILDDIR,"$PLUGINS_BUILDDIR")
-AC_SUBST(PLUGINS_BUILDDIR)
-
-dnl Private vars for libgst only
-LIBGST_LIBS="$GST_LIBS $XML_LIBS $GLIB_LIBS"
-LIBGST_CFLAGS="$GST_CFLAGS $XML_CFLAGS $GLIB_CFLAGS"
-AC_SUBST(LIBGST_LIBS)
-AC_SUBST(LIBGST_CFLAGS)
-
-dnl Vars for everyone else
-dnl FIXME: is there a reason to add this top_builddir stuff ? don't think so
-dnl GST_LIBS="\$(top_builddir)/gst/libgst.la $LIBGST_LIBS"
-dnl GST_CFLAGS="-I\$(top_srcdir) -I\$(top_srcdir)/include $LIBGST_CFLAGS"
-GST_CFLAGS="$GST_CFLAGS -I\$(top_srcdir)/gst-libs"
+GST_CFLAGS="$GST_CFLAGS -I\$(top_srcdir)/gst-libs -Wall -Werror"
 AC_SUBST(GST_LIBS)
 AC_SUBST(GST_CFLAGS)
 
-dnl #############################
-dnl # Configure the subpackages #
-dnl #############################
-
-dnl AC_CONFIG_SUBDIRS(gist)
-dnl AC_CONFIG_SUBDIRS(plugins/mp3decode/xing/libxing)
-
-dnl ##################################################
-dnl # Prepare informative messages to display at end #
-dnl ##################################################
-
-infomessages=
-
-if test "x$PLUGINS_USE_BUILDDIR" = xyes; then
-  infomessages="$infomessages
-*** Warning: You have configured using the --enable-plugin-builddir option.
-
-This option is for development purposes only: binaries built with
-it should be used with code in the build tree only.  To build an
-installable version, use ./configure without the --enable-plugin-builddir
-option.  Note that the autogen.sh script supplies the plugin builddir
-option automatically - it cannot be used to configure installable builds.
-
-"
-fi
-
 dnl #########################
 dnl # Make the output files #
 dnl #########################
 
-dnl gstreamer.pc
-dnl gstreamer-uninstalled.pc
-dnl gstreamer.spec,
-dnl until ffmpeg is handled by configure plugins/ffmpeg/Makefile
-dnl components/bonobo-gstmediaplay/Makefile
-dnl someone should fix this test/misc/Makefile
-dnl wtay fix this: testsuite/threads/Makefile
-dnl testsuite/refcounting/Makefile
-dnl stamp.h
-dnl echo "$infomessages", infomessages="$infomessages"
-AC_OUTPUT(
+dnl testsuite/autoplug/Makefile
+dnl testsuite/Makefile
+AC_CONFIG_FILES(
 Makefile
+gstreamer-libs.pc
+gstreamer-libs-uninstalled.pc
+gst-plugins.spec
 gst/Makefile
 gst/ac3parse/Makefile
 gst/adder/Makefile
@@ -1010,18 +748,23 @@ gst/chart/Makefile
 gst/cutter/Makefile
 gst/deinterlace/Makefile
 gst/flx/Makefile
+gst/goom/Makefile
 gst/intfloat/Makefile
 gst/law/Makefile
 gst/level/Makefile
 gst/median/Makefile
 gst/mpeg1enc/Makefile
 gst/mpeg1sys/Makefile
+gst/mpeg1videoparse/Makefile
 gst/mpeg2enc/Makefile
 gst/mpeg2sub/Makefile
 gst/mpegaudio/Makefile
 gst/mpegaudioparse/Makefile
 gst/mpegstream/Makefile
 gst/mpegtypes/Makefile
+gst/modplug/Makefile
+gst/modplug/libmodplug/Makefile
+gst/monoscope/Makefile
 gst/passthrough/Makefile
 gst/playondemand/Makefile
 gst/rtjpeg/Makefile
@@ -1041,12 +784,14 @@ gst/vumeter/Makefile
 gst/wavparse/Makefile
 gst/y4m/Makefile
 sys/Makefile
+sys/dxr3/Makefile
 sys/oss/Makefile
 sys/qcam/Makefile
 sys/v4l/Makefile
 sys/vcd/Makefile
 sys/vga/Makefile
 sys/xvideo/Makefile
+sys/videosink/Makefile
 ext/Makefile
 ext/a52dec/Makefile
 ext/aalib/Makefile
@@ -1065,11 +810,14 @@ ext/gnomevfs/Makefile
 ext/gsm/Makefile
 ext/hermes/Makefile
 ext/http/Makefile
+ext/jack/Makefile
 ext/jpeg/Makefile
+ext/lcs/Makefile
 ext/ladspa/Makefile
 ext/lame/Makefile
 ext/mad/Makefile
 ext/mikmod/Makefile
+ext/mjpegtools/Makefile
 ext/mpeg2dec/Makefile
 ext/openquicktime/Makefile
 ext/raw1394/Makefile
@@ -1077,8 +825,9 @@ ext/rtp/Makefile
 ext/sdl/Makefile
 ext/shout/Makefile
 ext/sidplay/Makefile
-ext/smooothwave/Makefile
+ext/smoothwave/Makefile
 ext/vorbis/Makefile
+ext/tarkin/Makefile
 ext/xmms/Makefile
 gst-libs/Makefile
 gst-libs/gst/Makefile
@@ -1086,9 +835,13 @@ gst-libs/gst/audio/Makefile
 gst-libs/gst/idct/Makefile
 gst-libs/gst/resample/Makefile
 gst-libs/gst/riff/Makefile
-gst-plugins.spec
+examples/capsfilter/Makefile
+examples/Makefile
+tools/Makefile
 )
 
+AC_OUTPUT
+
 echo -e "configure: *** Plugins that will be built : $GST_PLUGINS_YES"
 echo
 echo -e "configure: *** Plugins that will not be built : $GST_PLUGINS_NO"