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 AM_MAINTAINER_MODE only provides the option to configure to enable it
13 dnl when going to/from release please set the nano (fourth number) right !
14 dnl releases only do Wall, cvs and prerelease does Werror too
15 AS_VERSION(gst-plugins, GST_PLUGINS, 0, 4, 1, 1, GST_ERROR="-Wall", GST_ERROR="-Wall -Werror")
16 AM_INIT_AUTOMAKE($PACKAGE,$VERSION)
17 AS_LIBTOOL(GST_PLUGINS, 0, 0, 0, yes)
19 dnl FIXME take something else ?
20 AC_CONFIG_SRCDIR([gst/law/alaw.c])
21 AM_CONFIG_HEADER(config.h)
23 dnl Add parameters for aclocal
24 dnl (This must come after AM_INIT_AUTOMAKE, since it modifies ACLOCAL)
25 ACLOCAL_FLAGS="-I m4 -I common/m4"
26 AC_SUBST(ACLOCAL_AMFLAGS, $ACLOCAL_FLAGS)
32 dnl determine c++ compiler
34 dnl determine if c++ is available on this system
35 AC_CHECK_PROG(HAVE_CXX, $CXX, yes, no)
36 dnl determine c++ preprocessor
42 dnl ############################################
43 dnl # Super Duper options for plug-in building #
44 dnl ############################################
46 dnl ext plug-ins; plug-ins that have external dependencies
47 GST_CHECK_FEATURE(EXTERNAL, [enable building of plug-ins with external deps],,
48 [HAVE_EXTERNAL=yes],enabled,
50 AC_MSG_WARN(building external plug-ins)
53 AC_MSG_WARN(all plug-ins with external dependencies will not be built)
56 # make BUILD_EXTERNAL available to Makefile.am
57 AM_CONDITIONAL(BUILD_EXTERNAL, test "x$BUILD_EXTERNAL" = "xyes")
59 dnl experimental plug-ins; stuff that hasn't had the dust settle yet
60 dnl read 'builds, but might not work'UTO
61 GST_CHECK_FEATURE(EXPERIMENTAL, [enable building of experimental plug-ins],,
62 [HAVE_EXPERIMENTAL=yes],disabled,
64 AC_MSG_WARN(building experimental plug-ins)
68 AC_MSG_NOTICE(not building experimental plug-ins)
73 dnl broken plug-ins; stuff that doesn't seem to build at the moment
74 GST_CHECK_FEATURE(BROKEN, [enable building of broken plug-ins],,
75 HAVE_BROKEN=yes,disabled,
77 AC_MSG_WARN([building broken plug-ins -- no bug reports on these, only patches :)])
85 AC_MSG_NOTICE([not building broken plug-ins])
88 dnl ##############################
89 dnl # Do automated configuration #
90 dnl ##############################
95 dnl allow for different autotools
96 AS_AUTOTOOLS_ALTERNATE()
98 dnl modify pkg-config path
99 AC_ARG_WITH(pkg-config-path,
100 AC_HELP_STRING([--with-pkg-config-path],[colon-separated list of pkg-config(1) dirs]),
101 [export PKG_CONFIG_PATH=${withval}])
104 AC_PATH_PROG(NASM_PATH, nasm, no)
106 if test x$NASM_PATH = xno; then
107 AC_MSG_WARN(Couldn't find nasm)
110 AC_DEFINE(HAVE_NASM, 1, [Define if NASM, the netwide assembler, is available])
114 dnl check for gconftool-2
115 translit(dnm, m, l) AM_CONDITIONAL(USE_GCONFTOOL, true)
116 GST_CHECK_FEATURE(GCONFTOOL, [GConf schemas], , [
117 AC_PATH_PROG(GCONFTOOL, gconftool-2, no)
118 if test x$GCONFTOOL = xno; then
119 AC_MSG_WARN(Not installing GConf schemas)
125 AC_SUBST(HAVE_GCONFTOOL)
128 dnl check for GConf libraries
129 translit(dnm, m, l) AM_CONDITIONAL(USE_GCONF, true)
130 GST_CHECK_FEATURE(GCONF, [GConf libraries], , [
131 PKG_CHECK_MODULES(GCONF, gconf-2.0, HAVE_GCONF="yes", HAVE_GCONF="no")
132 AC_SUBST(GCONF_CFLAGS)
136 dnl check for gstreamer; uninstalled is selected preferentially -- see pkg-config(1)
137 PKG_CHECK_MODULES(GST, gstreamer >= $GST_PLUGINS_MAJOR.$GST_PLUGINS_MINOR.$GST_PLUGINS_MICRO,
138 HAVE_GST="yes", HAVE_GST="no")
140 if test "x$HAVE_GST" = "xno"; then
141 AC_MSG_ERROR(no GStreamer found)
144 GST_TOOLS_DIR=`pkg-config --variable=toolsdir gstreamer`
145 if test -z $GST_TOOLS_DIR; then
146 AC_MSG_ERROR([no tools dir defined in GStreamer pkg-config file; core upgrade needed.])
148 AC_SUBST(GST_TOOLS_DIR)
150 dnl Set up conditionals for (target) architecture:
151 dnl ==============================================
154 case "x${target_cpu}" in
155 xi?86 | k?) HAVE_CPU_I386=yes
156 AC_DEFINE(HAVE_CPU_I386, 1, [Define if the target CPU is an x86])
157 dnl FIXME could use some better detection
159 case "x${target_cpu}" in
161 *) AC_DEFINE(HAVE_RDTSC, 1, [Define if RDTSC is available]) ;;
163 xpowerpc) HAVE_CPU_PPC=yes
164 AC_DEFINE(HAVE_CPU_PPC, 1, [Define if the target CPU is a PPC]) ;;
165 xalpha) HAVE_CPU_ALPHA=yes
166 AC_DEFINE(HAVE_CPU_ALPHA, 1, [Define if the target CPU is an Alpha]) ;;
167 xarm*) HAVE_CPU_ARM=yes
168 AC_DEFINE(HAVE_CPU_ARM, 1, [Define if the target CPU is an ARM]) ;;
169 xsparc*) HAVE_CPU_SPARC=yes
170 AC_DEFINE(HAVE_CPU_SPARC, 1, [Define if the target CPU is a PPC]) ;;
171 xmips*) HAVE_CPU_MIPS=yes
172 AC_DEFINE(HAVE_CPU_MIPS, 1, [Define if the target CPU is a MIPS]) ;;
173 xhppa*) HAVE_CPU_HPPA=yes
174 AC_DEFINE(HAVE_CPU_HPPA, 1, [Define if the target CPU is a HPPA]) ;;
177 dnl Determine endianness
180 dnl Check for fast float to int casting as defined in C99
184 dnl Check for essential libraries first:
185 dnl ====================================
188 PKG_CHECK_MODULES(GTK2, gtk+-2.0, HAVE_GTK=yes, HAVE_GTK=no)
189 GTK_CFLAGS=$GTK2_CFLAGS
194 dnl Check for X11 extensions
196 if test "-DX_DISPLAY_MISSING" = "$X_CFLAGS"; then
197 AC_MSG_NOTICE([cannot find X11, the build system needs fixage])
201 AC_SUBST(X_EXTRA_LIBS)
204 dnl ===========================================================================
205 dnl ============================= gst plug-ins ================================
206 dnl ===========================================================================
208 GST_PLUGIN_LDFLAGS='-module -avoid-version'
209 AC_SUBST(GST_PLUGIN_LDFLAGS)
211 dnl these are all the gst plug-ins, compilable without additional libs
213 ac3parse adder audioscale auparse avi cdxaparse chart\
214 cutter deinterlace effectv festival filter flx goom\
216 median mixmatrix mpeg1enc mpeg1sys mpeg1videoparse mpeg2enc mpeg2sub\
217 mpegaudio mpegaudioparse mpegstream mpegtypes\
218 monoscope passthrough playondemand qtdemux rtjpeg silence sine\
219 smooth spectrum speed stereo stereomono\
220 synaesthesia udp videocrop videoscale videotestsrc volenv volume\
221 vumeter wavparse y4m"
223 dnl see if we can build C++ plug-ins
224 if test "x$HAVE_CXX" = "xyes"; then
225 GST_PLUGINS_ALL="$GST_PLUGINS_ALL \
228 AC_MSG_WARN([Not compiling plug-ins requiring C++ compiler])
231 AC_SUBST(GST_PLUGINS_ALL)
233 GST_PLUGINS_SELECTED=""
236 AC_HELP_STRING([--with-plugins],[comma-separated list of plug-ins to compile]),
237 [for i in `echo $withval | tr , ' '`; do
238 if test -n `echo $i | grep $GST_PLUGINS_ALL`; then
239 GST_PLUGINS_SELECTED="$GST_PLUGINS_SELECTED $i"
241 echo "plug-in $i not recognized, ignoring..."
244 [GST_PLUGINS_SELECTED=$GST_PLUGINS_ALL])
246 AC_SUBST(GST_PLUGINS_SELECTED)
248 dnl ==========================================================================
249 dnl ============================= sys plug-ins ================================
250 dnl ==========================================================================
252 dnl *** DXR3 card ***
253 translit(dnm, m, l) AM_CONDITIONAL(USE_DXR3, true)
254 GST_CHECK_FEATURE(DXR3, [DXR3 hardware mpeg video decoder], dxr3videosink, [
255 AC_CHECK_HEADER(linux/em8300.h, HAVE_DXR3="yes", HAVE_DXR3="no")
258 dnl *** OSS audio ***
259 translit(dnm, m, l) AM_CONDITIONAL(USE_OSS, true)
260 GST_CHECK_FEATURE(OSS, [OSS audio], osssrc osssink, [
261 AC_CHECK_HEADER(sys/soundcard.h, HAVE_OSS="yes", HAVE_OSS="no")
265 translit(dnm, m, l) AM_CONDITIONAL(USE_QCAM, true)
266 GST_CHECK_FEATURE(QCAM, [QuickCam], qcamsrc, [
267 dnl this one is for hadess, no qcam when no nasm found
268 if test "x$HAVE_NASM" = "xno";
271 AC_MSG_WARN([QuickCam needs nasm])
277 dnl *** Video 4 Linux ***
278 translit(dnm, m, l) AM_CONDITIONAL(USE_V4L, true)
279 GST_CHECK_FEATURE(V4L, [Video 4 Linux], v4lsrc v4lmjpegsrc v4lmjpegsink, [
280 AC_CHECK_DECL(VID_TYPE_MPEG_ENCODER, HAVE_V4L="yes", HAVE_V4L="no", [#include <linux/videodev.h>])
283 dnl *** Video 4 Linux 2***
284 translit(dnm, m, l) AM_CONDITIONAL(USE_V4L2, true)
285 GST_CHECK_FEATURE(V4L2, [Video 4 Linux 2], v4l2src, [
286 AC_CHECK_HEADER(linux/videodev2.h, HAVE_V4L2="yes", HAVE_V4L2="no")
290 translit(dnm, m, l) AM_CONDITIONAL(USE_VCD, true)
291 GST_CHECK_FEATURE(VCD, [Video CD], vcdsrc, [
292 AC_CHECK_HEADER(linux/cdrom.h, HAVE_VCD="yes", HAVE_VCD="no")
296 translit(dnm, m, l) AM_CONDITIONAL(USE_VGA, true)
297 GST_CHECK_FEATURE(VGA, [VGA], vgavideosink, [
298 AC_CHECK_HEADER(asm/vga.h, HAVE_VGA="yes", HAVE_VGA="no")
301 dnl *** CDROM Audio ***
302 translit(dnm, m, l) AM_CONDITIONAL(USE_CDROM, true)
303 GST_CHECK_FEATURE(CDROM, [CDROM Audio], cdrom, [
304 AC_CHECK_HEADERS(linux/cdrom.h) dnl linux
305 AC_CHECK_HEADERS(sys/cdio.h) dnl almost everything else
306 dnl AC_CHECK_HEADERS(dmedia/cdaudio.h) dnl irix
308 if test "${ac_cv_header_linux_cdrom_h}" = "yes" || test "${ac_cv_header_sys_cdio_h}" = "yes" || test "${ac_cv_header_dmedia_cdaudio_h}" = "yes"; then
310 *-sun-* | *-*-linux*)
311 AC_DEFINE(HAVE_CDROM_SOLARIS,, [Define if cdrom access is in Solaris style])
314 AC_DEFINE(HAVE_CDROM_BSD,, [Define if cdrom access is in BSD style])
316 *-*-netbsd* | *-*-openbsd*)
317 AC_DEFINE(HAVE_CDROM_BSD,, [Define if cdrom access is in BSD style])
318 AC_DEFINE(HAVE_CDROM_BSD_NETBSD,, [Define if cdrom access uses NetBSD variant])
321 AC_DEFINE(HAVE_CDROM_BSD,, [Define if cdrom access is in BSD style])
322 AC_DEFINE(HAVE_CDROM_BSD_DARWIN,, [Define if cdrom access uses Darwin variant])
325 dnl AC_DEFINE(HAVE_CDROM_IRIX,, [Define if cdrom access is in Irix DMedia style])
336 dnl Look for the PIC library first, Debian requires it.
337 dnl Check debian-devel archives for gory details.
339 dnl At the moment XFree86 doesn't distribute shared libXv due
340 dnl to unstable API. On many platforms you CAN NOT link a shared
341 dnl lib to a static non-PIC lib. This is what the xvideo GStreamer
342 dnl plug-in wants to do. So Debian distributes a PIC compiled
343 dnl version of the static lib for plug-ins to link to when it is
344 dnl inappropriate to link the main application to libXv directly.
345 dnl FIXME: add check if this platform can support linking to a
346 dnl non-PIC libXv, if not then don not use Xv.
347 dnl FIXME: perhaps warn user if they have a shared libXv since
348 dnl this is an error until XFree86 starts shipping one
349 translit(dnm, m, l) AM_CONDITIONAL(USE_XVIDEO, true)
350 GST_CHECK_FEATURE(XVIDEO, [X11 XVideo extensions], xvideosink videosink, [
351 dnl check for PIC static lib
352 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")
353 if test x$HAVE_XVIDEO = xno; then
354 dnl PIC lib not found, check for regular lib
355 GST_CHECK_LIBHEADER(XVIDEO, Xv, XvQueryExtension, $X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS, X11/extensions/Xvlib.h, XVIDEO_LIBS="-lXv -lXext")
357 AC_SUBST(XVIDEO_LIBS)
360 dnl Next, check for the optional libraries:
361 dnl These are all libraries used in building plug-ins
362 dnl ================================================
363 dnl let's try and sort them alphabetically, shall we ?
365 if test "x$BUILD_EXTERNAL" = "xyes"; then
367 AC_MSG_NOTICE(Checking for plug-in dependency libraries)
370 translit(dnm, m, l) AM_CONDITIONAL(USE_A52DEC, true)
371 GST_CHECK_FEATURE(A52DEC, [a52dec], a52dec, [
372 AC_CHECK_A52DEC(HAVE_A52DEC=yes, HAVE_A52DEC=no)
376 translit(dnm, m, l) AM_CONDITIONAL(USE_AALIB, true)
377 GST_CHECK_FEATURE(AALIB, [aasink plug-in], aasink, [
378 AM_PATH_AALIB(, HAVE_AALIB=yes, HAVE_AALIB=no)
382 translit(dnm, m, l) AM_CONDITIONAL(USE_ALSA, true)
383 GST_CHECK_FEATURE(ALSA, [alsa plug-ins], gstalsa, [
384 AM_PATH_ALSA(0.9.0, HAVE_ALSA=yes, HAVE_ALSA=no)
388 dnl if mcopidl can't be found there's no use in compiling it
389 AC_CHECK_PROG(MCOPIDL, mcopidl, yes, no)
390 if test "xHAVE_MCOPIDL" = "xno";
395 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTS, true)
396 GST_CHECK_FEATURE(ARTS, [arts plug-ins], arts, [
397 AM_PATH_ARTS(, HAVE_ARTS=yes, HAVE_ARTS=no)
401 translit(dnm, m, l) AM_CONDITIONAL(USE_ARTSC, true)
402 GST_CHECK_FEATURE(ARTSC, [artsd plug-ins], artsdsink, [
406 dnl *** audiofile ***
407 dnl this check uses the GST_CHECK_CONFIGPROG macro
408 translit(dnm, m, l) AM_CONDITIONAL(USE_AUDIOFILE, true)
409 GST_CHECK_FEATURE(AUDIOFILE, [audiofile], afsink afsrc, [
410 translit(dnm, m, l) AC_SUBST(AUDIOFILE_LIBS)
411 translit(dnm, m, l) AC_SUBST(AUDIOFILE_CFLAGS)
412 GST_CHECK_CONFIGPROG(AUDIOFILE, audiofile-config)
413 dnl we need this function
414 AC_CHECK_LIB(audiofile, afOpenVirtualFile, , HAVE_AUDIOFILE="no")
418 translit(dnm, m, l) AM_CONDITIONAL(USE_AVIFILE, true)
419 GST_CHECK_FEATURE(AVIFILE, [avifile], winenc windec, [
420 if test "x$no_x" = "xyes"; then
421 AC_MSG_WARN([No X libraries found, avifile test might fail compilation])
423 if test "x$HAVE_CXX" != "xyes"; then
424 AC_MSG_WARN([No C++ compiler found, avifile test will fail compilation])
426 AC_CHECK_LIB(stdc++, cout,,
427 [AC_MSG_WARN([no libstdc++ found, avifile test will fail])]
432 dnl *** CDParanoia ***
433 translit(dnm, m, l) AM_CONDITIONAL(USE_CDPARANOIA, true)
434 GST_CHECK_FEATURE(CDPARANOIA, [CDParanoia], cdparanoia, [
435 GST_CHECK_LIBHEADER(CDPARANOIA, cdda_interface,
438 CDPARANOIA_LIBS="-lcdda_interface -lcdda_paranoia"
440 FOUND_CDPARANOIA="yes")
441 if test "x$FOUND_CDPARANOIA" != "xyes";
443 GST_CHECK_LIBHEADER(CDPARANOIA, cdda_interface,
445 cdda/cdda_interface.h,
446 CDPARANOIA_LIBS="-lcdda_interface -lcdda_paranoia"
448 FOUND_CDPARANOIA="yes")
450 if test "x$HEADER_DIR" = "xyes";
452 AC_DEFINE_UNQUOTED(CDPARANOIA_HEADERS_IN_DIR, ,
453 defined if cdda headers are in a cdda/ directory)
455 AC_SUBST(CDPARANOIA_LIBS)
457 dnl FIXME : add second check somehow if that is necessary
458 dnl AC_CHECK_LIB(cdda_paranoia, paranoia_init, : , HAVE_CDPARANOIA=no, -lcdda_interface )
459 dnl AC_CHECK_HEADER(cdda_paranoia.h, :, HAVE_CDPARANOIA=no)
462 translit(dnm, m, l) AM_CONDITIONAL(USE_LIBDV, true)
463 GST_CHECK_FEATURE(LIBDV, [libdv DV/video decoder], dvdec, [
464 dnl use this when gtk deps are removed from its pkg-config .pc
465 dnl PKG_CHECK_MODULES(LIBDV, libdv, HAVE_LIBDV="yes", HAVE_LIBDV="no")
466 AM_PATH_LIBDV(HAVE_LIBDV="yes", HAVE_LIBDV="no")
467 AC_SUBST(LIBDV_CFLAGS)
472 translit(dnm, m, l) AM_CONDITIONAL(USE_DVDREAD, true)
473 GST_CHECK_FEATURE(DVDREAD, [dvdread library], dvdreadsrc, [
474 GST_CHECK_LIBHEADER(DVDREAD, dvdread, DVDOpen, , dvdread/dvd_reader.h, DVDREAD_LIBS="-ldvdread")
475 AC_SUBST(DVDREAD_LIBS)
479 translit(dnm, m, l) AM_CONDITIONAL(USE_DVDNAV, true)
480 GST_CHECK_FEATURE(DVDNAV, [dvdnav library], dvdnavsrc, [
481 translit(dnm, m, l) AC_SUBST(DVDNAV_LIBS)
482 translit(dnm, m, l) AC_SUBST(DVDNAV_CFLAGS)
483 GST_CHECK_CONFIGPROG(DVDNAV, dvdnav-config)
487 translit(dnm, m, l) AM_CONDITIONAL(USE_ESD, true)
488 GST_CHECK_FEATURE(ESD, [esound plug-ins], esdsink esdmon, [
489 AM_PATH_ESD(0.2.12, HAVE_ESD=yes, HAVE_ESD=no)
492 dnl **** festival ****
493 dnl translit(dnm, m, l) AM_CONDITIONAL(USE_FESTIVAL, true)
494 dnl GST_CHECK_FEATURE(FESTIVAL, [festival plug-ins], festivalsrc, [
495 dnl NOTE: just using local net connection now, add this lib check
496 dnl in the future if needed
497 dnl AC_LANG_PUSH(C++)
498 dnl dnl FIXME: took out func to check for
499 dnl dnl This check puts festival_tidy_up in extern "C".
500 dnl dnl But, at least on Debian as of 20020110, it is compiled with name
501 dnl dnl mangling C++ nonsense and symbols can't resolve
502 dnl dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, festival_tidy_up, , festival/festival.h, FESTIVAL_LIBS="-lFestival")
503 dnl GST_CHECK_LIBHEADER(FESTIVAL, Festival, , , festival/festival.h, FESTIVAL_LIBS="-lFestival")
505 dnl AC_SUBST(FESTIVAL_LIBS)
506 dnl HAVE_FESTIVAL=yes
510 dnl FLAC 1.0.3 is needed
511 translit(dnm, m, l) AM_CONDITIONAL(USE_FLAC, true)
512 GST_CHECK_FEATURE(FLAC, [FLAC lossless audio], flacenc flacdec, [
513 GST_CHECK_LIBHEADER(FLAC, FLAC, FLAC__stream_decoder_new, -lm, FLAC/all.h, FLAC_LIBS="-lFLAC")
517 dnl *** Gnome VFS ***
518 translit(dnm, m, l) AM_CONDITIONAL(USE_GNOME_VFS, true)
519 GST_CHECK_FEATURE(GNOME_VFS, [Gnome VFS], gnomevfssrc, [
520 PKG_CHECK_MODULES(GNOME_VFS, gnome-vfs-2.0, HAVE_GNOME_VFS="yes", HAVE_GNOME_VFS="no")
521 AC_SUBST(GNOME_VFS_CFLAGS)
522 AC_SUBST(GNOME_VFS_LIBS)
526 translit(dnm, m, l) AM_CONDITIONAL(USE_GSM, true)
527 GST_CHECK_FEATURE(GSM, [GSM library], gsmenc gsmdec, [
528 GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm.h, GSM_LIBS="-lgsm")
529 if test $HAVE_GSM != "yes"; then
530 GST_CHECK_LIBHEADER(GSM, gsm, gsm_create, , gsm/gsm.h, GSM_LIBS="-lgsm")
531 if test $HAVE_GSM = "yes"; then
532 AC_DEFINE(GSM_HEADER_IN_SUBDIR, 1, [Define if GSM header in gsm/ subdir])
539 translit(dnm, m, l) AM_CONDITIONAL(USE_HERMES, true)
540 GST_CHECK_FEATURE(HERMES, [Hermes library], colorspace, [
541 GST_CHECK_LIBHEADER(HERMES, Hermes, Hermes_ConverterInstance, , Hermes/Hermes.h, HERMES_LIBS="-lHermes")
542 ], AC_SUBST(HERMES_LIBS))
545 translit(dnm, m, l) AM_CONDITIONAL(USE_HTTP, true)
546 GST_CHECK_FEATURE(HTTP, [http plug-ins], gsthttpsrc, [
547 dnl FIXME: need to check for header
549 GST_HTTPSRC_GET_TYPE=
550 if test x$USE_GLIB2 = xyes; then
551 AC_MSG_WARN(ghttp disabled for glib2.0)
553 AC_CHECK_LIB(ghttp, ghttp_request_new,
555 GST_HTTPSRC_GET_TYPE="gst_httpsrc_get_type"
560 AC_SUBST(GST_HTTPSRC_GET_TYPE)
564 translit(dnm, m, l) AM_CONDITIONAL(USE_JACK, true)
565 GST_CHECK_FEATURE(JACK, Jack, jack, [
566 PKG_CHECK_MODULES(JACK, jack >= 0.29.0, HAVE_JACK="yes", HAVE_JACK="no")
567 AC_SUBST(JACK_CFLAGS)
572 dnl FIXME: we could use header checks here as well IMO
573 translit(dnm, m, l) AM_CONDITIONAL(USE_JPEG, true)
574 GST_CHECK_FEATURE(JPEG, [jpeg], jpegenc jpegdec, [
575 AC_CHECK_LIB(jpeg, jpeg_set_defaults, HAVE_JPEG="yes", HAVE_JPEG="no")
581 translit(dnm, m, l) AM_CONDITIONAL(USE_LADSPA, true)
582 GST_CHECK_FEATURE(LADSPA, [ladspa], ladspa, [
583 AC_CHECK_HEADER(ladspa.h, HAVE_LADSPA="yes", HAVE_LADSPA="no")
587 translit(dnm, m, l) AM_CONDITIONAL(USE_LAME, true)
588 GST_CHECK_FEATURE(LAME, [lame mp3 encoder library], lame, [
589 GST_CHECK_LIBHEADER(LAME, mp3lame, lame_init, -lm, lame/lame.h, HAVE_LAME="yes" LAME_LIBS="-lmp3lame")
593 dnl *** libcolorspace ***
594 translit(dnm, m, l) AM_CONDITIONAL(USE_LCS, true)
595 GST_CHECK_FEATURE(LCS, Lcs, lcs, [
596 PKG_CHECK_MODULES(LCS, lcs, HAVE_LCS="yes", HAVE_LCS="no")
602 translit(dnm, m, l) AM_CONDITIONAL(USE_LIBFAME, true)
603 GST_CHECK_FEATURE(LIBFAME, [libfame MPEG1/4 encoder], libfame, [
604 AM_PATH_LIBFAME(0.9.0, HAVE_LIBFAME="yes", HAVE_LIBFAME="no")
605 AC_SUBST(LIBFAME_CFLAGS)
606 AC_SUBST(LIBFAME_LIBS)
610 dnl FIXME: we could use header checks here as well IMO
611 translit(dnm, m, l) AM_CONDITIONAL(USE_MAD, true)
612 GST_CHECK_FEATURE(MAD, [mad mp3 decoder], mad, [
613 AC_CHECK_LIB(mad, mad_decoder_finish, HAVE_MAD="yes" MAD_LIBS="-lmad")
614 if test "x$HAVE_MAD" = "xyes"; then
615 # installed with mad >= 0.14
619 AC_CHECK_LIB(id3tag, id3_tag_query, HAVE_MAD="yes" MAD_LIBS="$MAD_LIBS -lid3tag")
626 translit(dnm, m, l) AM_CONDITIONAL(USE_MIKMOD, true)
627 GST_CHECK_FEATURE(MIKMOD, [mikmod plug-in], mikmod, [
628 AM_PATH_LIBMIKMOD(, HAVE_MIKMOD=yes, HAVE_MIKMOD=no)
629 AC_SUBST(MIKMOD_LIBS, "$LIBMIKMOD_LIBS")
630 AC_SUBST(MIKMOD_CFLAGS, "$LIBMIKMODCFLAGS")
633 dnl *** mjpegtools ***
634 translit(dnm, m, l) AM_CONDITIONAL(USE_MJPEGTOOLS, true)
635 GST_CHECK_FEATURE(MJPEGTOOLS, [mjpegtools], jpegmmxenc jpegmmxdec, [
636 PKG_CHECK_MODULES(MJPEGTOOLS, mjpegtools, HAVE_MJPEGTOOLS="yes", HAVE_MJPEGTOOLS="no")
638 if [ test x$HAVE_MJPEGTOOLS = x"yes" ]; then
639 dnl some headers we might want to need
640 AC_CHECK_HEADERS(stdint.h, HAVE_STDINT_H="yes", HAVE_STDINT_H="no")
641 if [ test x$HAVE_STDINT_H = x"no" ]; then
642 AC_CHECK_HEADERS(inttypes.h sys/types.h, HAVE_INTTYPES_H="yes", [
643 AC_MSG_WARN(No valid header files found, mjpegtools plugins disabled)
644 HAVE_INTTYPES_H="no" HAVE_MJPEGTOOLS="no"
647 AC_CHECK_HEADERS(stdbool.h, HAVE_STDBOOL_H="yes", HAVE_STDBOOL_H="no")
649 dnl sizeof PRId64 etc...
651 AC_CHECK_SIZEOF(long)
652 AC_CHECK_SIZEOF(long long)
655 PRID64_STRING_FORMAT="d"
658 PRID64_STRING_FORMAT="ld"
660 $ac_cv_sizeof_long_long)
661 PRID64_STRING_FORMAT="lld"
664 AC_MSG_WARN(No suitable variant for 64bits integers found, mjpegtools plugins disabled)
669 AC_DEFINE_UNQUOTED(PRID64_STRING_FORMAT, "$PRID64_STRING_FORMAT",
670 [ A printf type definition for 64 bit integers ])
671 AC_SUBST(MJPEGTOOLS_LIBS)
672 AC_SUBST(MJPEGTOOLS_CFLAGS)
677 translit(dnm, m, l) AM_CONDITIONAL(USE_MPEG2DEC, true)
678 GST_CHECK_FEATURE(MPEG2DEC, [mpeg2dec], mpeg2dec, [
679 AC_CHECK_MPEG2DEC(HAVE_MPEG2DEC=yes, HAVE_MPEG2DEC=no)
682 dnl *** openquicktime ***
683 translit(dnm, m, l) AM_CONDITIONAL(USE_OPENQUICKTIME, true)
684 GST_CHECK_FEATURE(OPENQUICKTIME, [Open Quicktime], quicktime_parser quicktime_decoder quicktime_demux,[
685 GST_CHECK_LIBHEADER(OPENQUICKTIME, openquicktime, quicktime_init,, openquicktime/openquicktime.h, OPENQUICKTIME_LIBS="-lopenquicktime")
686 AC_SUBST(OPENQUICKTIME_LIBS)
690 translit(dnm, m, l) AM_CONDITIONAL(USE_RAW1394, true)
691 GST_CHECK_FEATURE(RAW1394, [raw1394 library], dv1394src, [
692 GST_CHECK_LIBHEADER(RAW1394, raw1394, raw1394_get_handle,, libraw1394/raw1394.h, RAW1394_LIBS="-raw1394")
693 AC_SUBST(RAW1394_LIBS)
697 dnl FIXME : adapt and make it work
698 translit(dnm, m, l) AM_CONDITIONAL(USE_RTP, true)
699 GST_CHECK_FEATURE(RTP, [RTP library], rtpenc rtpdec,[
700 AC_CHECK_LIB(ortp, ortp_init, HAVE_RTP=yes, HAVE_RTP=no, $GST_CFLAGS $GST_LIBS)
705 dnl FIXME header check needs to use GLIB_CFLAGS in order to succeed for rtp
706 dnl can use GST_* which should have GLIB_* info
707 dnl AC_CHECK_HEADERS(rtp/rtp.h, HAVE_LIBRTP=yes, HAVE_LIBRTP=no)
708 dnl AC_CHECK_HEADERS(rtp/rtp-packet.h, :, HAVE_LIBRTP=no)
709 dnl AC_CHECK_HEADERS(rtp/rtcp-packet.h, :, HAVE_LIBRTP=no)
710 dnl AC_CHECK_HEADERS(rtp/rtp-audio.h, :, HAVE_LIBRTP=no)
713 translit(dnm, m, l) AM_CONDITIONAL(USE_SDL, true)
714 GST_CHECK_FEATURE(SDL, [SDL plug-in], sdlvideosink, [
715 AM_PATH_SDL(, HAVE_SDL=yes, HAVE_SDL=no)
719 translit(dnm, m, l) AM_CONDITIONAL(USE_SHOUT, true)
720 GST_CHECK_FEATURE(SHOUT, [shout plug-in], icecastsend, [
721 GST_CHECK_LIBHEADER(SHOUT, shout, shout_init_connection,, shout/shout.h, SHOUT_LIBS="-lshout")
726 translit(dnm, m, l) AM_CONDITIONAL(USE_SIDPLAY, true)
727 GST_CHECK_FEATURE(SIDPLAY, [sidplay plug-in], sidplay, [
731 dnl *** smoothwave ***
732 translit(dnm, m, l) AM_CONDITIONAL(USE_SMOOTHWAVE, true)
733 GST_CHECK_FEATURE(SMOOTHWAVE, [smoothwave plug-in], smoothwave, [
734 if test $HAVE_GTK = "yes"; then HAVE_SMOOTHWAVE=yes; fi;
739 translit(dnm, m, l) AM_CONDITIONAL(USE_LIBPNG, true)
740 GST_CHECK_FEATURE(LIBPNG, [snapshot plug-in], snapshot, [
741 GST_CHECK_LIBHEADER(LIBPNG, png, png_read_info, -lz, png.h, LIBPNG_LIBS="-lpng -lz")
742 AC_SUBST(LIBPNG_LIBS)
746 translit(dnm, m, l) AM_CONDITIONAL(USE_SWFDEC, true)
747 GST_CHECK_FEATURE(SWFDEC, [swfdec plug-in], swfdec, [
748 PKG_CHECK_MODULES(SWFDEC, libswfdec, HAVE_SWFDEC="yes", HAVE_SWFDEC="no")
749 AC_SUBST(SWFDEC_CFLAGS)
750 AC_SUBST(SWFDEC_LIBS)
754 dnl for now the sources are included in the plug-in
755 dnl and should be moved to ext-libs/ perhaps
756 translit(dnm, m, l) AM_CONDITIONAL(USE_TARKIN, true)
757 GST_CHECK_FEATURE(TARKIN, [tarkinenc tarkindec], tarkin, [
762 dnl AM_PATH_VORBIS only takes two options
763 translit(dnm, m, l) AM_CONDITIONAL(USE_VORBIS, true)
764 GST_CHECK_FEATURE(VORBIS, [vorbis plug-in], vorbisenc vorbisdec, [
765 XIPH_PATH_VORBIS(HAVE_VORBIS=yes, HAVE_VORBIS=no)
769 translit(dnm, m, l) AM_CONDITIONAL(USE_XMMS, true)
770 GST_CHECK_FEATURE(XMMS, [xmms plug-in], xmms, [
771 AM_PATH_XMMS(0.1.0, HAVE_XMMS=yes, HAVE_XMMS=no)
774 fi dnl of EXT plugins
776 dnl Check for atomic.h
777 dnl Note: use AC_CHECK_HEADER not AC_CHECK_HEADERS, because the latter
778 dnl defines the wrong default symbol as well (HAVE_ASM_ATOMIC_H)
779 AC_CHECK_HEADER(asm/atomic.h, HAVE_ATOMIC_H=yes, HAVE_ATOMIC_H=no)
780 dnl Do a compile to check that it has atomic_set (eg, linux 2.0 didn't)
781 if test x$HAVE_ATOMIC_H = xyes; then
783 #include "asm/atomic.h"
784 main() { atomic_t t; atomic_set(&t,0); atomic_inc(&t); atomic_add(1,&t);return 0;}
787 if test x$HAVE_ATOMIC_H = xyes; then
788 AC_MSG_WARN(Atomic reference counting is out of date: doing without.)
794 AC_MSG_WARN(Can't check properly for atomic reference counting. Assuming OK.)
799 dnl ######################################################################
800 dnl # Check command line parameters, and set shell variables accordingly #
801 dnl ######################################################################
805 AC_ARG_ENABLE(libmmx,
806 AC_HELP_STRING([--enable-libmmx],[use libmmx, if available]),
807 [case "${enableval}" in
808 yes) USE_LIBMMX=$HAVE_LIBMMX ;;
810 *) AC_MSG_ERROR(bad value ${enableval} for --enable-libmmx) ;;
812 [USE_LIBMMX=$HAVE_LIBMMX]) dnl Default value
814 AC_ARG_ENABLE(atomic,
815 AC_HELP_STRING([--enable-atomic],[use atomic reference counting header]),
816 [case "${enableval}" in
817 yes) USE_ATOMIC_H=$HAVE_ATOMIC_H;;
818 noset) USE_ATOMIC_H=$HAVE_ATOMIC_H;;
819 no) USE_ATOMIC_H=no;;
820 *) AC_MSG_ERROR(bad value ${enableval} for --enable-atomic) ;;
822 [USE_ATOMIC_H=$HAVE_ATOMIC_H]) dnl Default value
824 AC_ARG_ENABLE(profiling,
825 AC_HELP_STRING([--enable-profiling],
826 [-pg to compiler commandline, for profiling]),
827 [case "${enableval}" in
828 yes) USE_PROFILING=yes ;;
829 no) UES_PROFILING=no ;;
830 *) AC_MSG_ERROR(bad value ${enableval} for --enable-profiling) ;;
832 [USE_PROFILING=no]) dnl Default value
835 AC_HELP_STRING([--disable-tests],[disable building test apps]),
836 [case "${enableval}" in
837 yes) BUILD_TESTS=yes ;;
838 no) BUILD_TESTS=no ;;
839 *) AC_MSG_ERROR(bad value ${enableval} for --disable-tests) ;;
841 [BUILD_TESTS=yes]) dnl Default value
843 AC_ARG_ENABLE(examples,
844 AC_HELP_STRING([--disable-examples],[disable building examples]),
845 [case "${enableval}" in
846 yes) BUILD_EXAMPLES=yes ;;
847 no) BUILD_EXAMPLES=no ;;
848 *) AC_MSG_ERROR(bad value ${enableval} for --disable-examples) ;;
850 [BUILD_EXAMPLES=yes]) dnl Default value
852 dnl seeking needs freetype, so check for it here
853 AC_CHECK_FT2(2.0.9,HAVE_FT2=yes,HAVE_FT2=no)
854 dnl make the HAVE_FT2 variable available to automake and Makefile.am
855 AM_CONDITIONAL(HAVE_FT2, test "x$HAVE_FT2" = "xyes")
859 dnl ################################################
860 dnl # Set defines according to variables set above #
861 dnl ################################################
864 if test "x$USE_LIBMMX" = xyes; then
865 AC_DEFINE(HAVE_LIBMMX, 1, [Define if libmmx is available])
868 if test "x$USE_ATOMIC_H" = xyes; then
869 AC_DEFINE(HAVE_ATOMIC_H, 1, [Define if atomic.h header file is available])
872 if test "x$USE_DEBUG" = xyes; then
873 GST_CFLAGS="$GST_CFLAGS -g"
876 if test "x$USE_PROFILING" = xyes; then
877 dnl CFLAGS="$CFLAGS -pg -fprofile-arcs"
878 FOMIT_FRAME_POINTER=""
880 FOMIT_FRAME_POINTER="-fomit-frame-pointer"
884 dnl AC_SUBST(FOMIT_FRAME_POINTER)
887 dnl #############################
888 dnl # Set automake conditionals #
889 dnl #############################
891 dnl These should be "USE_*" instead of "HAVE_*", but some packages expect
892 dnl HAVE_ and it is likely to be easier to stick with the old name
893 AM_CONDITIONAL(HAVE_CPU_I386, test "x$HAVE_CPU_I386" = "xyes")
894 AM_CONDITIONAL(HAVE_CPU_PPC, test "x$HAVE_CPU_PPC" = "xyes")
895 AM_CONDITIONAL(HAVE_CPU_ALPHA, test "x$HAVE_CPU_ALPHA" = "xyes")
896 AM_CONDITIONAL(HAVE_CPU_ARM, test "x$HAVE_CPU_ARM" = "xyes")
897 AM_CONDITIONAL(HAVE_CPU_SPARC, test "x$HAVE_CPU_SPARC" = "xyes")
898 AM_CONDITIONAL(HAVE_LIBMMX, test "x$USE_LIBMMX" = "xyes")
900 AM_CONDITIONAL(HAVE_ATOMIC_H, test "x$USE_ATOMIC_H" = "xyes")
902 AM_CONDITIONAL(EXPERIMENTAL, test "$EXPERIMENTAL" = "$xyes")
903 AM_CONDITIONAL(BROKEN, test "$BROKEN" = "$xyes")
905 AM_CONDITIONAL(HAVE_NASM, test "x$HAVE_NASM" = "xyes")
906 AM_CONDITIONAL(HAVE_GTK, test "x$HAVE_GTK" = "xyes")
907 AM_CONDITIONAL(HAVE_GTK_DOC, $HAVE_GTK_DOC)
908 AM_CONDITIONAL(BUILD_DOCS, test "x$BUILD_DOCS" = "xyes")
909 AM_CONDITIONAL(BUILD_TESTS, test "x$BUILD_TESTS" = "xyes")
910 AM_CONDITIONAL(BUILD_EXAMPLES, test "x$BUILD_EXAMPLES" = "xyes")
911 AM_CONDITIONAL(BUILD_PLUGIN_DOCS, test "x$BUILD_PLUGIN_DOCS" = "xyes")
912 AM_CONDITIONAL(HAVE_FIG2DEV_PNG, $HAVE_FIG2DEV_PNG)
913 AM_CONDITIONAL(HAVE_FIG2DEV_PDF, $HAVE_FIG2DEV_PDF)
914 AM_CONDITIONAL(HAVE_RAW1394, test "x$HAVE_RAW1394" = "xyes")
916 GST_CFLAGS="$GST_CFLAGS -I\$(top_srcdir)/gst-libs -Wall -Werror"
920 dnl #########################
921 dnl # Make the output files #
922 dnl #########################
924 dnl testsuite/autoplug/Makefile
925 dnl testsuite/Makefile
929 gstreamer-libs-uninstalled.pc
932 gst/ac3parse/Makefile
934 gst/audioscale/Makefile
937 gst/cdxaparse/Makefile
940 gst/deinterlace/Makefile
942 gst/festival/Makefile
946 gst/intfloat/Makefile
950 gst/mixmatrix/Makefile
951 gst/mpeg1enc/Makefile
952 gst/mpeg1sys/Makefile
953 gst/mpeg1videoparse/Makefile
954 gst/mpeg2enc/Makefile
955 gst/mpeg2sub/Makefile
956 gst/mpegaudio/Makefile
957 gst/mpegaudioparse/Makefile
958 gst/mpegstream/Makefile
959 gst/mpegtypes/Makefile
961 gst/modplug/libmodplug/Makefile
962 gst/monoscope/Makefile
963 gst/passthrough/Makefile
964 gst/playondemand/Makefile
970 gst/spectrum/Makefile
973 gst/stereomono/Makefile
974 gst/synaesthesia/Makefile
976 gst/videoscale/Makefile
977 gst/videotestsrc/Makefile
978 gst/videocrop/Makefile
982 gst/wavparse/Makefile
994 sys/videosink/Makefile
1001 ext/audiofile/Makefile
1002 ext/avifile/Makefile
1003 ext/cdparanoia/Makefile
1005 ext/dvdread/Makefile
1010 ext/gnomevfs/Makefile
1019 ext/libfame/Makefile
1022 ext/mjpegtools/Makefile
1023 ext/mpeg2dec/Makefile
1024 ext/openquicktime/Makefile
1025 ext/raw1394/Makefile
1029 ext/sidplay/Makefile
1030 ext/smoothwave/Makefile
1036 gst-libs/gst/Makefile
1037 gst-libs/gst/audio/Makefile
1038 gst-libs/gst/floatcast/Makefile
1039 gst-libs/gst/gconf/Makefile
1040 gst-libs/gst/idct/Makefile
1041 gst-libs/gst/resample/Makefile
1042 gst-libs/gst/riff/Makefile
1043 examples/dynparams/Makefile
1044 examples/capsfilter/Makefile
1045 examples/seeking/Makefile
1053 echo -e "configure: *** Plug-ins that will be built : $GST_PLUGINS_YES"
1055 echo -e "configure: *** Plug-ins that will not be built : $GST_PLUGINS_NO"
1057 if test "x$BUILD_EXTERNAL" = "xno"; then
1058 echo "configure: *** No external plug-ins will be built"