1 dnl autoconf configuration file for gst-plugins
3 AC_CANONICAL_TARGET([])
5 dnl We disable static building for development, for time savings
6 dnl this goes before AS_LIBTOOL to appease autoconf
7 dnl *NOTE*: dnl this line before release, so release does static too
10 dnl when going to/from release please set the nano (fourth number) right !
11 dnl We disable static building for development, for time savings
13 AS_VERSION(gst-plugins, GST_PLUGINS, 0, 3, 3, 1)
14 AM_INIT_AUTOMAKE($PACKAGE,$VERSION)
15 AS_LIBTOOL(GST_PLUGINS, 0, 0, 0, yes)
17 dnl FIXME take something else ?
18 AC_CONFIG_SRCDIR([gst/law/alaw.c])
19 AM_CONFIG_HEADER(config.h)
21 dnl Add parameters for aclocal
22 dnl (This must come after AM_INIT_AUTOMAKE, since it modifies ACLOCAL)
23 ACLOCAL="$ACLOCAL -I m4 -I common/m4 $ACLOCAL_FLAGS"
37 dnl ###########################################
38 dnl # Super Duper options for plugin building #
39 dnl ###########################################
41 dnl experimental plugins; stuff that hasn't had the dust settle yet
42 dnl read 'builds, but might not work'
43 GST_CHECK_FEATURE(EXPERIMENTAL, [enable building of experimental plugins],,
44 [HAVE_EXPERIMENTAL=yes],disabled,
46 AC_MSG_WARN(building experimental plugins)
50 AC_MSG_NOTICE(not building experimental plugins)
55 dnl broken plugins; stuff that doesn't seem to build at the moment
56 GST_CHECK_FEATURE(BROKEN, [enable building of broken plugins],,
57 HAVE_BROKEN=yes,disabled,
59 AC_MSG_WARN([building broken plugins -- no bug reports on these, only patches :)])
67 AC_MSG_NOTICE(not building broken plugins)
70 dnl ##############################
71 dnl # Do automated configuration #
72 dnl ##############################
77 dnl modify pkg-config path
78 AC_ARG_WITH(pkg-config-path,
79 AC_HELP_STRING([--with-pkg-config-path],[colon-separated list of pkg-config(1) dirs]),
80 [export PKG_CONFIG_PATH=${withval}])
83 AC_PATH_PROG(NASM_PATH, nasm, no)
85 if test x$NASM_PATH = xno; then
86 AC_MSG_WARN(Couldn't find nasm)
89 AC_DEFINE(HAVE_NASM, 1, [Define if NASM, the netwide assembler, is available])
93 dnl check for gstreamer; uninstalled is selected preferentially -- see pkg-config(1)
94 PKG_CHECK_MODULES(GST, gstreamer >= $GST_PLUGINS_MAJOR.$GST_PLUGINS_MINOR.$GST_PLUGINS_MICRO,
95 HAVE_GST="yes", HAVE_GST="no")
97 if test "x$HAVE_GST" = "xno"; then
98 AC_MSG_ERROR(no GStreamer found)
101 GST_TOOLS_DIR=`pkg-config --variable=toolsdir gstreamer`
102 if test -z $GST_TOOLS_DIR; then
103 AC_MSG_ERROR([no tools dir defined in GStreamer pkg-config file; core upgrade needed.])
105 AC_SUBST(GST_TOOLS_DIR)
107 dnl Set up conditionals for (target) architecture:
108 dnl ==============================================
111 case "x${target_cpu}" in
112 xi?86 | k?) HAVE_CPU_I386=yes
113 AC_DEFINE(HAVE_CPU_I386, 1, [Define if the target CPU is an x86])
114 dnl FIXME could use some better detection
116 case "x${target_cpu}" in
118 *) AC_DEFINE(HAVE_RDTSC, 1, [Define if RDTSC is available]) ;;
120 xpowerpc) HAVE_CPU_PPC=yes
121 AC_DEFINE(HAVE_CPU_PPC, 1, [Define if the target CPU is a PPC]) ;;
122 xalpha) HAVE_CPU_ALPHA=yes
123 AC_DEFINE(HAVE_CPU_ALPHA, 1, [Define if the target CPU is an Alpha]) ;;
124 xarm*) HAVE_CPU_ARM=yes
125 AC_DEFINE(HAVE_CPU_ARM, 1, [Define if the target CPU is an ARM]) ;;
126 xsparc*) HAVE_CPU_SPARC=yes
127 AC_DEFINE(HAVE_CPU_SPARC, 1, [Define if the target CPU is a PPC]) ;;
128 xmips*) HAVE_CPU_MIPS=yes
129 AC_DEFINE(HAVE_CPU_MIPS, 1, [Define if the target CPU is a MIPS]) ;;
130 xhppa*) HAVE_CPU_HPPA=yes
131 AC_DEFINE(HAVE_CPU_HPPA, 1, [Define if the target CPU is a HPPA]) ;;
134 dnl Determine endianness
137 dnl Check for essential libraries first:
138 dnl ====================================
140 PKG_CHECK_MODULES(GTK2, gtk+-2.0, HAVE_GTK=yes, HAVE_GTK=no)
141 GTK_CFLAGS=$GTK2_CFLAGS
146 dnl Check for X11 extensions
148 if test "-DX_DISPLAY_MISSING" = "$X_CFLAGS"; then
149 AC_MSG_NOTICE([cannot find X11, the build system needs fixage])
153 AC_SUBST(X_EXTRA_LIBS)
156 dnl ==========================================================================
157 dnl ============================= gst plugins ================================
158 dnl ==========================================================================
159 GST_PLUGIN_LDFLAGS='-module -avoid-version'
160 AC_SUBST(GST_PLUGIN_LDFLAGS)
163 ac3parse adder audioscale auparse avi chart\
164 cutter deinterlace flx goom intfloat law level\
165 median mpeg1enc mpeg1sys mpeg1videoparse mpeg2enc mpeg2sub\
166 mpegaudio mpegaudioparse mpegstream mpegtypes modplug\
167 monoscope passthrough playondemand rtjpeg silence sine\
168 smooth spectrum speed stereo stereomono\
169 synaesthesia udp videoscale volenv volume vumeter wavparse y4m"
171 AC_SUBST(GST_PLUGINS_ALL)
173 GST_PLUGINS_SELECTED=""
176 AC_HELP_STRING([--with-plugins],[comma-separated list of plugins to compile]),
177 [for i in `echo $withval | tr , ' '`; do
178 if test -n `echo $i | grep $GST_PLUGINS_ALL`; then
179 GST_PLUGINS_SELECTED="$GST_PLUGINS_SELECTED $i"
181 echo "plugin $i not recognized, ignoring..."
184 [GST_PLUGINS_SELECTED=$GST_PLUGINS_ALL])
186 AC_SUBST(GST_PLUGINS_SELECTED)
188 dnl ==========================================================================
189 dnl ============================= sys plugins ================================
190 dnl ==========================================================================
193 dnl *** DXR3 card ***
194 translit(dnm, m, l) AM_CONDITIONAL(USE_DXR3, true)
195 GST_CHECK_FEATURE(DXR3, [DXR3 hardware mpeg video decoder], dxr3videosink, [
196 AC_CHECK_HEADER(linux/em8300.h, HAVE_DXR3="yes", HAVE_DXR3="no")
199 dnl *** OSS audio ***
200 translit(dnm, m, l) AM_CONDITIONAL(USE_OSS, true)
201 GST_CHECK_FEATURE(OSS, [OSS audio], osssrc osssink, [
202 AC_CHECK_HEADER(sys/soundcard.h, HAVE_OSS="yes", HAVE_OSS="no")
206 translit(dnm, m, l) AM_CONDITIONAL(USE_QCAM, true)
207 GST_CHECK_FEATURE(QCAM, [QuickCam], qcamsrc, [
208 dnl this one is for hadess, no qcam when no nasm found
209 if test "x$HAVE_NASM" = "xno";
212 AC_MSG_WARN([QuickCam needs nasm])
218 dnl *** Video 4 Linux ***
219 translit(dnm, m, l) AM_CONDITIONAL(USE_V4L, true)
220 GST_CHECK_FEATURE(V4L, [Video 4 Linux], v4lsrc v4lmjpegsrc v4lmjpegsink, [
221 AC_CHECK_DECL(VID_TYPE_MPEG_ENCODER, HAVE_V4L="yes", HAVE_V4L="no", [#include <linux/videodev.h>])
225 translit(dnm, m, l) AM_CONDITIONAL(USE_VCD, true)
226 GST_CHECK_FEATURE(VCD, [Video CD], vcdsrc, [
227 AC_CHECK_HEADER(linux/cdrom.h, HAVE_VCD="yes", HAVE_VCD="no")
231 translit(dnm, m, l) AM_CONDITIONAL(USE_VGA, true)
232 GST_CHECK_FEATURE(VGA, [VGA], vgavideosink, [
233 AC_CHECK_HEADER(asm/vga.h, HAVE_VGA="yes", HAVE_VGA="no")
237 dnl Look for the PIC library first, Debian requires it.
238 dnl Check debian-devel archives for gory details.
240 dnl At the moment XFree86 doesn't distribute shared libXv due
241 dnl to unstable API. On many platforms you CAN NOT link a shared
242 dnl lib to a static non-PIC lib. This is what the xvideo GStreamer
243 dnl plugin wants to do. So Debian distributes a PIC compiled
244 dnl version of the static lib for plugins to link to when it is
245 dnl inappropriate to link the main application to libXv directly.
246 dnl FIXME: add check if this platform can support linking to a
247 dnl non-PIC libXv, if not then don not use Xv.
248 dnl FIXME: perhaps warn user if they have a shared libXv since
249 dnl this is an error until XFree86 starts shipping one
250 translit(dnm, m, l) AM_CONDITIONAL(USE_XVIDEO, true)
251 GST_CHECK_FEATURE(XVIDEO, [X11 XVideo extensions], xvideosink videosink, [
252 dnl check for PIC static lib
253 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")
254 if test x$HAVE_XVIDEO = xno; then
255 dnl PIC lib not found, check for regular lib
256 GST_CHECK_LIBHEADER(XVIDEO, Xv, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h, XVIDEO_LIBS="-lXv -lXext")
258 AC_SUBST(XVIDEO_LIBS)
261 dnl Next, check for the optional libraries:
262 dnl These are all libraries used in building plugins
263 dnl ================================================
264 dnl let's try and sort them alphabetically, shall we ?
268 AC_MSG_NOTICE(Checking for plugin libraries)
271 translit(dnm, m, l) AM_CONDITIONAL(USE_A52DEC, true)
272 GST_CHECK_FEATURE(A52DEC, [a52dec], a52dec, [
277 translit(dnm, m, l) AM_CONDITIONAL(USE_AALIB, true)
278 GST_CHECK_FEATURE(AALIB, [aasink plugin], aasink, [
279 AM_PATH_AALIB(, HAVE_AALIB=yes, HAVE_AALIB=no)
283 translit(dnm, m, l) AM_CONDITIONAL(USE_ALSA, true)
284 GST_CHECK_FEATURE(ALSA, [alsa plugins], gstalsa, [
285 AM_PATH_ALSA(0.9.0, HAVE_ALSA=yes, HAVE_ALSA=no)
290 dnl if mcopidl can't be found there's no use in compiling it
291 AC_CHECK_PROG(MCOPIDL, mcopidl, yes, no)
292 if test "xHAVE_MCOPIDL" = "xno";
297 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTS, true)
298 GST_CHECK_FEATURE(ARTS, [arts plugins], arts, [
299 AM_PATH_ARTS(, HAVE_ARTS=yes, HAVE_ARTS=no)
301 dnl if mcopidl can't be found there's no use in compiling it
302 AC_PATH_PROG(MCOPIDL, mcopidl, yes, no)
303 if test "xHAVE_MCOPIDL" = "xno";
309 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTSC, true)
310 GST_CHECK_FEATURE(ARTSC, [artsd plugins], artsdsink, [
314 dnl *** audiofile ***
315 dnl this check uses the GST_CHECK_CONFIGPROG macro
316 translit(dnm, m, l) AM_CONDITIONAL(USE_AUDIOFILE, true)
317 GST_CHECK_FEATURE(AUDIOFILE, [audiofile], afsink afsrc, [
318 translit(dnm, m, l) AC_SUBST(AUDIOFILE_LIBS)
319 translit(dnm, m, l) AC_SUBST(AUDIOFILE_CFLAGS)
320 GST_CHECK_CONFIGPROG(AUDIOFILE, audiofile-config)
324 dnl this check uses the GST_CHECK_CONFIGPROG macro
325 dnl this check needs more fixing
326 dnl translit(dnm, m, l) AC_SUBST(AVIFILE_LIBS)
327 translit(dnm, m, l) AM_CONDITIONAL(USE_AVIFILE, true)
328 GST_CHECK_FEATURE(AVIFILE, [avifile], windec winenc, [
329 translit(dnm, m, l) AC_SUBST(AVIFILE_CFLAGS)
330 GST_CHECK_CONFIGPROG(AVIFILE, avifile-config)
331 AVIFILE_LIBS="$AVIFILE_LIBS -lstdc++"
332 AC_SUBST(AVIFILE_LIBS)
335 dnl *** CDParanoia ***
336 translit(dnm, m, l) AM_CONDITIONAL(USE_CDPARANOIA, true)
337 GST_CHECK_FEATURE(CDPARANOIA, [CDParanoia], cdparanoia, [
338 GST_CHECK_LIBHEADER(CDPARANOIA, cdda_interface, cdda_open, -lm, cdda_interface.h, CDPARANOIA_LIBS="-lcdda_interface -lcdda_paranoia")
339 AC_SUBST(CDPARANOIA_LIBS)
341 dnl FIXME : add second check somehow if that is necessary
342 dnl AC_CHECK_LIB(cdda_paranoia, paranoia_init, : , HAVE_CDPARANOIA=no, -lcdda_interface )
343 dnl AC_CHECK_HEADER(cdda_paranoia.h, :, HAVE_CDPARANOIA=no)
346 translit(dnm, m, l) AM_CONDITIONAL(USE_DV, true)
347 GST_CHECK_FEATURE(DV, [dv library], dv, [
348 GST_CHECK_LIBHEADER(DV, dv, dv_init, -lm $GST_CFLAGS $GST_LIBS, libdv/dv.h, DV_LIBS="-ldv")
353 translit(dnm, m, l) AM_CONDITIONAL(USE_DVDREAD, true)
354 GST_CHECK_FEATURE(DVDREAD, [dvdread library], dvdsrc, [
355 GST_CHECK_LIBHEADER(DVDREAD, dvdread, DVDOpen, , dvdread/dvd_reader.h, DVDREAD_LIBS="-ldvdread")
356 AC_SUBST(DVDREAD_LIBS)
360 translit(dnm, m, l) AM_CONDITIONAL(USE_ESD, true)
361 GST_CHECK_FEATURE(ESD, [esound plugins], esdsink esdmon, [
362 AM_PATH_ESD(0.2.12, HAVE_ESD=yes, HAVE_ESD=no)
365 dnl **** festival ****
366 translit(dnm, m, l) AM_CONDITIONAL(USE_FESTIVAL, true)
367 GST_CHECK_FEATURE(FESTIVAL, [festival plugins], festivalsrc, [
368 dnl NOTE: just using local net connection now, add this lib check
369 dnl in the future if needed
370 dnl AC_LANG_PUSH(C++)
371 dnl dnl FIXME: took out func to check for
372 dnl dnl This check puts festival_tidy_up in extern "C".
373 dnl dnl But, at least on Debian as of 20020110, it is compiled with name
374 dnl dnl mangling C++ nonsense and symbols can't resolve
375 dnl dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, festival_tidy_up, , festival/festival.h, FESTIVAL_LIBS="-lFestival")
376 dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, , , festival/festival.h, FESTIVAL_LIBS="-lFestival")
378 dnl AC_SUBST(FESTIVAL_LIBS)
383 translit(dnm, m, l) AM_CONDITIONAL(USE_FLAC, true)
384 GST_CHECK_FEATURE(FLAC, [FLAC lossless audio], flacenc flacdec, [
385 GST_CHECK_LIBHEADER(FLAC, FLAC, FLAC__stream_decoder_new, -lm, FLAC/all.h, FLAC_LIBS="-lFLAC")
389 dnl *** Gnome VFS ***
390 translit(dnm, m, l) AM_CONDITIONAL(USE_GNOME_VFS, true)
391 GST_CHECK_FEATURE(GNOME_VFS, [Gnome VFS], gnomevfssrc, [
392 PKG_CHECK_MODULES(GNOME_VFS, gnome-vfs-2.0, HAVE_GNOME_VFS="yes", HAVE_GNOME_VFS="no")
393 AC_SUBST(GNOME_VFS_CFLAGS)
394 AC_SUBST(GNOME_VFS_LIBS)
398 translit(dnm, m, l) AM_CONDITIONAL(USE_GSM, true)
399 GST_CHECK_FEATURE(GSM, [GSM library], gsmenc gsmdec, [
400 GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm.h, GSM_LIBS="-lgsm")
401 if test $HAVE_GSM != "yes"; then
402 GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm/gsm.h, GSM_LIBS="-lgsm")
403 if test $HAVE_GSM = "yes"; then
404 AC_DEFINE(GSM_HEADER_IN_SUBDIR, 1, [Define if GSM header in gsm/ subdir])
411 translit(dnm, m, l) AM_CONDITIONAL(USE_HERMES, true)
412 GST_CHECK_FEATURE(HERMES, [Hermes library], colorspace, [
413 GST_CHECK_LIBHEADER(HERMES, Hermes, Hermes_ConverterInstance, , Hermes/Hermes.h, HERMES_LIBS="-lHermes")
414 ], AC_SUBST(HERMES_LIBS))
417 translit(dnm, m, l) AM_CONDITIONAL(USE_HTTP, true)
418 GST_CHECK_FEATURE(HTTP, [http plugins], gsthttpsrc, [
419 dnl FIXME: need to check for header
421 GST_HTTPSRC_GET_TYPE=
422 if test x$USE_GLIB2 = xyes; then
423 AC_MSG_WARN(ghttp disabled for glib2.0)
425 AC_CHECK_LIB(ghttp, ghttp_request_new,
427 GST_HTTPSRC_GET_TYPE="gst_httpsrc_get_type"
432 AC_SUBST(GST_HTTPSRC_GET_TYPE)
436 translit(dnm, m, l) AM_CONDITIONAL(USE_JACK, true)
437 GST_CHECK_FEATURE(JACK, Jack, jack, [
438 PKG_CHECK_MODULES(JACK, jack, HAVE_JACK="yes", HAVE_JACK="no")
439 AC_SUBST(JACK_CFLAGS)
444 dnl FIXME: we could use header checks here as well IMO
445 translit(dnm, m, l) AM_CONDITIONAL(USE_JPEG, true)
446 GST_CHECK_FEATURE(JPEG, [jpeg], jpegenc jpegdec, [
447 AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
453 translit(dnm, m, l) AM_CONDITIONAL(USE_LAME, true)
454 GST_CHECK_FEATURE(LAME, [lame mp3 encoder library], lame, [
455 GST_CHECK_LIBHEADER(LAME, mp3lame, lame_init, -lm, lame/lame.h, HAVE_LAME="yes" LAME_LIBS="-lmp3lame")
459 dnl *** libcolorspace ***
460 translit(dnm, m, l) AM_CONDITIONAL(USE_LCS, true)
461 GST_CHECK_FEATURE(LCS, Lcs, lcs, [
462 PKG_CHECK_MODULES(LCS, lcs, HAVE_LCS="yes", HAVE_LCS="no")
467 dnl FIXME : check if these CPP flags can be dealt with otherwise
468 dnl libdvcheck_save_CPPFLAGS="$CPPFLAGS"
469 dnl CPPFLAGS="$CPPFLAGS $GST_CFLAGS"
470 dnl AC_CHECK_HEADER(libdv/dv.h, :, HAVE_LIBDV=no)
471 dnl CPPFLAGS="$libdvcheck_save_CPPFLAGS"
474 dnl FIXME: we could use header checks here as well IMO
475 translit(dnm, m, l) AM_CONDITIONAL(USE_MAD, true)
476 GST_CHECK_FEATURE(MAD, [mad mp3 decoder], mad, [
477 AC_CHECK_LIB(mad, mad_decoder_finish, HAVE_MAD="yes" MAD_LIBS="-lmad")
478 if test "x$HAVE_MAD" = "xyes"; then
479 # installed with mad >= 0.14
483 AC_CHECK_LIB(id3tag, id3_tag_query, HAVE_MAD="yes" MAD_LIBS="$MAD_LIBS -lid3tag")
490 translit(dnm, m, l) AM_CONDITIONAL(USE_MIKMOD, true)
491 GST_CHECK_FEATURE(MIKMOD, [mikmod plugin], mikmod, [
492 AM_PATH_LIBMIKMOD(, HAVE_MIKMOD=yes, HAVE_MIKMOD=no)
493 AC_SUBST(MIKMOD_LIBS, "$LIBMIKMOD_LIBS")
494 AC_SUBST(MIKMOD_CFLAGS, "$LIBMIKMODCFLAGS")
497 dnl *** mjpegtools ***
498 translit(dnm, m, l) AM_CONDITIONAL(USE_MJPEGTOOLS, true)
499 GST_CHECK_FEATURE(MJPEGTOOLS, [mjpegtools], jpegmmxenc jpegmmxdec, [
500 PKG_CHECK_MODULES(MJPEGTOOLS, mjpegtools, HAVE_MJPEGTOOLS="yes", HAVE_MJPEGTOOLS="no")
501 AC_SUBST(MJPEGTOOLS_LIBS)
502 AC_SUBST(MJPEGTOOLS_CFLAGS)
506 translit(dnm, m, l) AM_CONDITIONAL(USE_MPEG2DEC, true)
507 GST_CHECK_FEATURE(MPEG2DEC, [mpeg2dec], mpeg2dec, [ GST_CHECK_MPEG2DEC() ])
509 dnl *** openquicktime ***
510 translit(dnm, m, l) AM_CONDITIONAL(USE_OPENQUICKTIME, true)
511 GST_CHECK_FEATURE(OPENQUICKTIME, [Open Quicktime], quicktime_parser quicktime_decoder quicktime_demux,[
512 GST_CHECK_LIBHEADER(OPENQUICKTIME, openquicktime, quicktime_init,, openquicktime/openquicktime.h, OPENQUICKTIME_LIBS="-lopenquicktime")
513 AC_SUBST(OPENQUICKTIME_LIBS)
517 translit(dnm, m, l) AM_CONDITIONAL(USE_RAW1394, true)
518 GST_CHECK_FEATURE(RAW1394, [raw1394 library], dv1394src, [
519 GST_CHECK_LIBHEADER(RAW1394, raw1394, raw1394_get_handle,, libraw1394/raw1394.h, RAW1394_LIBS="-raw1394")
520 AC_SUBST(RAW1394_LIBS)
524 dnl FIXME : adapt and make it work
525 translit(dnm, m, l) AM_CONDITIONAL(USE_RTP, true)
526 GST_CHECK_FEATURE(RTP, [RTP library], rtpenc rtpdec,[
527 AC_CHECK_LIB(rtp, rtp_packet_new_take_data, HAVE_RTP=yes, HAVE_RTP=no, $GST_CFLAGS $GST_LIBS)
532 dnl FIXME header check needs to use GLIB_CFLAGS in order to succeed for rtp
533 dnl can use GST_* which should have GLIB_* info
534 dnl AC_CHECK_HEADERS(rtp/rtp.h, HAVE_LIBRTP=yes, HAVE_LIBRTP=no)
535 dnl AC_CHECK_HEADERS(rtp/rtp-packet.h, :, HAVE_LIBRTP=no)
536 dnl AC_CHECK_HEADERS(rtp/rtcp-packet.h, :, HAVE_LIBRTP=no)
537 dnl AC_CHECK_HEADERS(rtp/rtp-audio.h, :, HAVE_LIBRTP=no)
540 translit(dnm, m, l) AM_CONDITIONAL(USE_SDL, true)
541 GST_CHECK_FEATURE(SDL, [SDL plugin], sdlvideosink, [
542 AM_PATH_SDL(, HAVE_SDL=yes, HAVE_SDL=no)
546 translit(dnm, m, l) AM_CONDITIONAL(USE_SHOUT, true)
547 GST_CHECK_FEATURE(SHOUT, [shout plugin], icecastsend, [
548 GST_CHECK_LIBHEADER(SHOUT, shout, shout_init_connection,, shout/shout.h, SHOUT_LIBS="-lshout")
553 translit(dnm, m, l) AM_CONDITIONAL(USE_SIDPLAY, true)
554 GST_CHECK_FEATURE(SIDPLAY, [sidplay plugin], sidplay, [
558 dnl *** smoothwave ***
559 translit(dnm, m, l) AM_CONDITIONAL(USE_SMOOTHWAVE, true)
560 GST_CHECK_FEATURE(SMOOTHWAVE, [smoothwave plugin], smoothwave, [
561 if test $HAVE_GTK = "yes"; then HAVE_SMOOTHWAVE=yes; fi;
565 dnl for now the sources are included in the plugin
566 dnl and should be moved to ext-libs/ perhaps
567 translit(dnm, m, l) AM_CONDITIONAL(USE_TARKIN, true)
568 GST_CHECK_FEATURE(TARKIN, [tarkinenc tarkindec], tarkin, [
573 dnl AM_PATH_VORBIS only takes two options
574 translit(dnm, m, l) AM_CONDITIONAL(USE_VORBIS, true)
575 GST_CHECK_FEATURE(VORBIS, [vorbis plugin], vorbisenc vorbisdec, [
576 AM_PATH_VORBIS(HAVE_VORBIS=yes, HAVE_VORBIS=no)
580 translit(dnm, m, l) AM_CONDITIONAL(USE_XMMS, true)
581 GST_CHECK_FEATURE(XMMS, [xmms plugin], xmms, [
582 AM_PATH_XMMS(0.1.0, HAVE_XMMS=yes, HAVE_XMMS=no)
585 dnl Check for atomic.h
586 dnl Note: use AC_CHECK_HEADER not AC_CHECK_HEADERS, because the latter
587 dnl defines the wrong default symbol as well (HAVE_ASM_ATOMIC_H)
588 AC_CHECK_HEADER(asm/atomic.h, HAVE_ATOMIC_H=yes, HAVE_ATOMIC_H=no)
589 dnl Do a compile to check that it has atomic_set (eg, linux 2.0 didn't)
590 if test x$HAVE_ATOMIC_H = xyes; then
592 #include "asm/atomic.h"
593 main() { atomic_t t; atomic_set(&t,0); atomic_inc(&t); atomic_add(1,&t);return 0;}
596 if test x$HAVE_ATOMIC_H = xyes; then
597 AC_MSG_WARN(Atomic reference counting is out of date: doing without.)
603 AC_MSG_WARN(Can't check properly for atomic reference counting. Assuming OK.)
607 dnl ######################################################################
608 dnl # Check command line parameters, and set shell variables accordingly #
609 dnl ######################################################################
613 AC_ARG_ENABLE(libmmx,
614 [ --enable-libmmx use libmmx, if available],
615 [case "${enableval}" in
616 yes) USE_LIBMMX=$HAVE_LIBMMX ;;
618 *) AC_MSG_ERROR(bad value ${enableval} for --enable-libmmx) ;;
620 [USE_LIBMMX=$HAVE_LIBMMX]) dnl Default value
622 AC_ARG_ENABLE(atomic,
623 [ --enable-atomic use atomic reference counting header],
624 [case "${enableval}" in
625 yes) USE_ATOMIC_H=$HAVE_ATOMIC_H;;
626 noset) USE_ATOMIC_H=$HAVE_ATOMIC_H;;
627 no) USE_ATOMIC_H=no;;
628 *) AC_MSG_ERROR(bad value ${enableval} for --enable-atomic) ;;
630 [USE_ATOMIC_H=$HAVE_ATOMIC_H]) dnl Default value
632 AC_ARG_ENABLE(profiling,
633 [ --enable-profiling adds -pg to compiler commandline, for profiling],
634 [case "${enableval}" in
635 yes) USE_PROFILING=yes ;;
636 no) UES_PROFILING=no ;;
637 *) AC_MSG_ERROR(bad value ${enableval} for --enable-profiling) ;;
639 [USE_PROFILING=no]) dnl Default value
642 [ --disable-tests disable building test apps],
643 [case "${enableval}" in
644 yes) BUILD_TESTS=yes ;;
645 no) BUILD_TESTS=no ;;
646 *) AC_MSG_ERROR(bad value ${enableval} for --disable-tests) ;;
648 [BUILD_TESTS=yes]) dnl Default value
650 AC_ARG_ENABLE(examples,
651 [ --disable-examples disable building examples],
652 [case "${enableval}" in
653 yes) BUILD_EXAMPLES=yes ;;
654 no) BUILD_EXAMPLES=no ;;
655 *) AC_MSG_ERROR(bad value ${enableval} for --disable-examples) ;;
657 [BUILD_EXAMPLES=yes]) dnl Default value
659 dnl ################################################
660 dnl # Set defines according to variables set above #
661 dnl ################################################
664 if test "x$USE_LIBMMX" = xyes; then
665 AC_DEFINE(HAVE_LIBMMX, 1, [Define if libmmx is available])
668 if test "x$USE_ATOMIC_H" = xyes; then
669 AC_DEFINE(HAVE_ATOMIC_H, 1, [Define if atomic.h header file is available])
672 dnl if test "x$USE_DEBUG" = xyes; then
673 dnl CFLAGS="$CFLAGS -g"
676 if test "x$USE_PROFILING" = xyes; then
677 dnl CFLAGS="$CFLAGS -pg -fprofile-arcs"
678 FOMIT_FRAME_POINTER=""
680 FOMIT_FRAME_POINTER="-fomit-frame-pointer"
684 dnl AC_SUBST(FOMIT_FRAME_POINTER)
687 dnl #############################
688 dnl # Set automake conditionals #
689 dnl #############################
691 dnl These should be "USE_*" instead of "HAVE_*", but some packages expect
692 dnl HAVE_ and it is likely to be easier to stick with the old name
693 AM_CONDITIONAL(HAVE_CPU_I386, test "x$HAVE_CPU_I386" = "xyes")
694 AM_CONDITIONAL(HAVE_CPU_PPC, test "x$HAVE_CPU_PPC" = "xyes")
695 AM_CONDITIONAL(HAVE_CPU_ALPHA, test "x$HAVE_CPU_ALPHA" = "xyes")
696 AM_CONDITIONAL(HAVE_CPU_ARM, test "x$HAVE_CPU_ARM" = "xyes")
697 AM_CONDITIONAL(HAVE_CPU_SPARC, test "x$HAVE_CPU_SPARC" = "xyes")
698 AM_CONDITIONAL(HAVE_LIBMMX, test "x$USE_LIBMMX" = "xyes")
700 AM_CONDITIONAL(HAVE_ATOMIC_H, test "x$USE_ATOMIC_H" = "xyes")
702 AM_CONDITIONAL(EXPERIMENTAL, test "$EXPERIMENTAL" = "$xyes")
703 AM_CONDITIONAL(BROKEN, test "$BROKEN" = "$xyes")
705 AM_CONDITIONAL(HAVE_NASM, test "x$HAVE_NASM" = "xyes")
706 AM_CONDITIONAL(HAVE_LIBGLADE_GNOME, test "x$HAVE_LIBGLADE_GNOME" = "xyes")
707 AM_CONDITIONAL(HAVE_GNOME, test "x$HAVE_GNOME" = "xyes")
708 AM_CONDITIONAL(HAVE_GTK, test "x$HAVE_GTK" = "xyes")
709 AM_CONDITIONAL(HAVE_GTK_DOC, $HAVE_GTK_DOC)
710 AM_CONDITIONAL(BUILD_DOCS, test "x$BUILD_DOCS" = "xyes")
711 AM_CONDITIONAL(BUILD_TESTS, test "x$BUILD_TESTS" = "xyes")
712 AM_CONDITIONAL(BUILD_EXAMPLES, test "x$BUILD_EXAMPLES" = "xyes")
713 AM_CONDITIONAL(BUILD_PLUGIN_DOCS, test "x$BUILD_PLUGIN_DOCS" = "xyes")
714 AM_CONDITIONAL(HAVE_FIG2DEV_PNG, $HAVE_FIG2DEV_PNG)
715 AM_CONDITIONAL(HAVE_FIG2DEV_PDF, $HAVE_FIG2DEV_PDF)
716 AM_CONDITIONAL(HAVE_RAW1394, test "x$HAVE_RAW1394" = "xyes")
718 GST_CFLAGS="$GST_CFLAGS -I\$(top_srcdir)/gst-libs -Wall"
722 dnl #########################
723 dnl # Make the output files #
724 dnl #########################
726 dnl testsuite/autoplug/Makefile
727 dnl testsuite/Makefile
731 gstreamer-libs-uninstalled.pc
734 gst/ac3parse/Makefile
736 gst/audioscale/Makefile
741 gst/deinterlace/Makefile
744 gst/intfloat/Makefile
748 gst/mpeg1enc/Makefile
749 gst/mpeg1sys/Makefile
750 gst/mpeg1videoparse/Makefile
751 gst/mpeg2enc/Makefile
752 gst/mpeg2sub/Makefile
753 gst/mpegaudio/Makefile
754 gst/mpegaudioparse/Makefile
755 gst/mpegstream/Makefile
756 gst/mpegtypes/Makefile
758 gst/modplug/libmodplug/Makefile
759 gst/monoscope/Makefile
760 gst/passthrough/Makefile
761 gst/playondemand/Makefile
766 gst/spectrum/Makefile
769 gst/stereomono/Makefile
770 gst/synaesthesia/Makefile
772 gst/videoscale/Makefile
776 gst/wavparse/Makefile
786 sys/videosink/Makefile
793 ext/audiofile/Makefile
795 ext/cdparanoia/Makefile
799 ext/festival/Makefile
801 ext/gnomevfs/Makefile
812 ext/mjpegtools/Makefile
813 ext/mpeg2dec/Makefile
814 ext/openquicktime/Makefile
820 ext/smoothwave/Makefile
825 gst-libs/gst/Makefile
826 gst-libs/gst/audio/Makefile
827 gst-libs/gst/idct/Makefile
828 gst-libs/gst/resample/Makefile
829 gst-libs/gst/riff/Makefile
830 examples/capsfilter/Makefile
837 echo -e "configure: *** Plugins that will be built : $GST_PLUGINS_YES"
839 echo -e "configure: *** Plugins that will not be built : $GST_PLUGINS_NO"