diff options
42 files changed, 8727 insertions, 0 deletions
diff --git a/common/ChangeLog b/common/ChangeLog new file mode 100644 index 0000000..bda46af --- /dev/null +++ b/common/ChangeLog @@ -0,0 +1,804 @@ +2015-03-23 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Remove echo that wrongly slipped in with my previous commit. + +2015-03-23 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Allow specify an specific CPU family with an optionar argument. + +2015-03-21 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Prepend the library path. + +2014-11-25 Andoni Morales <amorelas@fluendo.com> + + * m4/libtool.mk: + Rename function with the same name + +2014-11-25 Andoni Morales <amorelas@fluendo.com> + + * m4/libtool.mk: + Append flags at the end of the command + +2014-11-25 Andoni Morales <amorelas@fluendo.com> + + * m4/libtool.mk: + parse inherited_linker_flags and include them in them + in the link command + +2014-11-24 Andoni Morales <amorelas@fluendo.com> + + * m4/libtool.mk: + Add missing coma and include more debug + +2014-11-24 Andoni Morales <amorelas@fluendo.com> + + * m4/libtool.mk: + * m4/staticplugins.m4: + Add support for tunning GStreamer libraries + link type (static or dynamic) + +2014-11-11 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Silence GST_TRACE when building with old GStreamer versions. + +2014-11-04 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add missing backward compat definition. + +2014-10-13 Xavi Artigas <xartigas@fluendo.com> + + * gst-compat.h: + Fix even more warnings (this one, and the two previous commits, + are needed to build on Fedora5) + +2014-10-13 Xavi Artigas <xartigas@fluendo.com> + + * gst-demo.h: + Fix warning + +2014-10-13 Xavi Artigas <xartigas@fluendo.com> + + * gst-compat.h: + Fix warning + +2014-10-03 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Drop -ftree-vectorize that slipped into common by error while + experimenting with it. + +2014-09-26 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add gst_event_has_name replacement for older GStreamer 0.10 versions. + +2014-07-21 Xavi Artigas <xartigas@fluendo.com> + + * gst-demo.h: + Fix precedence of = and ==. This only triggered a problem when + compiling the h265 plugin, because it uses C++ and the result of + a == is a boolean, not an int which can be silently converted + to an enum. + +2014-06-19 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Provide replacement for gst_adapter_unmap in GStreamer 0.10. + +2014-05-14 Andoni Morales <amorales@fluendo.com> + + * m4/staticplugins.m4: + Add replacement for d3dvideosink + +2014-05-12 Andoni Morales <amorales@fluendo.com> + + * gst-compat.h: + Fix compiler error casting from gpointer to guint8 * + +2014-05-07 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add few more replacements for 0.10. + +2014-05-07 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add gst_buffer_new_wrapped replacement for 0.10. + +2014-04-02 Jorge Zapata <jzapata@fluendo.com> + + * m4/ipp.m4: + Do not use ipp on non-intel archs + +2014-04-01 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add a replacement for g_list_free_full in order to allow builds + with older glib2. + +2014-04-01 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Provide guintptr definition to allow builds wiht older glib2. + +2014-03-25 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add a replacement for gst_caps_steal_structure. + +2014-03-14 Jorge Zapata <jzapata@fluendo.com> + + * doc: + * doc/Doxyfile_common.in: + * doc/css: + * doc/css/stylesheet.css: + * doc/doxygen_to_devhelp.xsl: + * doc/footer.html: + * doc/header.html: + * doxygen.mak: + Add the documentation common files + +2014-01-28 Andoni Morales <amorales@fluendo.com> + + * m4/platform.m4: Add detection support for iOS + +2014-01-18 Julien Moutte <julien@fluendo.com> + + * m4/ipp.m4: when linking on Windows we need to make + sure that we pull symbols from MSVCRT instead of NTDLL. + Indeed I've seen sscanf from NTDLL seriously break and the + symbol was used from NTDLL because of our link flag from ipp. + +2014-01-16 Andoni Morales <amorales@fluendo.com> + + * m4/platform.m4: + Add solaris platform detection + +2013-12-27 Andoni Morales <amorales@fluendo.com> + + * wibu.m4: + Add framework search path for Mavericks + +2013-12-27 Andoni Morales <amorales@fluendo.com> + + * wibu.m4: + Fix library names in Windows + +2013-12-27 Xavi Artigas <xartigas@fluendo.com> + + * m4/wibu.m4: + Use correct WIBU CodeMeter Linux library. + +2013-12-24 Andoni Morales <amorales@fluendo.com> + + * wibu.m4: + Add an option to check for AxProtector, CodeMeter or both + +2013-12-24 Andoni Morales <amorales@fluendo.com> + + * platform.m4: + Add macro for platform detection + * wibu.m4: + Add macro for WIBU detection + +2013-12-20 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add gst_caps_set_value replacement for older GStreamer versions. + +2013-11-29 Julien Moutte <julien@fluendo.com> + + * fluendo-plugins-sdk.props: Prepare for 1.0 build while maintaining + backward compatibility with old project files. + +2013-11-25 Andoni Morales <amorales@fluendo.com> + + * m4/staticplugins.am: + Fix registry names for windows plugins + +2013-11-22 Andoni Morales <amorales@fluendo.com> + + * m4/libtool.mk: Remove '=' from search paths (as seen in windows) + +2013-11-15 Andoni Morales <amorales@fluendo.com> + + * m4/staticplugins.am: Use the more portable printf and + fix plugin regsitry entry point for osxvideosink + +2013-11-15 Andoni Morales <amorales@fluendo.com> + + * m4/libtool.mk: Add missing -l to shared libraries that don't have it + +2013-11-15 Andoni Morales <amorales@fluendo.com> + + * m4/libtool.mk: Import helper from the android ndk + * m4/staticplugins.am: + Add a new helper to transform a list of plugins into + a linker command linking gstreamer and its plugins + statically and the rest as shared libraries + +2013-11-15 Andoni Morales <amorales@fluendo.com> + + * m4/staticplugins.am: Automake helper for static plugins + +2013-11-04 Julien Moutte <julien@fluendo.com> + + * gst-demo.h: Need to include the base class for audio encoder. + +2013-11-04 Julien Moutte <julien@fluendo.com> + + * gst-demo.h: Fix small mistakes in my previous commit for 1.0. + +2013-11-04 Julien Moutte <julien@fluendo.com> + + * gst-compat.h: Add backward definition for GST_FLOW_EOS and _FLUSHING + * gst-demo.h: Add a demo handling function for audio encoder base class + Remove useless functions and fix a potential race occuring when EOS is + handled before ERROR from demo code. + +2013-10-04 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Support specific tunning flag introduced in gcc 4.8. + +2013-10-03 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Add cpu tunning for Marvell Dove. + +2013-10-03 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Add a flag to enable arm v6 conditional code. + +2013-09-26 Andoni Morales <amorales@fluendo.com> + + * m4/ipp.m4: + _allmul and _chkstk are symbols from ntdll.dll that + are not correctly defined in mingw's ntdll.def. + The fix is therefore in MinGW's generated libntdll.a + +2013-09-25 Andoni Morales <amorales@fluendo.com> + + * m4/ipp.m4: + Add libippmsvccpompat.a to the link providing the missing + allmul and chkstk stub symbols + +2013-09-25 Andoni Morales <amorales@fluendo.com> + + * m4/ipp.m4: + Don't use the hack for MinGW anymore and use instead + libtool libraries for the ipp libs to help the link + of the static libraries in a shared module in Windows + +2013-09-23 Andoni Morales <amorales@fluendo.com> + + * m4/gst-cpu-tune.m4: + Disable -znoexecstack for mingw + Fix pass of -no-undefined to libtool (not as a linker flag) + +2013-06-21 Andoni Morales <amorales@fluendo.com> + + * m4/gst-cpu-tune.m4: + Disable -ftree-vectorize, which conflicts with -fno-strict-aliasing + +2013-06-11 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Use same type in 0.10 and 1.0. + +2013-06-04 Andoni Morales <amorales@fluendo.com> + + * m4/ipp.m4: + Fix IPP_PREFIX in windows + +2013-06-04 Andoni Morales <amorales@fluendo.com> + + * m4/gst-static-plugin.m4: + Fix typo + +2013-06-04 Josep Torra <josep@fluendo.com> + + * gst-fluendo.h: + * m4/gst-static-plugin.m4: + Simplify support code for builing static plugins. + +2013-06-04 Josep Torra <josep@fluendo.com> + + * m4/gst-check.m4: + Allow to specify the GStreamer API version with the '--with-gstreamer-api' + configure flag. + +2013-06-03 Josep Torra <josep@fluendo.com> + + * m4/gst-error.m4: + Instead of disable deprecation warning just disable glib deprecations. + +2013-05-31 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Clarify that IPP Merged is only for Linux and Solaris. + +2013-05-31 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Rework on the IPP related macros. + +2013-05-22 Jorge Zapata <jzapata@fluendo.com> + + * gst-autogen.sh: + Accept --host as a valid argument to be provided to configure. + +2013-04-30 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/gst-cpu-tune.m4: + Fix build of dll's in Windows + +2013-04-18 Julien Moutte <julien@fluendo.com> + + * Makefile.am: Properly include gst-demo.h in tarballs. + * gst-demo.h: Make the default demo duration 3 minutes in case we + can't find the duration to be consistent. + +2013-04-10 Jorge Zapata <jzapata@fluendo.com> + + * gst-demo.h: + when setting up the statistics be sure to reset them first + Initialize the decoded time to zero after getting the real duration + +2013-04-10 Jorge Zapata <jzapata@fluendo.com> + + * gst-demo.h: + Split some functions to ease the demo developing on elements that are not decoders + +2013-04-09 Jorge Zapata <jzapata@fluendo.com> + + * gst-demo.h: + Add more demo helpers + Do not unref the buffer on check, only when pushing or finishing a buffer/frame + +2013-04-09 Jorge Zapata <jzapata@fluendo.com> + + * gst-demo.h: + Add video decoders specific demo functions + +2013-04-05 Jorge Zapata <jzapata@fluendo.com> + + * gst-demo.h: + * gst-fluendo.h: + Initial approach for demo support on GStreamer 1.0 + Split the demo code from the gst-fluendo.h header + Older demo macros do not provide the demo functionality anymore but + projects using it can still compile + +2013-02-18 Andoni Morales Alastruey <amorales@fluendo.com> + + * ipp_mingw.py: + More this script to a better place + +2013-02-18 Andoni Morales Alastruey <amorales@fluendo.com> + + * ipp_mingw.py: + Add script to install IPP's for mingw and cerbero + +2013-02-14 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Add some more ARM tunning options. + +2013-02-07 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add GST_FLOW_CUSTOM_SUCCESS definition for earlier GStreamer versions. + +2013-01-07 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/gst-static-plugin.m4: + Remove AS_CASE for older autotools + +2013-01-28 Josep Torra <josep@fluendo.com> + + * m4/gst-check.m4: + Change the macro to fallback to a default plugins base location. + +2013-01-23 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Allow use gst_buffer_map/_unmap sintax in GStreamer 0.10. + +2013-01-22 Xavi Artigas <xartigas@fluendo.com> + + * m4/gst-gettext.m4: + Add macro necessary for internationalization. + +2012-12-14 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Fixes macro by respecting the arguments. + +2012-10-09 Josep Torra <josep@fluendo.com> + + * m4/gst-check.m4: + Handle older GStreamer versions that doesn't provide .pc files + for audio/video libs. + +2012-10-03 Andoni Morales <amorales@fluendo.com> + + * gst-fluendo.h: + Use GST_VERSION_MAJOR instead of GST_VERSION_CHECK, which is not + defined before 0.10.18 + +2012-10-03 Andoni Morales <amorales@fluendo.com> + + * m4/gst-fluendo.h: + Fix GST_PLUGIN_DEFINE for 1.0 where the plugin name is not a string anymore + +2012-10-05 Josep Torra <josep@fluendo.com> + + * m4/gst-check.m4: + Add macros to check for audio and video libraries. + +2012-10-04 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add g_onece_enter/leave replacement bits for older GLib. + +2012-10-04 Josep Torra <josep@fluendo.com> + + * m4/gst-check.m4: + Minor fixes in the macros. + +2012-10-03 Andoni Morales <amorales@fluendo.com> + + * gst-fluendo.h: + * m4/gst-check.m4: + Fix includes for GST 1.0 + +2012-10-03 Andoni Morales <amorales@fluendo.com> + + * m4/gst-check.m4: + Define confitionals for makefiles and versions requirements + +2012-10-03 Andoni Morales <amorales@fluendo.com> + + * m4/gst-check.m4: + Add new macro for testing the gstreamer version + +2012-10-03 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add more backward compatibility bits. + +2012-10-02 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add more backward compatibility bits. + +2012-10-02 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add more backward compatibility bits. + +2012-10-02 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add more backward compatibility bits. + +2012-10-02 Josep Torra <josep@fluendo.com> + + * gst-fluendo.h: + Avoid colision by redefinition on gst-compat.h. + Keept here to be able build older releases. + +2012-10-02 Josep Torra <josep@fluendo.com> + + * gst-compat.h: + Add more backward compatibility bits. + +2012-07-19 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/ipp.m4: + Add a check for __int64 in windows + +2012-07-16 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/ipp.m4: + Don't override IPP_SUFFIX + +2012-07-16 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/ipp.m4: + Add a better support for static builds on windows + +2012-07-12 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/gst-static-plugins.m4: + Revert --disable-shared for static plugins + +2012-07-11 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/gst-static-plugins.m4: + Configure with --disable-shared too + +2012-07-10 Andoni Morales Alastruey <amorales@fluendo.com> + + * m4/ipp.m4: + Add support for MinGW builds in windows + +2012-06-22 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Tune ARM build some more. + +2012-05-15 Julien Moutte <julien@fluendo.com> + + * gst-compat.h: Add base adapter header for some function replacement. + +2012-05-15 Julien Moutte <julien@fluendo.com> + + * gst-compat.h: Add some more macros. + +2012-05-15 Julien Moutte <julien@fluendo.com> + + * gst-compat.h: Add some more macros. + * Makefile.am: Distribute the compat header. + +2012-05-15 Julien Moutte <julien@fluendo.com> + + * gst-compat.h: Add header file for conditional compat definitions. + +2012-04-13 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Move the code related to IPP_FUNC_PATH definition to the AG_CHECK_IPP + macro. + It allows to build older releases using the trunk common. + +2012-02-23 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Add some more CPU tune configure flags for ARM. + +2012-01-20 Josep Torra <josep@fluendo.com> + + * m4/gst-error.m4: + When building with -Wall -Werror, disable error on deprecation + warnings. This is a workaround to build with new glib versions + that have deprecated the threading API. + +2011-12-05 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Minor cosmetic changes on the enable VFP flag. + +2011-11-20 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Minor fixes in the macro related to ARM. + +2011-11-18 Josep Torra <josep@fluendo.com> + + * m4/gst-args.m4: + Minor fix in the macro to avoid an error when there's spaces + in the package name. + +2011-10-06 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Fix build in Mac OSX. + +2011-07-20 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Improve --enable-cpu-tune-atom to handle -march=atom available + in modern GCC versions. + +2011-06-29 Jorge Zapata <jzapata@fluendo.com> + + * m4/ipp.m4: + Add the thread safe variant for ipp + +2011-06-28 Jorge Zapata <jzapata@fluendo.com> + + * m4/ipp.m4: + Always put ippcore at the end + +2011-06-27 Jorge Zapata <jzapata@fluendo.com> + + * m4/ipp.m4: + Add a common function to set the needed IPP variables, just pass + the list of IPP libraries you need to include + +2011-05-25 Josep Torra <josep@fluendo.com> + + * gst-autogen.sh: + Accept --build as a valid argument to be provided to configure. + +2011-04-01 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Fix location for IPP 7 in Mac OSX. + +2011-03-31 Jorge Zapata <jzapata@fluendo.com> + + * gst-fluendo.h: + Modify the limits to 3 minuts minimum and 30 minuts maximum + Use the gstreamer macros to make the code more readable + +2011-02-09 Jorge Zapata <jzapata@fluendo.com> + + * m4/gst-demo-plugin.m4: + Always define the ENABLE_DEMO_PLUGIN with the correct value + +2009-12-18 Thijs Vermeir <thijs@fluendo.com> + + * m4/gst-static-plugin.m4: Don't loose prev CFLAGS when + using --enable-static-plugin + +2009-09-29 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Added some stuff to build with IPP in Mac OS X. + +2009-06-05 Josep Torra <josep@fluendo.com> + + * m4/gst-fionread.m4: + Fix 'suspicious cache id' warnings. + +2009-02-20 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + * m4/ipp.m4: + Added helpers to do builds for Intel Atom and IPP/lp32. + +2009-02-05 Sergi Alvarez <salvarez@fluendo.com> + + * Makefile.am: Add gst-fluendo.h in EXTRA_DIST + +2009-01-20 Sergi Alvarez <salvarez@fluendo.com> + + * gst-fluendo.h: #if -> #ifdef + +2009-01-20 Sergi Alvarez <salvarez@fluendo.com> + + * m4/gst-static-plugin.m4: Rename AG_GST_STATIC.. to AG_GST_ARG_STATIC.. + +2009-01-20 Sergi Alvarez <salvarez@fluendo.com> + + * gst-fluendo.h: Initial import of the fluendo 'static-plugin' macro + * m4/gst-static-plugin.m4: Add --enable-static-plugin flag (implemented + in AG_GST_STATIC_PLUGIN m4 macro) + +2009-01-17 Julien Moutte <julien@fluendo.com> + + * m4/gst-cpu-tune.m4: Darwin does not have the execstack flag. + Fix the macro. + +2008-11-28 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Fix IPP version sorting. + +2008-11-26 Josep Torra <josep@fluendo.com> + + * m4/ipp.m4: + Added IPP emt64 single architectures. + +2008-11-26 Josep Torra <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + No execstack fixed for solaris. + +2008-10-15 Sergi Alvarez <salvarez@fluendo.com> + + * m4/Makefile.am: Drop cflags.m4 + * m4/cflags.m4: Removed file + * m4/gst-cpu-tune.m4: Merge cflags.m4 here. Add SunCC check + +2008-10-15 Sergi Alvarez <salvarez@fluendo.com> + + * m4/Makefile.am: Include cflags.m4 for extra-dist + * m4/cflags.m4: Initial import of the global cflags/ldflags setup + +2008-06-17 Paul Brossier <piem@fluendo.com> + + * m4/ipp.m4: if --without-ipp is used, define HAVE_IPP to false + +2008-06-09 Paul Brossier <piem@fluendo.com> + + * m4/ipp.m4: add AG_CHECK_IPP macro to check for Intel Integrated + Performance Primitives (IPP). + +2007-11-14 Christophe Eymard <ceymard@fluendo.com> + + * m4/gst-cpu-tune.m4: + Added support for -xO5 for Solaris (default optimization is not + added by the autotools) + * m4/gst-error.m4: + In solaris, added -features=no%extinl to treat extern inlines + as they used to be. + +2007-11-07 Josep Torra Valles <josep@fluendo.com> + + * m4/gst-check.m4: + Add POST_10_11 to POST_10_14. + Patch provided by Christophe Eymard <ceymard@fluendo.com> + +2007-10-24 Josep Torra Valles <josep@fluendo.com> + + * m4/gst-check.m4: + When gstreamer version is checked, check for >= 0.10.10 and set + POST_10_10 on config.h + +2007-09-03 Josep Torra Valles <josep@fluendo.com> + + * m4/gst-cpu-tune.m4: + Added -fomit-frame-pointer at tunning profile for N800. + +2007-08-29 Josep Torra Valles <josep@fluendo.com> + + * m4/Makefile.am: + * m4/gst-cpu-tune.m4: + Added to make easier add plataform specific build flags. + +2007-05-23 Edward Hervey <edward@fluendo.com> + + * m4/ax_create_stdint_h.m4: + Added from gstreamer common. + Needed for gst-fluendo-wmaenc. + +2007-05-14 Josep Torra Valles <josep@fluendo.com> + + * m4/check.m4: + Added to make projects compile under sbox. + +2007-04-10 Thomas Vander Stichele <thomas at apestaart dot org> + + * m4/gst-check.m4: + Allow pre-setting the GST(PB)_TOOLS/PLUGINS_DIR variables to help + builds against older GStreamer. + +2007-02-28 Thomas Vander Stichele <thomas at apestaart dot org> + + * m4/as-ac-expand.m4: + * m4/gst-plugindir.m4: + * m4/gst-args.m4: + * m4/Makefile.am + add these macros + +2007-02-28 Thomas Vander Stichele <thomas at apestaart dot org> + + * m4/as-version.m4: + update AS_VERSION. Needs updating configure.ac in all + Fluendo GStreamer modules too. + +2007-02-28 Thomas Vander Stichele <thomas at apestaart dot org> + + * update to new AG_GST style macros + * add gst-args, gst-valgrind, gst-check + +2007-02-28 Thomas Vander Stichele <thomas at apestaart dot org> + + * add check.mak and gst.supp + +2006-10-10 Josep Torra Valles <josep@fluendo.com> + + * m4/gst-fionread.m4: + adding a copy of the check macro + +2006-05-30 Thomas Vander Stichele <thomas at apestaart dot org> + + * m4/gst-error.m4: + adding a copy of the error macro + +2006-03-30 Thomas Vander Stichele <thomas at apestaart dot org> + + * share among modules + + diff --git a/common/Makefile.am b/common/Makefile.am new file mode 100644 index 0000000..8474ccd --- /dev/null +++ b/common/Makefile.am @@ -0,0 +1,3 @@ +SUBDIRS = m4 + +EXTRA_DIST = ChangeLog gettext.patch glib-gen.mak release.mak gst-autogen.sh gst-fluendo.h gst-compat.h gst-demo.h diff --git a/common/check.mak b/common/check.mak new file mode 100644 index 0000000..428b277 --- /dev/null +++ b/common/check.mak @@ -0,0 +1,148 @@ +clean-local-check: + for i in `find . -name ".libs" -type d`; do \ + rm -rf $$i; \ + done + +if HAVE_VALGRIND +# hangs spectacularly on some machines, so let's not do this by default yet +check-valgrind: + make valgrind +else +check-valgrind: + @true +endif + +LOOPS = 10 + +# run any given test by running make test.check +# if the test fails, run it again at at least debug level 2 +%.check: % + @$(TESTS_ENVIRONMENT) \ + CK_DEFAULT_TIMEOUT=20 \ + $* || \ + $(TESTS_ENVIRONMENT) \ + GST_DEBUG=$$GST_DEBUG,*:2 \ + CK_DEFAULT_TIMEOUT=20 \ + $* + +# run any given test in a loop +%.torture: % + @for i in `seq 1 $(LOOPS)`; do \ + $(TESTS_ENVIRONMENT) \ + CK_DEFAULT_TIMEOUT=20 \ + $*; done + +# run any given test in an infinite loop +%.forever: % + @while true; do \ + $(TESTS_ENVIRONMENT) \ + CK_DEFAULT_TIMEOUT=20 \ + $* || break; done + +# valgrind any given test by running make test.valgrind +%.valgrind: % + $(TESTS_ENVIRONMENT) \ + CK_DEFAULT_TIMEOUT=360 \ + G_SLICE=always-malloc \ + libtool --mode=execute \ + $(VALGRIND_PATH) -q \ + $(foreach s,$(SUPPRESSIONS),--suppressions=$(s)) \ + --tool=memcheck --leak-check=full --trace-children=yes \ + --leak-resolution=high --num-callers=20 \ + ./$* 2>&1 | tee valgrind.log + @if grep "==" valgrind.log > /dev/null 2>&1; then \ + rm valgrind.log; \ + exit 1; \ + fi + @rm valgrind.log + +# valgrind any given test and generate suppressions for it +%.valgrind.gen-suppressions: % + $(TESTS_ENVIRONMENT) \ + CK_DEFAULT_TIMEOUT=60 \ + libtool --mode=execute \ + $(VALGRIND_PATH) -q \ + $(foreach s,$(SUPPRESSIONS),--suppressions=$(s)) \ + --tool=memcheck --leak-check=full --trace-children=yes \ + --leak-resolution=high --num-callers=20 \ + --gen-suppressions=all \ + ./$* 2>&1 | tee suppressions.log + +# valgrind any given test until failure by running make test.valgrind-forever +%.valgrind-forever: % + @while make $*.valgrind; do \ + true; done + +# gdb any given test by running make test.gdb +%.gdb: % + $(TESTS_ENVIRONMENT) \ + CK_FORK=no \ + libtool --mode=execute \ + gdb $* + +# torture tests +torture: $(TESTS) + -rm test-registry.xml + @echo "Torturing tests ..." + for i in `seq 1 $(LOOPS)`; do \ + make check || \ + (echo "Failure after $$i runs"; exit 1) || \ + exit 1; \ + done + @banner="All $(LOOPS) loops passed"; \ + dashes=`echo "$$banner" | sed s/./=/g`; \ + echo $$dashes; echo $$banner; echo $$dashes + +# forever tests +forever: $(TESTS) + -rm test-registry.xml + @echo "Forever tests ..." + while true; do \ + make check || \ + (echo "Failure"; exit 1) || \ + exit 1; \ + done + +# valgrind all tests +valgrind: $(TESTS) + @echo "Valgrinding tests ..." + @failed=0; \ + for t in $(filter-out $(VALGRIND_TESTS_DISABLE),$(TESTS)); do \ + make $$t.valgrind; \ + if test "$$?" -ne 0; then \ + echo "Valgrind error for test $$t"; \ + failed=`expr $$failed + 1`; \ + whicht="$$whicht $$t"; \ + fi; \ + done; \ + if test "$$failed" -ne 0; then \ + echo "$$failed tests had leaks or errors under valgrind:"; \ + echo "$$whicht"; \ + false; \ + fi + +# inspect every plugin feature +GST_INSPECT = $(GST_TOOLS_DIR)/gst-inspect-$(GST_MAJORMINOR) +inspect: + @echo "Inspecting features ..." + for e in `$(TESTS_ENVIRONMENT) $(GST_INSPECT) | head -n -2 \ + | cut -d: -f2`; \ + do echo Inspecting $$e; \ + $(GST_INSPECT) $$e > /dev/null 2>&1; done + +help: + @echo "make check -- run all checks" + @echo "make torture -- run all checks $(LOOPS) times" + @echo "make (dir)/(test).check -- run the given check once" + @echo "make (dir)/(test).forever -- run the given check forever" + @echo "make (dir)/(test).torture -- run the given check $(LOOPS) times" + @echo + @echo "make (dir)/(test).gdb -- start up gdb for the given test" + @echo + @echo "make valgrind -- valgrind all tests" + @echo "make (dir)/(test).valgrind -- valgrind the given test" + @echo "make (dir)/(test).valgrind-forever -- valgrind the given test forever" + @echo "make (dir)/(test).valgrind.gen-suppressions -- generate suppressions" + @echo " and save to suppressions.log" + @echo "make inspect -- inspect all plugin features" + diff --git a/common/doc/Doxyfile_common.in b/common/doc/Doxyfile_common.in new file mode 100644 index 0000000..fec48bd --- /dev/null +++ b/common/doc/Doxyfile_common.in @@ -0,0 +1,1856 @@ +# Common Doxyfile 1.8.3.1 definitions +# include this file on the AC_CONFIG_FILES and be sure +# to include on your own Doxyfile + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all +# text before the first occurrence of this tag. Doxygen uses libiconv (or the +# iconv built into libc) for the transcoding. See +# http://www.gnu.org/software/libiconv for the list of possible encodings. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or sequence of words) that should +# identify the project. Note that if you do not use Doxywizard you need +# to put quotes around the project name if it contains spaces. + +PROJECT_NAME = @PACKAGE_NAME@ + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. +# This could be handy for archiving the generated documentation or +# if some version control system is used. + +PROJECT_NUMBER = @PACKAGE_VERSION@ + +# With the PROJECT_LOGO tag one can specify an logo or icon that is +# included in the documentation. The maximum height of the logo should not +# exceed 55 pixels and the maximum width should not exceed 200 pixels. +# Doxygen will copy the logo to the output directory. + +PROJECT_LOGO = + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) +# base path where the generated documentation will be put. +# If a relative path is entered, it will be relative to the location +# where doxygen was started. If left blank the current directory will be used. + +OUTPUT_DIRECTORY = doc + +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create +# 4096 sub-directories (in 2 levels) under the output directory of each output +# format and will distribute the generated files over these directories. +# Enabling this option can be useful when feeding doxygen a huge amount of +# source files, where putting all generated files in the same directory would +# otherwise cause performance problems for the file system. + +CREATE_SUBDIRS = NO + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# The default language is English, other supported languages are: +# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, +# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German, +# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English +# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, +# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrillic, Slovak, +# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will +# include brief member descriptions after the members that are listed in +# the file and class documentation (similar to JavaDoc). +# Set to NO to disable this. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend +# the brief description of a member or function before the detailed description. +# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. + +REPEAT_BRIEF = YES + +# This tag implements a quasi-intelligent brief description abbreviator +# that is used to form the text in various listings. Each string +# in this list, if found as the leading text of the brief description, will be +# stripped from the text and the result after processing the whole list, is +# used as the annotated text. Otherwise, the brief description is used as-is. +# If left blank, the following values are used ("$name" is automatically +# replaced with the name of the entity): "The $name class" "The $name widget" +# "The $name file" "is" "provides" "specifies" "contains" +# "represents" "a" "an" "the" + +ABBREVIATE_BRIEF = + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# Doxygen will generate a detailed section even if there is only a brief +# description. + +ALWAYS_DETAILED_SEC = YES + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full +# path before files name in the file list and in the header files. If set +# to NO the shortest path that makes the file name unique will be used. + +FULL_PATH_NAMES = YES + +# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag +# can be used to strip a user-defined part of the path. Stripping is +# only done if one of the specified strings matches the left-hand part of +# the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the +# path to strip. Note that you specify absolute paths here, but also +# relative paths, which will be relative from the directory where doxygen is +# started. + +STRIP_FROM_PATH = + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of +# the path mentioned in the documentation of a class, which tells +# the reader which header file to include in order to use a class. +# If left blank only the name of the header file containing the class +# definition is used. Otherwise one should specify the include paths that +# are normally passed to the compiler using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter +# (but less readable) file names. This can be useful if your file system +# doesn't support long names like on DOS, Mac, or CD-ROM. + +SHORT_NAMES = NO + +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen +# will interpret the first line (until the first dot) of a JavaDoc-style +# comment as the brief description. If set to NO, the JavaDoc +# comments will behave just like regular Qt-style comments +# (thus requiring an explicit @brief command for a brief description.) + +JAVADOC_AUTOBRIEF = NO + +# If the QT_AUTOBRIEF tag is set to YES then Doxygen will +# interpret the first line (until the first dot) of a Qt-style +# comment as the brief description. If set to NO, the comments +# will behave just like regular Qt-style comments (thus requiring +# an explicit \brief command for a brief description.) + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen +# treat a multi-line C++ special comment block (i.e. a block of //! or /// +# comments) as a brief description. This used to be the default behaviour. +# The new default is to treat a multi-line C++ comment block as a detailed +# description. Set this tag to YES if you prefer the old behaviour instead. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented +# member inherits the documentation from any documented member that it +# re-implements. + +INHERIT_DOCS = YES + +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce +# a new page for each member. If set to NO, the documentation of a member will +# be part of the file/class/namespace that contains it. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. +# Doxygen uses this value to replace tabs by spaces in code fragments. + +TAB_SIZE = 4 + +# This tag can be used to specify a number of aliases that acts +# as commands in the documentation. An alias has the form "name=value". +# For example adding "sideeffect=\par Side Effects:\n" will allow you to +# put the command \sideeffect (or @sideeffect) in the documentation, which +# will result in a user-defined paragraph with heading "Side Effects:". +# You can put \n's in the value part of an alias to insert newlines. + +ALIASES = + +# This tag can be used to specify a number of word-keyword mappings (TCL only). +# A mapping has the form "name=value". For example adding +# "class=itcl::class" will allow you to use the command class in the +# itcl::class meaning. + +TCL_SUBST = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C +# sources only. Doxygen will then generate output that is more tailored for C. +# For instance, some of the names that are used will be different. The list +# of all members will be omitted, etc. + +OPTIMIZE_OUTPUT_FOR_C = YES + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java +# sources only. Doxygen will then generate output that is more tailored for +# Java. For instance, namespaces will be presented as packages, qualified +# scopes will look different, etc. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources only. Doxygen will then generate output that is more tailored for +# Fortran. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for +# VHDL. + +OPTIMIZE_OUTPUT_VHDL = NO + +# Doxygen selects the parser to use depending on the extension of the files it +# parses. With this tag you can assign which parser to use for a given +# extension. Doxygen has a built-in mapping, but you can override or extend it +# using this tag. The format is ext=language, where ext is a file extension, +# and language is one of the parsers supported by doxygen: IDL, Java, +# Javascript, CSharp, C, C++, D, PHP, Objective-C, Python, Fortran, VHDL, C, +# C++. For instance to make doxygen treat .inc files as Fortran files (default +# is PHP), and .f files as C (default is Fortran), use: inc=Fortran f=C. Note +# that for custom extensions you also need to set FILE_PATTERNS otherwise the +# files are not read by doxygen. + +EXTENSION_MAPPING = + +# If MARKDOWN_SUPPORT is enabled (the default) then doxygen pre-processes all +# comments according to the Markdown format, which allows for more readable +# documentation. See http://daringfireball.net/projects/markdown/ for details. +# The output of markdown processing is further processed by doxygen, so you +# can mix doxygen, HTML, and XML commands with Markdown formatting. +# Disable only in case of backward compatibilities issues. + +MARKDOWN_SUPPORT = YES + +# When enabled doxygen tries to link words that correspond to documented classes, +# or namespaces to their corresponding documentation. Such a link can be +# prevented in individual cases by by putting a % sign in front of the word or +# globally by setting AUTOLINK_SUPPORT to NO. + +AUTOLINK_SUPPORT = YES + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should +# set this tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. +# func(std::string) {}). This also makes the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. + +BUILTIN_STL_SUPPORT = NO + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. +# Doxygen will parse them like normal C++ but will assume all classes use public +# instead of private inheritance when no explicit protection keyword is present. + +SIP_SUPPORT = NO + +# For Microsoft's IDL there are propget and propput attributes to indicate +# getter and setter methods for a property. Setting this option to YES (the +# default) will make doxygen replace the get and set methods by a property in +# the documentation. This will only work if the methods are indeed getting or +# setting a simple type. If this is not the case, or you want to show the +# methods anyway, you should set this option to NO. + +IDL_PROPERTY_SUPPORT = YES + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES, then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES (the default) to allow class member groups of +# the same type (for instance a group of public functions) to be put as a +# subgroup of that type (e.g. under the Public Functions section). Set it to +# NO to prevent subgrouping. Alternatively, this can be done per class using +# the \nosubgrouping command. + +SUBGROUPING = YES + +# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and +# unions are shown inside the group in which they are included (e.g. using +# @ingroup) instead of on a separate page (for HTML and Man pages) or +# section (for LaTeX and RTF). + +INLINE_GROUPED_CLASSES = YES + +# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and +# unions with only public data fields will be shown inline in the documentation +# of the scope in which they are defined (i.e. file, namespace, or group +# documentation), provided this scope is documented. If set to NO (the default), +# structs, classes, and unions are shown on a separate page (for HTML and Man +# pages) or section (for LaTeX and RTF). + +INLINE_SIMPLE_STRUCTS = YES + +# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum +# is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically +# be useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. + +TYPEDEF_HIDES_STRUCT = YES + +# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to +# determine which symbols to keep in memory and which to flush to disk. +# When the cache is full, less often used symbols will be written to disk. +# For small to medium size projects (<1000 input files) the default value is +# probably good enough. For larger projects a too small cache size can cause +# doxygen to be busy swapping symbols to and from disk most of the time +# causing a significant performance penalty. +# If the system has enough physical memory increasing the cache will improve the +# performance by keeping more symbols in memory. Note that the value works on +# a logarithmic scale so increasing the size by one will roughly double the +# memory usage. The cache size is given by this formula: +# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0, +# corresponding to a cache size of 2^16 = 65536 symbols. + +SYMBOL_CACHE_SIZE = 0 + +# Similar to the SYMBOL_CACHE_SIZE the size of the symbol lookup cache can be +# set using LOOKUP_CACHE_SIZE. This cache is used to resolve symbols given +# their name and scope. Since this can be an expensive process and often the +# same symbol appear multiple times in the code, doxygen keeps a cache of +# pre-resolved symbols. If the cache is too small doxygen will become slower. +# If the cache is too large, memory is wasted. The cache size is given by this +# formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range is 0..9, the default is 0, +# corresponding to a cache size of 2^16 = 65536 symbols. + +LOOKUP_CACHE_SIZE = 0 + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. +# Private class members and static file members will be hidden unless +# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES + +EXTRACT_ALL = NO + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class +# will be included in the documentation. + +EXTRACT_PRIVATE = NO + +# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal +# scope will be included in the documentation. + +EXTRACT_PACKAGE = NO + +# If the EXTRACT_STATIC tag is set to YES all static members of a file +# will be included in the documentation. + +EXTRACT_STATIC = NO + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) +# defined locally in source files will be included in the documentation. +# If set to NO only classes defined in header files are included. + +EXTRACT_LOCAL_CLASSES = NO + +# This flag is only useful for Objective-C code. When set to YES local +# methods, which are defined in the implementation section but not in +# the interface are included in the documentation. +# If set to NO (the default) only methods in the interface are included. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base +# name of the file that contains the anonymous namespace. By default +# anonymous namespaces are hidden. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all +# undocumented members of documented classes, files or namespaces. +# If set to NO (the default) these members will be included in the +# various overviews, but no documentation section is generated. +# This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. +# If set to NO (the default) these classes will be included in the various +# overviews. This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all +# friend (class|struct|union) declarations. +# If set to NO (the default) these declarations will be included in the +# documentation. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any +# documentation blocks found inside the body of a function. +# If set to NO (the default) these blocks will be appended to the +# function's detailed documentation block. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation +# that is typed after a \internal command is included. If the tag is set +# to NO (the default) then the documentation will be excluded. +# Set it to YES to include the internal documentation. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate +# file names in lower-case letters. If set to YES upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. + +CASE_SENSE_NAMES = YES + +# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen +# will show members with their full class and namespace scopes in the +# documentation. If set to YES the scope will be hidden. + +HIDE_SCOPE_NAMES = NO + +# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen +# will put a list of the files that are included by a file in the documentation +# of that file. + +SHOW_INCLUDE_FILES = YES + +# If the FORCE_LOCAL_INCLUDES tag is set to YES then Doxygen +# will list include files with double quotes in the documentation +# rather than with sharp brackets. + +FORCE_LOCAL_INCLUDES = NO + +# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] +# is inserted in the documentation for inline members. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen +# will sort the (detailed) documentation of file and class members +# alphabetically by member name. If set to NO the members will appear in +# declaration order. + +SORT_MEMBER_DOCS = NO + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the +# brief documentation of file, namespace and class members alphabetically +# by member name. If set to NO (the default) the members will appear in +# declaration order. + +SORT_BRIEF_DOCS = NO + +# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen +# will sort the (brief and detailed) documentation of class members so that +# constructors and destructors are listed first. If set to NO (the default) +# the constructors will appear in the respective orders defined by +# SORT_MEMBER_DOCS and SORT_BRIEF_DOCS. +# This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO +# and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO. + +SORT_MEMBERS_CTORS_1ST = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the +# hierarchy of group names into alphabetical order. If set to NO (the default) +# the group names will appear in their defined order. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be +# sorted by fully-qualified names, including namespaces. If set to +# NO (the default), the class list will be sorted only by class name, +# not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the +# alphabetical list. + +SORT_BY_SCOPE_NAME = NO + +# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to +# do proper type resolution of all parameters of a function it will reject a +# match between the prototype and the implementation of a member function even +# if there is only one candidate or it is obvious which candidate to choose +# by doing a simple string match. By disabling STRICT_PROTO_MATCHING doxygen +# will still accept a match between prototype and implementation in such cases. + +STRICT_PROTO_MATCHING = NO + +# The GENERATE_TODOLIST tag can be used to enable (YES) or +# disable (NO) the todo list. This list is created by putting \todo +# commands in the documentation. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable (YES) or +# disable (NO) the test list. This list is created by putting \test +# commands in the documentation. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable (YES) or +# disable (NO) the bug list. This list is created by putting \bug +# commands in the documentation. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or +# disable (NO) the deprecated list. This list is created by putting +# \deprecated commands in the documentation. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional +# documentation sections, marked by \if section-label ... \endif +# and \cond section-label ... \endcond blocks. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines +# the initial value of a variable or macro consists of for it to appear in +# the documentation. If the initializer consists of more lines than specified +# here it will be hidden. Use a value of 0 to hide initializers completely. +# The appearance of the initializer of individual variables and macros in the +# documentation can be controlled using \showinitializer or \hideinitializer +# command in the documentation regardless of this setting. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated +# at the bottom of the documentation of classes and structs. If set to YES the +# list will mention the files that were used to generate the documentation. + +SHOW_USED_FILES = YES + +# Set the SHOW_FILES tag to NO to disable the generation of the Files page. +# This will remove the Files entry from the Quick Index and from the +# Folder Tree View (if specified). The default is YES. + +SHOW_FILES = YES + +# Set the SHOW_NAMESPACES tag to NO to disable the generation of the +# Namespaces page. +# This will remove the Namespaces entry from the Quick Index +# and from the Folder Tree View (if specified). The default is YES. + +SHOW_NAMESPACES = YES + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command <command> <input-file>, where <command> is the value of +# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file +# provided by doxygen. Whatever the program writes to standard output +# is used as the file version. See the manual for examples. + +FILE_VERSION_FILTER = + +# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed +# by doxygen. The layout file controls the global structure of the generated +# output files in an output format independent way. To create the layout file +# that represents doxygen's defaults, run doxygen with the -l option. +# You can optionally specify a file name after the option, if omitted +# DoxygenLayout.xml will be used as the name of the layout file. + +LAYOUT_FILE = + +# The CITE_BIB_FILES tag can be used to specify one or more bib files +# containing the references data. This must be a list of .bib files. The +# .bib extension is automatically appended if omitted. Using this command +# requires the bibtex tool to be installed. See also +# http://en.wikipedia.org/wiki/BibTeX for more info. For LaTeX the style +# of the bibliography can be controlled using LATEX_BIB_STYLE. To use this +# feature you need bibtex and perl available in the search path. Do not use +# file names with spaces, bibtex cannot handle them. + +CITE_BIB_FILES = + +#--------------------------------------------------------------------------- +# configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated +# by doxygen. Possible values are YES and NO. If left blank NO is used. + +QUIET = NO + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated by doxygen. Possible values are YES and NO. If left blank +# NO is used. + +WARNINGS = YES + +# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings +# for undocumented members. If EXTRACT_ALL is set to YES then this flag will +# automatically be disabled. + +WARN_IF_UNDOCUMENTED = YES + +# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some +# parameters in a documented function, or documenting parameters that +# don't exist or using markup commands wrongly. + +WARN_IF_DOC_ERROR = YES + +# The WARN_NO_PARAMDOC option can be enabled to get warnings for +# functions that are documented, but have no documentation for their parameters +# or return value. If set to NO (the default) doxygen will only warn about +# wrong or incomplete parameter documentation, but not about the absence of +# documentation. + +WARN_NO_PARAMDOC = YES + +# The WARN_FORMAT tag determines the format of the warning messages that +# doxygen can produce. The string should contain the $file, $line, and $text +# tags, which will be replaced by the file and line number from which the +# warning originated and the warning text. Optionally the format may contain +# $version, which will be replaced by the version of the file (if it could +# be obtained via FILE_VERSION_FILTER) + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning +# and error messages should be written. If left blank the output is written +# to stderr. + +WARN_LOGFILE = + +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag can be used to specify the files and/or directories that contain +# documented source files. You may enter file names like "myfile.cpp" or +# directories like "/usr/src/myproject". Separate the files or directories +# with spaces. + +INPUT = + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is +# also the default input encoding. Doxygen uses libiconv (or the iconv built +# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for +# the list of possible encodings. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank the following patterns are tested: +# *.c *.cc *.cxx *.cpp *.c++ *.d *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh +# *.hxx *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.dox *.py +# *.f90 *.f *.for *.vhd *.vhdl + +FILE_PATTERNS = + +# The RECURSIVE tag can be used to turn specify whether or not subdirectories +# should be searched for input files as well. Possible values are YES and NO. +# If left blank NO is used. + +RECURSIVE = YES + +# The EXCLUDE tag can be used to specify files and/or directories that should be +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. +# Note that relative paths are relative to the directory from which doxygen is +# run. + +EXCLUDE = + +# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or +# directories that are symbolic links (a Unix file system feature) are excluded +# from the input. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. Note that the wildcards are matched +# against the file with absolute path, so to exclude all test directories +# for example use the pattern */test/* + +EXCLUDE_PATTERNS = + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test + +EXCLUDE_SYMBOLS = + +# The EXAMPLE_PATH tag can be used to specify one or more files or +# directories that contain example code fragments that are included (see +# the \include command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank all files are included. + +EXAMPLE_PATTERNS = + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude +# commands irrespective of the value of the RECURSIVE tag. +# Possible values are YES and NO. If left blank NO is used. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or +# directories that contain image that are included in the documentation (see +# the \image command). + +IMAGE_PATH = doc/img + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command <filter> <input-file>, where <filter> +# is the value of the INPUT_FILTER tag, and <input-file> is the name of an +# input file. Doxygen will then use the output that the filter program writes +# to standard output. +# If FILTER_PATTERNS is specified, this tag will be +# ignored. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. +# Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. +# The filters are a list of the form: +# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further +# info on how filters are used. If FILTER_PATTERNS is empty or if +# non of the patterns match the file name, INPUT_FILTER is applied. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER) will be used to filter the input files when producing source +# files to browse (i.e. when SOURCE_BROWSER is set to YES). + +FILTER_SOURCE_FILES = NO + +# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file +# pattern. A pattern will override the setting for FILTER_PATTERN (if any) +# and it is also possible to disable source filtering for a specific pattern +# using *.ext= (so without naming a filter). This option only has effect when +# FILTER_SOURCE_FILES is enabled. + +FILTER_SOURCE_PATTERNS = + +# If the USE_MD_FILE_AS_MAINPAGE tag refers to the name of a markdown file that +# is part of the input, its contents will be placed on the main page (index.html). +# This can be useful if you have a project on for instance GitHub and want reuse +# the introduction page also for the doxygen output. + +USE_MDFILE_AS_MAINPAGE = + +#--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will +# be generated. Documented entities will be cross-referenced with these sources. +# Note: To get rid of all source code in the generated output, make sure also +# VERBATIM_HEADERS is set to NO. + +SOURCE_BROWSER = NO + +# Setting the INLINE_SOURCES tag to YES will include the body +# of functions and classes directly in the documentation. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct +# doxygen to hide any special comment blocks from generated source code +# fragments. Normal C, C++ and Fortran comments will always remain visible. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES +# then for each documented function all documented +# functions referencing it will be listed. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES +# then for each documented function all documented entities +# called/used by that function will be listed. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) +# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from +# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will +# link to the source code. +# Otherwise they will link to the documentation. + +REFERENCES_LINK_SOURCE = YES + +# If the USE_HTAGS tag is set to YES then the references to source code +# will point to the HTML generated by the htags(1) tool instead of doxygen +# built-in source browser. The htags tool is part of GNU's global source +# tagging system (see http://www.gnu.org/software/global/global.html). You +# will need version 4.8.6 or higher. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen +# will generate a verbatim copy of the header file for each class for +# which an include is specified. Set to NO to disable this. + +VERBATIM_HEADERS = YES + +#--------------------------------------------------------------------------- +# configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index +# of all compounds will be generated. Enable this if the project +# contains a lot of classes, structs, unions or interfaces. + +ALPHABETICAL_INDEX = YES + +# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then +# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns +# in which this list will be split (can be a number in the range [1..20]) + +COLS_IN_ALPHA_INDEX = 5 + +# In case all classes in a project start with a common prefix, all +# classes will be put under the same header in the alphabetical index. +# The IGNORE_PREFIX tag can be used to specify one or more prefixes that +# should be ignored while generating the index headers. + +IGNORE_PREFIX = + +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES (the default) Doxygen will +# generate HTML output. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `html' will be used as the default path. + +HTML_OUTPUT = html + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for +# each generated HTML page (for example: .htm,.php,.asp). If it is left blank +# doxygen will generate files with .html extension. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a personal HTML header for +# each generated HTML page. If it is left blank doxygen will generate a +# standard header. Note that when using a custom header you are responsible +# for the proper inclusion of any scripts and style sheets that doxygen +# needs, which is dependent on the configuration options used. +# It is advised to generate a default header using "doxygen -w html +# header.html footer.html stylesheet.css YourConfigFile" and then modify +# that header. Note that the header is subject to change so you typically +# have to redo this when upgrading to a newer version of doxygen or when +# changing the value of configuration settings such as GENERATE_TREEVIEW! + +HTML_HEADER = common/doc/header.html + +# The HTML_FOOTER tag can be used to specify a personal HTML footer for +# each generated HTML page. If it is left blank doxygen will generate a +# standard footer. + +HTML_FOOTER = common/doc/footer.html + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading +# style sheet that is used by each HTML page. It can be used to +# fine-tune the look of the HTML output. If left blank doxygen will +# generate a default style sheet. Note that it is recommended to use +# HTML_EXTRA_STYLESHEET instead of this one, as it is more robust and this +# tag will in the future become obsolete. + +HTML_STYLESHEET = common/doc/css/stylesheet.css + +# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional +# user-defined cascading style sheet that is included after the standard +# style sheets created by doxygen. Using this option one can overrule +# certain style aspects. This is preferred over using HTML_STYLESHEET +# since it does not replace the standard style sheet and is therefor more +# robust against future updates. Doxygen will copy the style sheet file to +# the output directory. + +HTML_EXTRA_STYLESHEET = + +# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the HTML output directory. Note +# that these files will be copied to the base HTML output directory. Use the +# $relpath$ marker in the HTML_HEADER and/or HTML_FOOTER files to load these +# files. In the HTML_STYLESHEET file, use the file name only. Also note that +# the files will be copied as-is; there are no commands or markers available. + +HTML_EXTRA_FILES = + +# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. +# Doxygen will adjust the colors in the style sheet and background images +# according to this color. Hue is specified as an angle on a colorwheel, +# see http://en.wikipedia.org/wiki/Hue for more information. +# For instance the value 0 represents red, 60 is yellow, 120 is green, +# 180 is cyan, 240 is blue, 300 purple, and 360 is red again. +# The allowed range is 0 to 359. + +HTML_COLORSTYLE_HUE = 220 + +# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of +# the colors in the HTML output. For a value of 0 the output will use +# grayscales only. A value of 255 will produce the most vivid colors. + +HTML_COLORSTYLE_SAT = 100 + +# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to +# the luminance component of the colors in the HTML output. Values below +# 100 gradually make the output lighter, whereas values above 100 make +# the output darker. The value divided by 100 is the actual gamma applied, +# so 80 represents a gamma of 0.8, The value 220 represents a gamma of 2.2, +# and 100 does not change the gamma. + +HTML_COLORSTYLE_GAMMA = 80 + +# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML +# page will contain the date and time when the page was generated. Setting +# this to NO can help when comparing the output of multiple runs. + +HTML_TIMESTAMP = YES + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. + +HTML_DYNAMIC_SECTIONS = NO + +# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of +# entries shown in the various tree structured indices initially; the user +# can expand and collapse entries dynamically later on. Doxygen will expand +# the tree to such a level that at most the specified number of entries are +# visible (unless a fully collapsed tree already exceeds this amount). +# So setting the number of entries 1 will produce a full collapsed tree by +# default. 0 is a special value representing an infinite number of entries +# and will result in a full expanded tree by default. + +HTML_INDEX_NUM_ENTRIES = 100 + +# If the GENERATE_DOCSET tag is set to YES, additional index files +# will be generated that can be used as input for Apple's Xcode 3 +# integrated development environment, introduced with OSX 10.5 (Leopard). +# To create a documentation set, doxygen will generate a Makefile in the +# HTML output directory. Running make will produce the docset in that +# directory and running "make install" will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find +# it at startup. +# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html +# for more information. + +GENERATE_DOCSET = NO + +# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the +# feed. A documentation feed provides an umbrella under which multiple +# documentation sets from a single provider (such as a company or product suite) +# can be grouped. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that +# should uniquely identify the documentation set bundle. This should be a +# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen +# will append .docset to the name. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# When GENERATE_PUBLISHER_ID tag specifies a string that should uniquely +# identify the documentation publisher. This should be a reverse domain-name +# style string, e.g. com.mycompany.MyDocSet.documentation. + +DOCSET_PUBLISHER_ID = org.doxygen.Publisher + +# The GENERATE_PUBLISHER_NAME tag identifies the documentation publisher. + +DOCSET_PUBLISHER_NAME = Publisher + +# If the GENERATE_HTMLHELP tag is set to YES, additional index files +# will be generated that can be used as input for tools like the +# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) +# of the generated HTML documentation. + +GENERATE_HTMLHELP = NO + +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can +# be used to specify the file name of the resulting .chm file. You +# can add a path in front of the file if the result should not be +# written to the html output directory. + +CHM_FILE = + +# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can +# be used to specify the location (absolute path including file name) of +# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run +# the HTML help compiler on the generated index.hhp. + +HHC_LOCATION = + +# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag +# controls if a separate .chi index file is generated (YES) or that +# it should be included in the master .chm file (NO). + +GENERATE_CHI = NO + +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING +# is used to encode HtmlHelp index (hhk), content (hhc) and project file +# content. + +CHM_INDEX_ENCODING = + +# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag +# controls whether a binary table of contents is generated (YES) or a +# normal table of contents (NO) in the .chm file. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members +# to the contents of the HTML help documentation and to the tree view. + +TOC_EXPAND = NO + +# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and +# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated +# that can be used as input for Qt's qhelpgenerator to generate a +# Qt Compressed Help (.qch) of the generated HTML documentation. + +GENERATE_QHP = NO + +# If the QHG_LOCATION tag is specified, the QCH_FILE tag can +# be used to specify the file name of the resulting .qch file. +# The path specified is relative to the HTML output folder. + +QCH_FILE = + +# The QHP_NAMESPACE tag specifies the namespace to use when generating +# Qt Help Project output. For more information please see +# http://doc.trolltech.com/qthelpproject.html#namespace + +QHP_NAMESPACE = org.doxygen.Project + +# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating +# Qt Help Project output. For more information please see +# http://doc.trolltech.com/qthelpproject.html#virtual-folders + +QHP_VIRTUAL_FOLDER = doc + +# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to +# add. For more information please see +# http://doc.trolltech.com/qthelpproject.html#custom-filters + +QHP_CUST_FILTER_NAME = + +# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the +# custom filter to add. For more information please see +# <a href="http://doc.trolltech.com/qthelpproject.html#custom-filters"> +# Qt Help Project / Custom Filters</a>. + +QHP_CUST_FILTER_ATTRS = + +# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this +# project's +# filter section matches. +# <a href="http://doc.trolltech.com/qthelpproject.html#filter-attributes"> +# Qt Help Project / Filter Attributes</a>. + +QHP_SECT_FILTER_ATTRS = + +# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can +# be used to specify the location of Qt's qhelpgenerator. +# If non-empty doxygen will try to run qhelpgenerator on the generated +# .qhp file. + +QHG_LOCATION = + +# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files +# will be generated, which together with the HTML files, form an Eclipse help +# plugin. To install this plugin and make it available under the help contents +# menu in Eclipse, the contents of the directory containing the HTML and XML +# files needs to be copied into the plugins directory of eclipse. The name of +# the directory within the plugins directory should be the same as +# the ECLIPSE_DOC_ID value. After copying Eclipse needs to be restarted before +# the help appears. + +GENERATE_ECLIPSEHELP = NO + +# A unique identifier for the eclipse help plugin. When installing the plugin +# the directory name containing the HTML and XML files should also have +# this name. + +ECLIPSE_DOC_ID = org.doxygen.Project + +# The DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) +# at top of each HTML page. The value NO (the default) enables the index and +# the value YES disables it. Since the tabs have the same information as the +# navigation tree you can set this option to NO if you already set +# GENERATE_TREEVIEW to YES. + +DISABLE_INDEX = NO + +# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index +# structure should be generated to display hierarchical information. +# If the tag value is set to YES, a side panel will be generated +# containing a tree-like index structure (just like the one that +# is generated for HTML Help). For this to work a browser that supports +# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser). +# Windows users are probably better off using the HTML help feature. +# Since the tree basically has the same information as the tab index you +# could consider to set DISABLE_INDEX to NO when enabling this option. + +GENERATE_TREEVIEW = NO + +# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values +# (range [0,1..20]) that doxygen will group on one line in the generated HTML +# documentation. Note that a value of 0 will completely suppress the enum +# values from appearing in the overview section. + +ENUM_VALUES_PER_LINE = 1 + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be +# used to set the initial width (in pixels) of the frame in which the tree +# is shown. + +TREEVIEW_WIDTH = 250 + +# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open +# links to external symbols imported via tag files in a separate window. + +EXT_LINKS_IN_WINDOW = NO + +# Use this tag to change the font size of Latex formulas included +# as images in the HTML documentation. The default is 10. Note that +# when you change the font size after a successful doxygen run you need +# to manually remove any form_*.png images from the HTML output directory +# to force them to be regenerated. + +FORMULA_FONTSIZE = 10 + +# Use the FORMULA_TRANPARENT tag to determine whether or not the images +# generated for formulas are transparent PNGs. Transparent PNGs are +# not supported properly for IE 6.0, but are supported on all modern browsers. +# Note that when changing this option you need to delete any form_*.png files +# in the HTML output before the changes have effect. + +FORMULA_TRANSPARENT = YES + +# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax +# (see http://www.mathjax.org) which uses client side Javascript for the +# rendering instead of using prerendered bitmaps. Use this if you do not +# have LaTeX installed or if you want to formulas look prettier in the HTML +# output. When enabled you may also need to install MathJax separately and +# configure the path to it using the MATHJAX_RELPATH option. + +USE_MATHJAX = NO + +# When MathJax is enabled you can set the default output format to be used for +# thA MathJax output. Supported types are HTML-CSS, NativeMML (i.e. MathML) and +# SVG. The default value is HTML-CSS, which is slower, but has the best +# compatibility. + +MATHJAX_FORMAT = HTML-CSS + +# When MathJax is enabled you need to specify the location relative to the +# HTML output directory using the MATHJAX_RELPATH option. The destination +# directory should contain the MathJax.js script. For instance, if the mathjax +# directory is located at the same level as the HTML output directory, then +# MATHJAX_RELPATH should be ../mathjax. The default value points to +# the MathJax Content Delivery Network so you can quickly see the result without +# installing MathJax. +# However, it is strongly recommended to install a local +# copy of MathJax from http://www.mathjax.org before deployment. + +MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest + +# The MATHJAX_EXTENSIONS tag can be used to specify one or MathJax extension +# names that should be enabled during MathJax rendering. + +MATHJAX_EXTENSIONS = + +# When the SEARCHENGINE tag is enabled doxygen will generate a search box +# for the HTML output. The underlying search engine uses javascript +# and DHTML and should work on any modern browser. Note that when using +# HTML help (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets +# (GENERATE_DOCSET) there is already a search function so this one should +# typically be disabled. For large projects the javascript based search engine +# can be slow, then enabling SERVER_BASED_SEARCH may provide a better solution. + +SEARCHENGINE = NO + +# When the SERVER_BASED_SEARCH tag is enabled the search engine will be +# implemented using a web server instead of a web client using Javascript. +# There are two flavours of web server based search depending on the +# EXTERNAL_SEARCH setting. When disabled, doxygen will generate a PHP script for +# searching and an index file used by the script. When EXTERNAL_SEARCH is +# enabled the indexing and searching needs to be provided by external tools. +# See the manual for details. + +SERVER_BASED_SEARCH = NO + +# When EXTERNAL_SEARCH is enabled doxygen will no longer generate the PHP +# script for searching. Instead the search results are written to an XML file +# which needs to be processed by an external indexer. Doxygen will invoke an +# external search engine pointed to by the SEARCHENGINE_URL option to obtain +# the search results. Doxygen ships with an example indexer (doxyindexer) and +# search engine (doxysearch.cgi) which are based on the open source search engine +# library Xapian. See the manual for configuration details. + +EXTERNAL_SEARCH = NO + +# The SEARCHENGINE_URL should point to a search engine hosted by a web server +# which will returned the search results when EXTERNAL_SEARCH is enabled. +# Doxygen ships with an example search engine (doxysearch) which is based on +# the open source search engine library Xapian. See the manual for configuration +# details. + +SEARCHENGINE_URL = + +# When SERVER_BASED_SEARCH and EXTERNAL_SEARCH are both enabled the unindexed +# search data is written to a file for indexing by an external tool. With the +# SEARCHDATA_FILE tag the name of this file can be specified. + +SEARCHDATA_FILE = searchdata.xml + +# When SERVER_BASED_SEARCH AND EXTERNAL_SEARCH are both enabled the +# EXTERNAL_SEARCH_ID tag can be used as an identifier for the project. This is +# useful in combination with EXTRA_SEARCH_MAPPINGS to search through multiple +# projects and redirect the results back to the right project. + +EXTERNAL_SEARCH_ID = + +# The EXTRA_SEARCH_MAPPINGS tag can be used to enable searching through doxygen +# projects other than the one defined by this configuration file, but that are +# all added to the same external search index. Each project needs to have a +# unique id set via EXTERNAL_SEARCH_ID. The search mapping then maps the id +# of to a relative location where the documentation can be found. +# The format is: EXTRA_SEARCH_MAPPINGS = id1=loc1 id2=loc2 ... + +EXTRA_SEARCH_MAPPINGS = + +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- + +# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will +# generate Latex output. + +GENERATE_LATEX = YES + +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `latex' will be used as the default path. + +LATEX_OUTPUT = latex + +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be +# invoked. If left blank `latex' will be used as the default command name. +# Note that when enabling USE_PDFLATEX this option is only used for +# generating bitmaps for formulas in the HTML output, but not in the +# Makefile that is written to the output directory. + +LATEX_CMD_NAME = latex + +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to +# generate index for LaTeX. If left blank `makeindex' will be used as the +# default command name. + +MAKEINDEX_CMD_NAME = makeindex + +# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact +# LaTeX documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_LATEX = NO + +# The PAPER_TYPE tag can be used to set the paper type that is used +# by the printer. Possible values are: a4, letter, legal and +# executive. If left blank a4wide will be used. + +PAPER_TYPE = a4 + +# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX +# packages that should be included in the LaTeX output. + +EXTRA_PACKAGES = + +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for +# the generated latex document. The header should contain everything until +# the first chapter. If it is left blank doxygen will generate a +# standard header. Notice: only use this tag if you know what you are doing! + +LATEX_HEADER = + +# The LATEX_FOOTER tag can be used to specify a personal LaTeX footer for +# the generated latex document. The footer should contain everything after +# the last chapter. If it is left blank doxygen will generate a +# standard footer. Notice: only use this tag if you know what you are doing! + +LATEX_FOOTER = + +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated +# is prepared for conversion to pdf (using ps2pdf). The pdf file will +# contain links (just like the HTML output) instead of page references +# This makes the output suitable for online browsing using a pdf viewer. + +PDF_HYPERLINKS = YES + +# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of +# plain latex in the generated Makefile. Set this option to YES to get a +# higher quality PDF documentation. + +USE_PDFLATEX = YES + +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. +# command to the generated LaTeX files. This will instruct LaTeX to keep +# running if errors occur, instead of asking the user for help. +# This option is also used when generating formulas in HTML. + +LATEX_BATCHMODE = NO + +# If LATEX_HIDE_INDICES is set to YES then doxygen will not +# include the index chapters (such as File Index, Compound Index, etc.) +# in the output. + +LATEX_HIDE_INDICES = NO + +# If LATEX_SOURCE_CODE is set to YES then doxygen will include +# source code with syntax highlighting in the LaTeX output. +# Note that which sources are shown also depends on other settings +# such as SOURCE_BROWSER. + +LATEX_SOURCE_CODE = NO + +# The LATEX_BIB_STYLE tag can be used to specify the style to use for the +# bibliography, e.g. plainnat, or ieeetr. The default style is "plain". See +# http://en.wikipedia.org/wiki/BibTeX for more info. + +LATEX_BIB_STYLE = plain + +#--------------------------------------------------------------------------- +# configuration options related to the RTF output +#--------------------------------------------------------------------------- + +# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output +# The RTF output is optimized for Word 97 and may not look very pretty with +# other RTF readers or editors. + +GENERATE_RTF = NO + +# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `rtf' will be used as the default path. + +RTF_OUTPUT = rtf + +# If the COMPACT_RTF tag is set to YES Doxygen generates more compact +# RTF documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_RTF = NO + +# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated +# will contain hyperlink fields. The RTF file will +# contain links (just like the HTML output) instead of page references. +# This makes the output suitable for online browsing using WORD or other +# programs which support those fields. +# Note: wordpad (write) and others do not support links. + +RTF_HYPERLINKS = NO + +# Load style sheet definitions from file. Syntax is similar to doxygen's +# config file, i.e. a series of assignments. You only have to provide +# replacements, missing definitions are set to their default value. + +RTF_STYLESHEET_FILE = + +# Set optional variables used in the generation of an rtf document. +# Syntax is similar to doxygen's config file. + +RTF_EXTENSIONS_FILE = + +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- + +# If the GENERATE_MAN tag is set to YES (the default) Doxygen will +# generate man pages + +GENERATE_MAN = YES + +# The MAN_OUTPUT tag is used to specify where the man pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `man' will be used as the default path. + +MAN_OUTPUT = man + +# The MAN_EXTENSION tag determines the extension that is added to +# the generated man pages (default is the subroutine's section .3) + +MAN_EXTENSION = .3 + +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, +# then it will generate one additional man file for each entity +# documented in the real man page(s). These additional files +# only source the real man page, but without them the man command +# would be unable to find the correct page. The default is NO. + +MAN_LINKS = NO + +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- + +# If the GENERATE_XML tag is set to YES Doxygen will +# generate an XML file that captures the structure of +# the code including all documentation. + +GENERATE_XML = YES + +# The XML_OUTPUT tag is used to specify where the XML pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `xml' will be used as the default path. + +XML_OUTPUT = xml + +# The XML_SCHEMA tag can be used to specify an XML schema, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_SCHEMA = + +# The XML_DTD tag can be used to specify an XML DTD, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_DTD = + +# If the XML_PROGRAMLISTING tag is set to YES Doxygen will +# dump the program listings (including syntax highlighting +# and cross-referencing information) to the XML output. Note that +# enabling this will significantly increase the size of the XML output. + +XML_PROGRAMLISTING = YES + +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- + +# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will +# generate an AutoGen Definitions (see autogen.sf.net) file +# that captures the structure of the code including all +# documentation. Note that this feature is still experimental +# and incomplete at the moment. + +GENERATE_AUTOGEN_DEF = NO + +#--------------------------------------------------------------------------- +# configuration options related to the Perl module output +#--------------------------------------------------------------------------- + +# If the GENERATE_PERLMOD tag is set to YES Doxygen will +# generate a Perl module file that captures the structure of +# the code including all documentation. Note that this +# feature is still experimental and incomplete at the +# moment. + +GENERATE_PERLMOD = NO + +# If the PERLMOD_LATEX tag is set to YES Doxygen will generate +# the necessary Makefile rules, Perl scripts and LaTeX code to be able +# to generate PDF and DVI output from the Perl module output. + +PERLMOD_LATEX = NO + +# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be +# nicely formatted so it can be parsed by a human reader. +# This is useful +# if you want to understand what is going on. +# On the other hand, if this +# tag is set to NO the size of the Perl module output will be much smaller +# and Perl will parse it just the same. + +PERLMOD_PRETTY = YES + +# The names of the make variables in the generated doxyrules.make file +# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. +# This is useful so different doxyrules.make files included by the same +# Makefile don't overwrite each other's variables. + +PERLMOD_MAKEVAR_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- + +# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will +# evaluate all C-preprocessor directives found in the sources and include +# files. + +ENABLE_PREPROCESSING = YES + +# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro +# names in the source code. If set to NO (the default) only conditional +# compilation will be performed. Macro expansion can be done in a controlled +# way by setting EXPAND_ONLY_PREDEF to YES. + +MACRO_EXPANSION = NO + +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES +# then the macro expansion is limited to the macros specified with the +# PREDEFINED and EXPAND_AS_DEFINED tags. + +EXPAND_ONLY_PREDEF = NO + +# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files +# pointed to by INCLUDE_PATH will be searched when a #include is found. + +SEARCH_INCLUDES = YES + +# The INCLUDE_PATH tag can be used to specify one or more directories that +# contain include files that are not input files but should be processed by +# the preprocessor. + +INCLUDE_PATH = + +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard +# patterns (like *.h and *.hpp) to filter out the header-files in the +# directories. If left blank, the patterns specified with FILE_PATTERNS will +# be used. + +INCLUDE_FILE_PATTERNS = + +# The PREDEFINED tag can be used to specify one or more macro names that +# are defined before the preprocessor is started (similar to the -D option of +# gcc). The argument of the tag is a list of macros of the form: name +# or name=definition (no spaces). If the definition and the = are +# omitted =1 is assumed. To prevent a macro definition from being +# undefined via #undef or recursively expanded use the := operator +# instead of the = operator. + +PREDEFINED = + +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then +# this tag can be used to specify a list of macro names that should be expanded. +# The macro definition that is found in the sources will be used. +# Use the PREDEFINED tag if you want to use a different macro definition that +# overrules the definition found in the source code. + +EXPAND_AS_DEFINED = + +# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then +# doxygen's preprocessor will remove all references to function-like macros +# that are alone on a line, have an all uppercase name, and do not end with a +# semicolon, because these will confuse the parser if not removed. + +SKIP_FUNCTION_MACROS = YES + +#--------------------------------------------------------------------------- +# Configuration::additions related to external references +#--------------------------------------------------------------------------- + +# The TAGFILES option can be used to specify one or more tagfiles. For each +# tag file the location of the external documentation should be added. The +# format of a tag file without this location is as follows: +# +# TAGFILES = file1 file2 ... +# Adding location for the tag files is done as follows: +# +# TAGFILES = file1=loc1 "file2 = loc2" ... +# where "loc1" and "loc2" can be relative or absolute paths +# or URLs. Note that each tag file must have a unique name (where the name does +# NOT include the path). If a tag file is not located in the directory in which +# doxygen is run, you must also specify the path to the tagfile here. + +TAGFILES = + +# When a file name is specified after GENERATE_TAGFILE, doxygen will create +# a tag file that is based on the input files it reads. + +GENERATE_TAGFILE = + +# If the ALLEXTERNALS tag is set to YES all external classes will be listed +# in the class index. If set to NO only the inherited external classes +# will be listed. + +ALLEXTERNALS = NO + +# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed +# in the modules index. If set to NO, only the current project's groups will +# be listed. + +EXTERNAL_GROUPS = YES + +# The PERL_PATH should be the absolute path and name of the perl script +# interpreter (i.e. the result of `which perl'). + +PERL_PATH = /usr/bin/perl + +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- + +# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will +# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base +# or super classes. Setting the tag to NO turns the diagrams off. Note that +# this option also works with HAVE_DOT disabled, but it is recommended to +# install and use dot, since it yields more powerful graphs. + +CLASS_DIAGRAMS = YES + +# You can define message sequence charts within doxygen comments using the \msc +# command. Doxygen will then run the mscgen tool (see +# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the +# documentation. The MSCGEN_PATH tag allows you to specify the directory where +# the mscgen tool resides. If left empty the tool is assumed to be found in the +# default search path. + +MSCGEN_PATH = + +# If set to YES, the inheritance and collaboration graphs will hide +# inheritance and usage relations if the target is undocumented +# or is not a class. + +HIDE_UNDOC_RELATIONS = YES + +# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is +# available from the path. This tool is part of Graphviz, a graph visualization +# toolkit from AT&T and Lucent Bell Labs. The other options in this section +# have no effect if this option is set to NO (the default) + +HAVE_DOT = NO + +# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is +# allowed to run in parallel. When set to 0 (the default) doxygen will +# base this on the number of processors available in the system. You can set it +# explicitly to a value larger than 0 to get control over the balance +# between CPU load and processing speed. + +DOT_NUM_THREADS = 0 + +# By default doxygen will use the Helvetica font for all dot files that +# doxygen generates. When you want a differently looking font you can specify +# the font name using DOT_FONTNAME. You need to make sure dot is able to find +# the font, which can be done by putting it in a standard location or by setting +# the DOTFONTPATH environment variable or by setting DOT_FONTPATH to the +# directory containing the font. + +DOT_FONTNAME = Helvetica + +# The DOT_FONTSIZE tag can be used to set the size of the font of dot graphs. +# The default size is 10pt. + +DOT_FONTSIZE = 10 + +# By default doxygen will tell dot to use the Helvetica font. +# If you specify a different font using DOT_FONTNAME you can use DOT_FONTPATH to +# set the path where dot can find it. + +DOT_FONTPATH = + +# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect inheritance relations. Setting this tag to YES will force the +# CLASS_DIAGRAMS tag to NO. + +CLASS_GRAPH = YES + +# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect implementation dependencies (inheritance, containment, and +# class references variables) of the class with other documented classes. + +COLLABORATION_GRAPH = YES + +# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for groups, showing the direct groups dependencies + +GROUP_GRAPHS = YES + +# If the UML_LOOK tag is set to YES doxygen will generate inheritance and +# collaboration diagrams in a style similar to the OMG's Unified Modeling +# Language. + +UML_LOOK = NO + +# If the UML_LOOK tag is enabled, the fields and methods are shown inside +# the class node. If there are many fields or methods and many nodes the +# graph may become too big to be useful. The UML_LIMIT_NUM_FIELDS +# threshold limits the number of items for each type to make the size more +# managable. Set this to 0 for no limit. Note that the threshold may be +# exceeded by 50% before the limit is enforced. + +UML_LIMIT_NUM_FIELDS = 10 + +# If set to YES, the inheritance and collaboration graphs will show the +# relations between templates and their instances. + +TEMPLATE_RELATIONS = NO + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT +# tags are set to YES then doxygen will generate a graph for each documented +# file showing the direct and indirect include dependencies of the file with +# other documented files. + +INCLUDE_GRAPH = YES + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and +# HAVE_DOT tags are set to YES then doxygen will generate a graph for each +# documented header file showing the documented files that directly or +# indirectly include this file. + +INCLUDED_BY_GRAPH = YES + +# If the CALL_GRAPH and HAVE_DOT options are set to YES then +# doxygen will generate a call dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable call graphs +# for selected functions only using the \callgraph command. + +CALL_GRAPH = NO + +# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then +# doxygen will generate a caller dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable caller +# graphs for selected functions only using the \callergraph command. + +CALLER_GRAPH = NO + +# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen +# will generate a graphical hierarchy of all classes instead of a textual one. + +GRAPHICAL_HIERARCHY = YES + +# If the DIRECTORY_GRAPH and HAVE_DOT tags are set to YES +# then doxygen will show the dependencies a directory has on other directories +# in a graphical way. The dependency relations are determined by the #include +# relations between the files in the directories. + +DIRECTORY_GRAPH = YES + +# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images +# generated by dot. Possible values are svg, png, jpg, or gif. +# If left blank png will be used. If you choose svg you need to set +# HTML_FILE_EXTENSION to xhtml in order to make the SVG files +# visible in IE 9+ (other browsers do not have this requirement). + +DOT_IMAGE_FORMAT = png + +# If DOT_IMAGE_FORMAT is set to svg, then this option can be set to YES to +# enable generation of interactive SVG images that allow zooming and panning. +# Note that this requires a modern browser other than Internet Explorer. +# Tested and working are Firefox, Chrome, Safari, and Opera. For IE 9+ you +# need to set HTML_FILE_EXTENSION to xhtml in order to make the SVG files +# visible. Older versions of IE do not have SVG support. + +INTERACTIVE_SVG = NO + +# The tag DOT_PATH can be used to specify the path where the dot tool can be +# found. If left blank, it is assumed the dot tool can be found in the path. + +DOT_PATH = + +# The DOTFILE_DIRS tag can be used to specify one or more directories that +# contain dot files that are included in the documentation (see the +# \dotfile command). + +DOTFILE_DIRS = + +# The MSCFILE_DIRS tag can be used to specify one or more directories that +# contain msc files that are included in the documentation (see the +# \mscfile command). + +MSCFILE_DIRS = + +# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of +# nodes that will be shown in the graph. If the number of nodes in a graph +# becomes larger than this value, doxygen will truncate the graph, which is +# visualized by representing a node as a red box. Note that doxygen if the +# number of direct children of the root node in a graph is already larger than +# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note +# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. + +DOT_GRAPH_MAX_NODES = 50 + +# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the +# graphs generated by dot. A depth value of 3 means that only nodes reachable +# from the root by following a path via at most 3 edges will be shown. Nodes +# that lay further from the root node will be omitted. Note that setting this +# option to 1 or 2 may greatly reduce the computation time needed for large +# code bases. Also note that the size of a graph can be further restricted by +# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. + +MAX_DOT_GRAPH_DEPTH = 0 + +# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent +# background. This is disabled by default, because dot on Windows does not +# seem to support this out of the box. Warning: Depending on the platform used, +# enabling this option may lead to badly anti-aliased labels on the edges of +# a graph (i.e. they become hard to read). + +DOT_TRANSPARENT = NO + +# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output +# files in one run (i.e. multiple -o and -T options on the command line). This +# makes dot run faster, but since only newer versions of dot (>1.8.10) +# support this, this feature is disabled by default. + +DOT_MULTI_TARGETS = NO + +# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will +# generate a legend page explaining the meaning of the various boxes and +# arrows in the dot generated graphs. + +GENERATE_LEGEND = YES + +# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will +# remove the intermediate dot files that are used to generate +# the various graphs. + +DOT_CLEANUP = YES + diff --git a/common/doc/css/stylesheet.css b/common/doc/css/stylesheet.css new file mode 100644 index 0000000..1c40540 --- /dev/null +++ b/common/doc/css/stylesheet.css @@ -0,0 +1,1225 @@ +/* The standard CSS for doxygen */ + +body, table, div, p, dl { + font: 400 14px/19px monospace; + color: #57585c; +} + +/* @group Heading Levels */ + +h1 { + font-size: 150%; +} + +.title { + font-size: 150%; + font-weight: bold; + margin: 10px 2px; +} + +h2 { + border-bottom: 1px solid #57585c; + color: #57585c; + font-size: 150%; + font-weight: normal; + margin-top: 2.75em; + padding-top: 8px; + padding-bottom: 4px; + width: 100%; +} + +h3 { + font-size: 100%; +} + +h1, h2, h3, h4, h5, h6 { + -webkit-transition: text-shadow 0.5s linear; + -moz-transition: text-shadow 0.5s linear; + -ms-transition: text-shadow 0.5s linear; + -o-transition: text-shadow 0.5s linear; + transition: text-shadow 0.5s linear; + margin-right: 15px; +} + +h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { + text-shadow: 0 0 15px cyan; +} + +dt { + font-weight: bold; +} + +div.multicol { + -moz-column-gap: 1em; + -webkit-column-gap: 1em; + -moz-column-count: 3; + -webkit-column-count: 3; +} + +p.startli, p.startdd, p.starttd { + margin-top: 2px; +} + +p.endli { + margin-bottom: 0px; +} + +p.enddd { + margin-bottom: 4px; +} + +p.endtd { + margin-bottom: 2px; +} + +/* @end */ + +caption { + font-weight: bold; +} + +span.legend { + font-size: 70%; + text-align: center; +} + +h3.version { + font-size: 90%; + text-align: center; +} + +div.qindex, div.navtab{ + background-color: #EBEFF6; + border: 1px solid #A3B4D7; + text-align: center; +} + +div.qindex, div.navpath { + width: 100%; + line-height: 140%; +} + +div.navtab { + margin-right: 15px; +} + +/* @group Link Styling */ + +a { + color: #34ccfd; + font-weight: normal; + text-decoration: none; +} + +.contents a:visited { + color: #0693ff; +} + +a:hover { + text-decoration: underline; +} + +a.qindex { + font-weight: bold; +} + +a.qindexHL { + font-weight: bold; + background-color: #9CAFD4; + color: #ffffff; + border: 1px double #869DCA; +} + +.contents a.qindexHL:visited { + color: #ffffff; +} + +a.el { + font-weight: bold; +} + +a.elRef { +} + +a.code, a.code:visited { + color: #4665A2; +} + +a.codeRef, a.codeRef:visited { + color: #4665A2; +} + +/* @end */ + +dl.el { + margin-left: -1cm; +} + +pre.fragment { + border: 1px solid #C4CFE5; + background-color: #FBFCFD; + padding: 4px 6px; + margin: 4px 8px 4px 2px; + overflow: auto; + word-wrap: break-word; + font-size: 9pt; + line-height: 125%; + font-family: monospace, fixed; + font-size: 105%; +} + +div.fragment { + border: 1px solid #ababab; + background-color: #e8e8e8; + padding: 4px; + margin: 4px; +} + +div.line { + font-family: monospace, fixed; + font-size: 13px; + min-height: 13px; + line-height: 1.0; + text-wrap: unrestricted; + white-space: -moz-pre-wrap; /* Moz */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + white-space: pre-wrap; /* CSS3 */ + word-wrap: break-word; /* IE 5.5+ */ + text-indent: -53px; + padding-left: 53px; + padding-bottom: 0px; + margin: 0px; + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +div.line.glow { + background-color: cyan; + box-shadow: 0 0 10px cyan; +} + + +span.lineno { + padding-right: 4px; + text-align: right; + border-right: 2px solid #0F0; + background-color: #E8E8E8; + white-space: pre; +} +span.lineno a { + background-color: #D8D8D8; +} + +span.lineno a:hover { + background-color: #C8C8C8; +} + +div.ah { + background-color: black; + font-weight: bold; + color: #ffffff; + margin-bottom: 3px; + margin-top: 3px; + padding: 0.2em; + border: solid thin #333; + border-radius: 0.5em; + -webkit-border-radius: .5em; + -moz-border-radius: .5em; + box-shadow: 2px 2px 3px #999; + -webkit-box-shadow: 2px 2px 3px #999; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); + background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000); +} + +div.groupHeader { + margin-left: 16px; + margin-top: 12px; + font-weight: bold; +} + +div.groupText { + margin-left: 16px; + font-style: italic; +} + +body { + background-color: white; + color: black; + margin: 0; +} + +div.contents { + margin-top: 10px; + margin-left: 12px; + margin-right: 8px; +} + +td.indexkey { + background-color: #EBEFF6; + font-weight: bold; + border: 1px solid #C4CFE5; + margin: 2px 0px 2px 0; + padding: 2px 10px; + white-space: nowrap; + vertical-align: top; +} + +td.indexvalue { + background-color: #EBEFF6; + border: 1px solid #C4CFE5; + padding: 2px 10px; + margin: 2px 0px; +} + +tr.memlist { + background-color: #EEF1F7; +} + +p.formulaDsp { + text-align: center; +} + +img.formulaDsp { + +} + +img.formulaInl { + vertical-align: middle; +} + +div.center { + text-align: center; + margin-top: 0px; + margin-bottom: 0px; + padding: 0px; +} + +div.center img { + border: 0px; +} + +address.footer { + font-style: normal; + text-align: right; + padding-right: 12px; +} + +img.footer { + border: 0px; + vertical-align: middle; +} + +div.footer { + border-top: 1px solid #ababab; + background-color: #e8e8e8; + color: #57585c; +} + +/* @group Code Colorization */ + +span.keyword { + color: #ff206c +} + +span.keywordtype { + color: #ff206c +} + +span.keywordflow { + color: #ff206c +} + +span.comment { + color: #0693ff +} + +span.preprocessor { + color: #050740 +} + +span.stringliteral { + color: #0693ff +} + +span.charliteral { + color: #34ccfd +} + +span.vhdldigit { + color: #ff00ff +} + +span.vhdlchar { + color: #000000 +} + +span.vhdlkeyword { + color: #700070 +} + +span.vhdllogic { + color: #ff0000 +} + +blockquote { + background-color: #F7F8FB; + border-left: 2px solid #9CAFD4; + margin: 0 24px 0 4px; + padding: 0 12px 0 16px; +} + +/* @end */ + +/* +.search { + color: #003399; + font-weight: bold; +} + +form.search { + margin-bottom: 0px; + margin-top: 0px; +} + +input.search { + font-size: 75%; + color: #000080; + font-weight: normal; + background-color: #e8eef2; +} +*/ + +td.tiny { + font-size: 75%; +} + +.dirtab { + padding: 4px; + border-collapse: collapse; + border: 1px solid #A3B4D7; +} + +th.dirtab { + background: #EBEFF6; + font-weight: bold; +} + +hr { + height: 0px; + border: none; + border-top: 1px solid #ababab; +} + +hr.footer { + height: 1px; +} + +/* @group Member Descriptions */ + +table.memberdecls { + border-spacing: 0px; + padding: 0px; +} + +.memberdecls td, .fieldtable tr { + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +.memberdecls td.glow, .fieldtable tr.glow { + background-color: cyan; + box-shadow: 0 0 15px cyan; +} + +.mdescLeft, .mdescRight, +.memItemLeft, .memItemRight, +.memTemplItemLeft, .memTemplItemRight, .memTemplParams { + background-color: #F9FAFC; + border: none; + margin: 4px; + padding: 1px 0 0 8px; +} + +.mdescLeft, .mdescRight { + padding: 0px 8px 4px 8px; + color: #555; +} + +.memItemLeft, .memItemRight, .memTemplParams { + border-bottom: 1px solid #DEE4F0; +} + +.memItemLeft, .memTemplItemLeft { + white-space: nowrap; +} + +.memItemRight { + width: 100%; +} + +.memTemplParams { + color: #4665A2; + white-space: nowrap; +} + +/* @end */ + +/* @group Member Details */ + +/* Styles for detailed member documentation */ + +.memtemplate { + font-size: 80%; + color: #4665A2; + font-weight: normal; + margin-left: 9px; +} + +.memnav { + background-color: #EBEFF6; + border: 1px solid #A3B4D7; + text-align: center; + margin: 2px; + margin-right: 15px; + padding: 2px; +} + +.mempage { + width: 100%; +} + +.memitem { + padding: 0; + margin-bottom: 10px; + margin-right: 5px; + -webkit-transition: box-shadow 0.5s linear; + -moz-transition: box-shadow 0.5s linear; + -ms-transition: box-shadow 0.5s linear; + -o-transition: box-shadow 0.5s linear; + transition: box-shadow 0.5s linear; + display: table !important; + width: 100%; +} + +.memitem.glow { + box-shadow: 0 0 15px cyan; +} + +.memname { + font-weight: bold; + margin-left: 6px; +} + +.memname td { + vertical-align: bottom; +} + +.memproto, dl.reflist dt { + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 0px 6px 0px; + color: #0693ff; + font-weight: bold; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + background-image:url('nav_f.png'); + background-repeat:repeat-x; + background-color: #E2E8F2; + /* opera specific markup */ + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-top-right-radius: 4px; + border-top-left-radius: 4px; + /* firefox specific markup */ + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + -moz-border-radius-topright: 4px; + -moz-border-radius-topleft: 4px; + /* webkit specific markup */ + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + -webkit-border-top-right-radius: 4px; + -webkit-border-top-left-radius: 4px; + +} + +.memdoc, dl.reflist dd { + border-bottom: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 10px 2px 10px; + background-color: #FBFCFD; + border-top-width: 0; + background-image:url('nav_g.png'); + background-repeat:repeat-x; + background-color: #FFFFFF; + /* opera specific markup */ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + /* firefox specific markup */ + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-bottomright: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + /* webkit specific markup */ + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +dl.reflist dt { + padding: 5px; +} + +dl.reflist dd { + margin: 0px 0px 10px 0px; + padding: 5px; +} + +.paramkey { + text-align: right; +} + +.paramtype { + white-space: nowrap; +} + +.paramname { + color: #ff206c; + white-space: nowrap; +} +.paramname em { + font-style: normal; +} +.paramname code { + line-height: 14px; +} + +.params, .retval, .exception, .tparams { + margin-left: 0px; + padding-left: 0px; +} + +.params .paramname, .retval .paramname { + font-weight: bold; + vertical-align: top; +} + +.params .paramtype { + font-style: italic; + vertical-align: top; +} + +.params .paramdir { + font-family: "courier new",courier,monospace; + vertical-align: top; +} + +table.mlabels { + border-spacing: 0px; +} + +td.mlabels-left { + width: 100%; + padding: 0px; +} + +td.mlabels-right { + vertical-align: bottom; + padding: 0px; + white-space: nowrap; +} + +span.mlabels { + margin-left: 8px; +} + +span.mlabel { + background-color: #728DC1; + border-top:1px solid #5373B4; + border-left:1px solid #5373B4; + border-right:1px solid #C4CFE5; + border-bottom:1px solid #C4CFE5; + text-shadow: none; + color: white; + margin-right: 4px; + padding: 2px 3px; + border-radius: 3px; + font-size: 7pt; + white-space: nowrap; +} + + + +/* @end */ + +/* these are for tree view when not used as main index */ + +div.directory { + margin: 10px 0px; + border-top: 1px solid #A8B8D9; + border-bottom: 1px solid #A8B8D9; + width: 100%; +} + +.directory table { + border-collapse:collapse; +} + +.directory td { + margin: 0px; + padding: 0px; + vertical-align: top; +} + +.directory td.entry { + white-space: nowrap; + padding-right: 6px; +} + +.directory td.entry a { + outline:none; +} + +.directory td.entry a img { + border: none; +} + +.directory td.desc { + width: 100%; + padding-left: 6px; + padding-right: 6px; + padding-top: 3px; + border-left: 1px solid rgba(0,0,0,0.05); +} + +.directory tr.even { + padding-left: 6px; + background-color: #F7F8FB; +} + +.directory img { + vertical-align: -30%; +} + +.directory .levels { + white-space: nowrap; + width: 100%; + text-align: right; + font-size: 9pt; +} + +.directory .levels span { + cursor: pointer; + padding-left: 2px; + padding-right: 2px; + color: #3D578C; +} + +div.dynheader { + margin-top: 8px; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +table.doxtable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.doxtable td, table.doxtable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.doxtable th { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +table.fieldtable { + width: 100%; + margin-bottom: 10px; + border: 1px solid #A8B8D9; + border-spacing: 0px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + border-radius: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); + box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); +} + +.fieldtable td, .fieldtable th { + padding: 3px 7px 2px; +} + +.fieldtable td.fieldtype, .fieldtable td.fieldname { + white-space: nowrap; + border-right: 1px solid #A8B8D9; + border-bottom: 1px solid #A8B8D9; + vertical-align: top; +} + +.fieldtable td.fielddoc { + border-bottom: 1px solid #A8B8D9; + width: 100%; +} + +.fieldtable tr:last-child td { + border-bottom: none; +} + +.fieldtable th { + background-image:url('nav_f.png'); + background-repeat:repeat-x; + background-color: #E2E8F2; + font-size: 90%; + color: #253555; + padding-bottom: 4px; + padding-top: 5px; + text-align:left; + -moz-border-radius-topleft: 4px; + -moz-border-radius-topright: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom: 1px solid #A8B8D9; +} + + +.tabsearch { + top: 0px; + left: 10px; + height: 36px; + background-image: url('tab_b.png'); + z-index: 101; + overflow: hidden; + font-size: 13px; +} + +.navpath ul +{ + font-size: 11px; + background-image:url('tab_b.png'); + background-repeat:repeat-x; + height:30px; + line-height:30px; + color:#8AA0CC; + border:solid 1px #C2CDE4; + overflow:hidden; + margin:0px; + padding:0px; +} + +.navpath li +{ + list-style-type:none; + float:left; + padding-left:10px; + padding-right:15px; + background-image:url('bc_s.png'); + background-repeat:no-repeat; + background-position:right; + color:#364D7C; +} + +.navpath li.navelem a +{ + height:32px; + display:block; + text-decoration: none; + outline: none; + font-family: gotham-light, 'Helvetica Neue', Helvetica, Helvetica, Arial, sans-serif; +} + +.navpath li.navelem a:hover +{ + color:#6884BD; +} + +.navpath li.footer +{ + list-style-type:none; + float:right; + padding-left:10px; + padding-right:15px; + background-image:none; + background-repeat:no-repeat; + background-position:right; + color:#364D7C; + font-size: 8pt; +} + + +div.summary +{ + float: right; + font-size: 8pt; + padding-right: 5px; + width: 50%; + text-align: right; +} + +div.summary a +{ + white-space: nowrap; +} + +div.ingroups +{ + font-size: 8pt; + width: 50%; + text-align: left; +} + +div.ingroups a +{ + white-space: nowrap; +} + +div.header +{ + margin: 0px; + border-bottom: 1px solid #ababab; + background-color: #e8e8e8; +} + +div.headertitle +{ + padding: 5px 5px 5px 10px; +} + +dl +{ + padding: 0 0 0 10px; +} + +/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug */ +dl.section +{ + margin-left: 0px; + padding-left: 0px; +} + +dl.note +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #D0C000; +} + +dl.warning, dl.attention +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #FF0000; +} + +dl.pre, dl.post, dl.invariant +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #00D000; +} + +dl.deprecated +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #505050; +} + +dl.todo +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #00C0E0; +} + +dl.test +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #3030E0; +} + +dl.bug +{ + margin-left:-7px; + padding-left: 3px; + border-left:4px solid; + border-color: #C08050; +} + +dl.section dd { + margin-bottom: 6px; +} + + +#companylogo img +{ + padding: 5px; +} + +#companylogo img +{ + border: 0px none; +} + +#projectlogo +{ + text-align: center; + vertical-align: bottom; + border-collapse: separate; +} + +#projectlogo img +{ + border: 0px none; +} + +#projectname +{ + font: 300% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 2px 0px; +} + +#projectbrief +{ + font: 120% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#projectnumber +{ + font: 50% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#titlearea +{ + padding: 0px; + margin: 0px; + width: 100%; +} + +.image +{ + text-align: center; +} + +.dotgraph +{ + text-align: center; +} + +.mscgraph +{ + text-align: center; +} + +.caption +{ + font-weight: bold; +} + +div.zoom +{ + border: 1px solid #90A5CE; +} + +dl.citelist { + margin-bottom:50px; +} + +dl.citelist dt { + color:#334975; + float:left; + font-weight:bold; + margin-right:10px; + padding:5px; +} + +dl.citelist dd { + margin:2px 0; + padding:5px 0; +} + +div.toc { + padding: 14px 25px; + background-color: #F4F6FA; + border: 1px solid #D8DFEE; + border-radius: 7px 7px 7px 7px; + float: right; + height: auto; + margin: 0 20px 10px 10px; + width: 200px; +} + +div.toc li { + background: url("bdwn.png") no-repeat scroll 0 5px transparent; + font: 10px/1.2 Verdana,DejaVu Sans,Geneva,sans-serif; + margin-top: 5px; + padding-left: 10px; + padding-top: 2px; +} + +div.toc h3 { + font: bold 12px/1.2 Arial,FreeSans,sans-serif; + color: #4665A2; + border-bottom: 0 none; + margin: 0; +} + +div.toc ul { + list-style: none outside none; + border: medium none; + padding: 0px; +} + +div.toc li.level1 { + margin-left: 0px; +} + +div.toc li.level2 { + margin-left: 15px; +} + +div.toc li.level3 { + margin-left: 30px; +} + +div.toc li.level4 { + margin-left: 45px; +} + +.inherit_header { + font-weight: bold; + color: gray; + cursor: pointer; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.inherit_header td { + padding: 6px 0px 2px 5px; +} + +.inherit { + display: none; +} + +tr.heading h2 { + margin-top: 12px; + margin-bottom: 4px; +} + +@media print +{ + #top { display: none; } + #side-nav { display: none; } + #nav-path { display: none; } + body { overflow:visible; } + h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } + .summary { display: none; } + .memitem { page-break-inside: avoid; } + #doc-content + { + margin-left:0 !important; + height:auto !important; + width:auto !important; + overflow:inherit; + display:inline; + } +} + +/* TABS */ +.tabs, .tabs2, .tabs3 { + width: 100%; + z-index: 101; + font-size: 13px; + font-family: monospace; +} + +.tabs2 { + font-size: 10px; +} +.tabs3 { + font-size: 9px; +} + +.tablist { + margin: 0; + padding: 0; + display: table; +} + +.tablist li { + float: left; + display: table-cell; + line-height: 36px; + list-style: none; +} + +.tablist a { + display: block; + padding: 0 20px; + font-weight: bold; + color: #57585C;; + text-decoration: none; + outline: none; +} + +.tabs3 .tablist a { + padding: 0 10px; +} + +.tablist a:hover { + background-color: #34ccfd; + color: #fff; + text-decoration: none; +} + +.tablist li.current a { + background-color: #34ccfd; + color: #fff; +} + diff --git a/common/doc/doxygen_to_devhelp.xsl b/common/doc/doxygen_to_devhelp.xsl new file mode 100644 index 0000000..1aca34d --- /dev/null +++ b/common/doc/doxygen_to_devhelp.xsl @@ -0,0 +1,41 @@ +<xsl:stylesheet + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + xmlns:fo="http://www.w3.org/1999/XSL/Format" + version="1.0"> + +<xsl:output method="xml" version="1.0" indent="yes"/> + +<xsl:param name="prefix"></xsl:param> +<xsl:param name="booktitle"></xsl:param> +<xsl:param name="bookpart"></xsl:param> + +<xsl:template match="/"> + <book title="ONEPLAY: {$booktitle}" + name="oneplay-{$bookpart}" + link="html/index.html"> + <chapters> + <xsl:apply-templates select="doxygenindex/compound[@kind='group']"/> + </chapters> + <functions> + <xsl:apply-templates select="doxygenindex/compound[@kind='group']/member[@kind='function']"/> + </functions> + </book> +</xsl:template> + +<xsl:template match="compound[@kind='group']"> + <xsl:param name="name"><xsl:value-of select="name"/></xsl:param> + <xsl:param name="refid"><xsl:value-of select="@refid"/></xsl:param> + <xsl:param name="link"><xsl:value-of select="$refid"/>.html</xsl:param> + <sub name="{$name}" link="html/{$link}"/> +</xsl:template> + +<xsl:template match="member"> + <xsl:param name="name"><xsl:value-of select="name"/></xsl:param> + <xsl:param name="refid"><xsl:value-of select="@refid"/></xsl:param> + <xsl:param name="before"><xsl:value-of select="substring-before($refid,'_1')"/></xsl:param> + <xsl:param name="after"><xsl:value-of select="substring-after($refid,'_1')"/></xsl:param> + <xsl:param name="link"><xsl:value-of select="$before"/>.html#<xsl:value-of select="$after"/></xsl:param> + <function name="{$name}" link="html/{$link}"/> +</xsl:template> + +</xsl:stylesheet> diff --git a/common/doc/footer.html b/common/doc/footer.html new file mode 100644 index 0000000..0c719e7 --- /dev/null +++ b/common/doc/footer.html @@ -0,0 +1,22 @@ +<!-- start footer part --> +<!--BEGIN GENERATE_TREEVIEW--> +<div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> + <ul> + $navpath + <li class="footer">$generatedby + <a href="http://www.doxygen.org/index.html"> + <img class="footer" src="$relpath$doxygen.png" alt="doxygen"/></a> $doxygenversion </li> + </ul> +</div> +<!--END GENERATE_TREEVIEW--> +<!--BEGIN !GENERATE_TREEVIEW--> +<div class="footer"> + <address class="footer"><small> +$generatedby  <a href="http://www.doxygen.org/index.html"> + <img class="footer" src="$relpath$doxygen.png" alt="doxygen"/> + </a> $doxygenversion + </small></address> +</div> +<!--END !GENERATE_TREEVIEW--> +</body> +</html> diff --git a/common/doc/header.html b/common/doc/header.html new file mode 100644 index 0000000..7e1046d --- /dev/null +++ b/common/doc/header.html @@ -0,0 +1,52 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> +<meta http-equiv="X-UA-Compatible" content="IE=9"/> +<!--BEGIN PROJECT_NAME--><title>$projectname: $title</title><!--END PROJECT_NAME--> +<!--BEGIN !PROJECT_NAME--><title>$title</title><!--END !PROJECT_NAME--> +<script type="text/javascript" src="$relpath$jquery.js"></script> +<script type="text/javascript" src="$relpath$dynsections.js"></script> +$treeview +$search +$mathjax +<link href="$relpath$css/stylesheet.css" rel="stylesheet" type="text/css" /> +</head> +<body> +<div id="top"><!-- do not remove this div, it is closed by doxygen! --> + +<!--BEGIN TITLEAREA--> +<div id="titlearea"> +<table cellspacing="0" cellpadding="0"> + <tbody> + <tr style="height: 144px;"> + <!--END COMPANY_LOGO--> + <!--BEGIN PROJECT_LOGO--> + <td id="projectlogo"><img alt="Logo" src="$relpath$$projectlogo"/></td> + <!--END PROJECT_LOGO--> + <!--BEGIN PROJECT_NAME--> + <td style="padding-left: 0.5em;"> + <div id="projectname">$projectname + <!--BEGIN PROJECT_NUMBER--> <span id="projectnumber">$projectnumber</span><!--END PROJECT_NUMBER--> + </div> + <!--BEGIN PROJECT_BRIEF--><div id="projectbrief">$projectbrief</div><!--END PROJECT_BRIEF--> + </td> + <!--END PROJECT_NAME--> + <!--BEGIN !PROJECT_NAME--> + <!--BEGIN PROJECT_BRIEF--> + <td style="padding-left: 0.5em;"> + <div id="projectbrief">$projectbrief</div> + </td> + <!--END PROJECT_BRIEF--> + <!--END !PROJECT_NAME--> + <!--BEGIN DISABLE_INDEX--> + <!--BEGIN SEARCHENGINE--> + <td>$searchbox</td> + <!--END SEARCHENGINE--> + <!--END DISABLE_INDEX--> + </tr> + </tbody> +</table> +</div> +<!--END TITLEAREA--> +<!-- end header part --> diff --git a/common/doxygen.mak b/common/doxygen.mak new file mode 100644 index 0000000..4ff3232 --- /dev/null +++ b/common/doxygen.mak @@ -0,0 +1,32 @@ +.PHONY: doc doc-clean doc-internal doc-tar + +PACKAGE_DOC_NAME = $(top_builddir)/$(PACKAGE_TARNAME)-$(PACKAGE_VERSION)-doc +PACKAGE_DOC_CONTENTS = $(top_builddir)/doc/html/ $(top_builddir)/doc/xml/ $(top_builddir)/doc/latex/ $(top_builddir)/doc/man/ + +oneplay-engine.devhelp: doc + xsltproc -o $@ common/doc/doxygen_to_devhelp.xsl doc/xml/index.xml + +doc-clean: + rm -rf $(PACKAGE_DOC_CONTENTS) $(PACKAGE_DOC_NAME).tar* + +doc-internal: doc-clean + doxygen $(top_srcdir)/doc/Doxyfile_internal.dox + cp -r $(top_srcdir)/common/doc/css $(top_builddir)/doc/html/ + rm -rf $(PACKAGE_DOC_NAME).tar* + mkdir -p $(PACKAGE_DOC_NAME)/doc + cp -R $(PACKAGE_DOC_CONTENTS) $(PACKAGE_DOC_NAME)/doc + tar cf $(PACKAGE_DOC_NAME).tar $(PACKAGE_DOC_NAME)/ + bzip2 -9 $(PACKAGE_DOC_NAME).tar + rm -rf $(PACKAGE_DOC_NAME)/ + +doc: doc-clean + doxygen $(top_srcdir)/doc/Doxyfile_api.dox + cp -r $(top_srcdir)/common/doc/css $(top_builddir)/doc/html/ + rm -rf $(PACKAGE_DOC_NAME).tar* + mkdir -p $(PACKAGE_DOC_NAME)/doc + cp -R $(PACKAGE_DOC_CONTENTS) $(PACKAGE_DOC_NAME)/doc + tar cf $(PACKAGE_DOC_NAME).tar $(PACKAGE_DOC_NAME)/ + bzip2 -9 $(PACKAGE_DOC_NAME).tar + rm -rf $(PACKAGE_DOC_NAME)/ + +clean-local: doc-clean diff --git a/common/fluendo-plugins-sdk.props b/common/fluendo-plugins-sdk.props new file mode 100644 index 0000000..a529fe2 --- /dev/null +++ b/common/fluendo-plugins-sdk.props @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ImportGroup Label="PropertySheets" />
+ <PropertyGroup Label="UserMacros" />
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32' or '$(Configuration)|$(Platform)'=='Release|Win32'">
+ <OutDir>$(GSTREAMER_SDK_ROOT_X86)\lib\gstreamer-0.10\fluendo\</OutDir>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64' or '$(Configuration)|$(Platform)'=='Release|x64'">
+ <OutDir>$(GSTREAMER_SDK_ROOT_X86_64)\lib\gstreamer-0.10\fluendo\</OutDir>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_0.10|Win32' or '$(Configuration)|$(Platform)'=='Release_0.10|Win32'">
+ <OutDir>$(GSTREAMER_SDK_ROOT_X86)\lib\gstreamer-0.10\fluendo\</OutDir>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_0.10|x64' or '$(Configuration)|$(Platform)'=='Release_0.10|x64'">
+ <OutDir>$(GSTREAMER_SDK_ROOT_X86_64)\lib\gstreamer-0.10\fluendo\</OutDir>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_1.x|Win32' or '$(Configuration)|$(Platform)'=='Release_1.x|Win32'">
+ <OutDir>$(GSTREAMER_1_0_ROOT_X86)\lib\gstreamer-1.0\fluendo\</OutDir>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug_1.x|x64' or '$(Configuration)|$(Platform)'=='Release_1.x|x64'">
+ <OutDir>$(GSTREAMER_1_0_ROOT_X86_64)\lib\gstreamer-1.0\fluendo\</OutDir>
+ </PropertyGroup>
+ <ItemDefinitionGroup>
+ <ClCompile>
+ <PreprocessorDefinitions>HAVE_CONFIG_H;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <AdditionalIncludeDirectories>..\include;..\..\common;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+ </ClCompile>
+ <Link>
+ <ProgramDatabaseFile>$(TargetDir)\debug\$(TargetName).pdb</ProgramDatabaseFile>
+ </Link>
+ </ItemDefinitionGroup>
+ <ItemGroup />
+</Project>
\ No newline at end of file diff --git a/common/gettext.patch b/common/gettext.patch new file mode 100644 index 0000000..c00eb34 --- /dev/null +++ b/common/gettext.patch @@ -0,0 +1,11 @@ +--- po/Makefile.in.in.orig 2004-01-09 16:35:54.000000000 +0100 ++++ po/Makefile.in.in 2004-01-09 16:36:43.000000000 +0100 +@@ -11,6 +11,9 @@ + PACKAGE = @PACKAGE@ + VERSION = @VERSION@ + ++# thomas: add GETTEXT_PACKAGE substitution as used in Makevars ++GETTEXT_PACKAGE = @GETTEXT_PACKAGE@ ++ + SHELL = /bin/sh + @SET_MAKE@ diff --git a/common/glib-gen.mak b/common/glib-gen.mak new file mode 100644 index 0000000..1de0cd5 --- /dev/null +++ b/common/glib-gen.mak @@ -0,0 +1,42 @@ +# these are the variables your Makefile.am should set +# the example is based on the colorbalance interface + +#glib_enum_headers=$(colorbalance_headers) +#glib_enum_define=GST_COLOR_BALANCE +#glib_enum_prefix=gst_color_balance + +# these are all the rules generating the relevant files +%-marshal.h: %-marshal.list + glib-genmarshal --header --prefix=$(glib_enum_prefix)_marshal $^ > $*-marshal.h.tmp + mv $*-marshal.h.tmp $*-marshal.h + +%-marshal.c: %-marshal.list + echo "#include \"$*-marshal.h\"" >> $*-marshal.c.tmp + glib-genmarshal --body --prefix=$(glib_enum_prefix)_marshal $^ >> $*-marshal.c.tmp + mv $*-marshal.c.tmp $*-marshal.c + +%-enumtypes.h: $(glib_enum_headers) + glib-mkenums \ + --fhead "#ifndef __$(glib_enum_define)_ENUM_TYPES_H__\n#define __$(glib_enum_define)_ENUM_TYPES_H__\n\n#include <glib-object.h>\n\nG_BEGIN_DECLS\n" \ + --fprod "/* enumerations from \"@filename@\" */\n" \ + --vhead "GType @enum_name@_get_type (void);\n#define GST_TYPE_@ENUMSHORT@ (@enum_name@_get_type())\n" \ + --ftail "G_END_DECLS\n\n#endif /* __$(glib_enum_define)_ENUM_TYPES_H__ */" \ + $^ > $@ + +%-enumtypes.c: $(glib_enum_headers) + @if test "x$(glib_enum_headers)" == "x"; then echo "ERROR: glib_enum_headers is empty, please fix Makefile"; exit 1; fi + glib-mkenums \ + --fhead "#include <$*.h>" \ + --fprod "\n/* enumerations from \"@filename@\" */" \ + --vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \ + --vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \ + --vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \ + $^ > $@ + +# a hack rule to make sure .Plo files exist because they get include'd +# from Makefile's +.deps/%-marshal.Plo: + touch $@ + +.deps/%-enumtypes.Plo: + touch $@ diff --git a/common/gst-autogen.sh b/common/gst-autogen.sh new file mode 100644 index 0000000..6d942c5 --- /dev/null +++ b/common/gst-autogen.sh @@ -0,0 +1,319 @@ +# a silly hack that generates autoregen.sh but it's handy +echo "#!/bin/sh" > autoregen.sh +echo "./autogen.sh $@ \$@" >> autoregen.sh +chmod +x autoregen.sh + +# helper functions for autogen.sh + +debug () +# print out a debug message if DEBUG is a defined variable +{ + if test ! -z "$DEBUG" + then + echo "DEBUG: $1" + fi +} + +version_check () +# check the version of a package +# first argument : package name (executable) +# second argument : optional path where to look for it instead +# third argument : source download url +# rest of arguments : major, minor, micro version +# all consecutive ones : suggestions for binaries to use +# (if not specified in second argument) +{ + PACKAGE=$1 + PKG_PATH=$2 + URL=$3 + MAJOR=$4 + MINOR=$5 + MICRO=$6 + + # for backwards compatibility, we let PKG_PATH=PACKAGE when PKG_PATH null + if test -z "$PKG_PATH"; then PKG_PATH=$PACKAGE; fi + debug "major $MAJOR minor $MINOR micro $MICRO" + VERSION=$MAJOR + if test ! -z "$MINOR"; then VERSION=$VERSION.$MINOR; else MINOR=0; fi + if test ! -z "$MICRO"; then VERSION=$VERSION.$MICRO; else MICRO=0; fi + + debug "major $MAJOR minor $MINOR micro $MICRO" + + for SUGGESTION in $PKG_PATH; do + COMMAND="$SUGGESTION" + + # don't check if asked not to + test -z "$NOCHECK" && { + echo -n " checking for $COMMAND >= $VERSION ... " + } || { + # we set a var with the same name as the package, but stripped of + # unwanted chars + VAR=`echo $PACKAGE | sed 's/-//g'` + debug "setting $VAR" + eval $VAR="$COMMAND" + return 0 + } + + debug "checking version with $COMMAND" + ($COMMAND --version) < /dev/null > /dev/null 2>&1 || + { + echo "not found." + continue + } + # strip everything that's not a digit, then use cut to get the first field + pkg_version=`$COMMAND --version|head -n 1|sed 's/^[^0-9]*//'|cut -d' ' -f1` + debug "pkg_version $pkg_version" + # remove any non-digit characters from the version numbers to permit numeric + # comparison + pkg_major=`echo $pkg_version | cut -d. -f1 | sed s/[a-zA-Z\-].*//g` + pkg_minor=`echo $pkg_version | cut -d. -f2 | sed s/[a-zA-Z\-].*//g` + pkg_micro=`echo $pkg_version | cut -d. -f3 | sed s/[a-zA-Z\-].*//g` + test -z "$pkg_major" && pkg_major=0 + test -z "$pkg_minor" && pkg_minor=0 + test -z "$pkg_micro" && pkg_micro=0 + debug "found major $pkg_major minor $pkg_minor micro $pkg_micro" + + #start checking the version + debug "version check" + + # reset check + WRONG= + + if [ ! "$pkg_major" -gt "$MAJOR" ]; then + debug "major: $pkg_major <= $MAJOR" + if [ "$pkg_major" -lt "$MAJOR" ]; then + debug "major: $pkg_major < $MAJOR" + WRONG=1 + elif [ ! "$pkg_minor" -gt "$MINOR" ]; then + debug "minor: $pkg_minor <= $MINOR" + if [ "$pkg_minor" -lt "$MINOR" ]; then + debug "minor: $pkg_minor < $MINOR" + WRONG=1 + elif [ "$pkg_micro" -lt "$MICRO" ]; then + debug "micro: $pkg_micro < $MICRO" + WRONG=1 + fi + fi + fi + + if test ! -z "$WRONG"; then + echo "found $pkg_version, not ok !" + continue + else + echo "found $pkg_version, ok." + # we set a var with the same name as the package, but stripped of + # unwanted chars + VAR=`echo $PACKAGE | sed 's/-//g'` + debug "setting $VAR" + eval $VAR="$COMMAND" + return 0 + fi + done + + echo "not found !" + echo "You must have $PACKAGE installed to compile $package." + echo "Download the appropriate package for your distribution," + echo "or get the source tarball at $URL" + return 1; +} + +aclocal_check () +{ + # normally aclocal is part of automake + # so we expect it to be in the same place as automake + # so if a different automake is supplied, we need to adapt as well + # so how's about replacing automake with aclocal in the set var, + # and saving that in $aclocal ? + # note, this will fail if the actual automake isn't called automake* + # or if part of the path before it contains it + if [ -z "$automake" ]; then + echo "Error: no automake variable set !" + return 1 + else + aclocal=`echo $automake | sed s/automake/aclocal/` + debug "aclocal: $aclocal" + if [ "$aclocal" != "aclocal" ]; + then + CONFIGURE_DEF_OPT="$CONFIGURE_DEF_OPT --with-aclocal=$aclocal" + fi + if [ ! -x `which $aclocal` ]; then + echo "Error: cannot execute $aclocal !" + return 1 + fi + fi +} + +autoheader_check () +{ + # same here - autoheader is part of autoconf + # use the same voodoo + if [ -z "$autoconf" ]; then + echo "Error: no autoconf variable set !" + return 1 + else + autoheader=`echo $autoconf | sed s/autoconf/autoheader/` + debug "autoheader: $autoheader" + if [ "$autoheader" != "autoheader" ]; + then + CONFIGURE_DEF_OPT="$CONFIGURE_DEF_OPT --with-autoheader=$autoheader" + fi + if [ ! -x `which $autoheader` ]; then + echo "Error: cannot execute $autoheader !" + return 1 + fi + fi + +} +autoconf_2_52d_check () +{ + # autoconf 2.52d has a weird issue involving a yes:no error + # so don't allow it's use + test -z "$NOCHECK" && { + ac_version=`$autoconf --version|head -n 1|sed 's/^[a-zA-Z\.\ ()]*//;s/ .*$//'` + if test "$ac_version" = "2.52d"; then + echo "autoconf 2.52d has an issue with our current build." + echo "We don't know who's to blame however. So until we do, get a" + echo "regular version. RPM's of a working version are on the gstreamer site." + exit 1 + fi + } + return 0 +} + +die_check () +{ + # call with $DIE + # if set to 1, we need to print something helpful then die + DIE=$1 + if test "x$DIE" = "x1"; + then + echo + echo "- Please get the right tools before proceeding." + echo "- Alternatively, if you're sure we're wrong, run with --nocheck." + exit 1 + fi +} + +autogen_options () +{ + if test "x$1" = "x"; then + return 0 + fi + + while test "x$1" != "x" ; do + optarg=`expr "x$1" : 'x[^=]*=\(.*\)'` + case "$1" in + --noconfigure) + NOCONFIGURE=defined + AUTOGEN_EXT_OPT="$AUTOGEN_EXT_OPT --noconfigure" + echo "+ configure run disabled" + shift + ;; + --nocheck) + AUTOGEN_EXT_OPT="$AUTOGEN_EXT_OPT --nocheck" + NOCHECK=defined + echo "+ autotools version check disabled" + shift + ;; + --debug) + DEBUG=defined + AUTOGEN_EXT_OPT="$AUTOGEN_EXT_OPT --debug" + echo "+ debug output enabled" + shift + ;; + --prefix=*) + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT --prefix=$optarg" + echo "+ passing --prefix=$optarg to configure" + shift + ;; + --prefix) + shift + echo "DEBUG: $1" + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT --prefix=$1" + echo "+ passing --prefix=$1 to configure" + shift + ;; + --build=*) + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT --build=$optarg" + echo "+ passing --build=$optarg to configure" + shift + ;; + --build) + shift + echo "DEBUG: $1" + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT --build=$1" + echo "+ passing --build=$1 to configure" + shift + ;; + + -h|--help) + echo "autogen.sh (autogen options) -- (configure options)" + echo "autogen.sh help options: " + echo " --noconfigure don't run the configure script" + echo " --nocheck don't do version checks" + echo " --debug debug the autogen process" + echo " --prefix will be passed on to configure" + echo + echo " --with-autoconf PATH use autoconf in PATH" + echo " --with-automake PATH use automake in PATH" + echo + echo "to pass options to configure, put them as arguments after -- " + exit 1 + ;; + --host=*) + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT --host=$optarg" + echo "+ passing --host=$optarg to configure" + shift + ;; + --with-automake=*) + AUTOMAKE=$optarg + echo "+ using alternate automake in $optarg" + CONFIGURE_DEF_OPT="$CONFIGURE_DEF_OPT --with-automake=$AUTOMAKE" + shift + ;; + --with-autoconf=*) + AUTOCONF=$optarg + echo "+ using alternate autoconf in $optarg" + CONFIGURE_DEF_OPT="$CONFIGURE_DEF_OPT --with-autoconf=$AUTOCONF" + shift + ;; + --disable*|--enable*|--with*) + echo "+ passing option $1 to configure" + CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT $1" + shift + ;; + --) shift ; break ;; + *) echo "- ignoring unknown autogen.sh argument $1"; shift ;; + esac + done + + for arg do CONFIGURE_EXT_OPT="$CONFIGURE_EXT_OPT $arg"; done + if test ! -z "$CONFIGURE_EXT_OPT" + then + echo "+ options passed to configure: $CONFIGURE_EXT_OPT" + fi +} + +toplevel_check () +{ + srcfile=$1 + test -f $srcfile || { + echo "You must run this script in the top-level $package directory" + exit 1 + } +} + + +tool_run () +{ + tool=$1 + options=$2 + run_if_fail=$3 + echo "+ running $tool $options..." + $tool $options || { + echo + echo $tool failed + eval $run_if_fail + exit 1 + } +} diff --git a/common/gst-compat.h b/common/gst-compat.h new file mode 100644 index 0000000..4f05cec --- /dev/null +++ b/common/gst-compat.h @@ -0,0 +1,249 @@ +/* + * FLUENDO S.A. + * Copyright (C) <2012> <support@fluendo.com> + */ + +#ifndef GST_COMPAT_H +#define GST_COMPAT_H + +#include <string.h> + +#include <gst/gst.h> +#include <gst/base/gstadapter.h> + +#if !GLIB_CHECK_VERSION(2,14,0) +#define g_once_init_enter(_token) (!(*(_token))) +#define g_once_init_leave(_token,_value) (*(_token)=(_value)) +#endif + +#if !GLIB_CHECK_VERSION(2,18,0) +typedef unsigned long guintptr; +#endif + +#if (!GLIB_CHECK_VERSION(2,28,0)) +static inline void +g_list_free_full (GList * list, GDestroyNotify free_func) +{ + GList *next = list; + while (next) { + free_func (next->data); + next = g_list_remove_link (next, next); + } +} +#endif + +#ifndef GST_CHECK_VERSION +#define GST_CHECK_VERSION(major,minor,micro) \ + (GST_VERSION_MAJOR > (major) || \ + (GST_VERSION_MAJOR == (major) && GST_VERSION_MINOR > (minor)) || \ + (GST_VERSION_MAJOR == (major) && GST_VERSION_MINOR == (minor) && \ + GST_VERSION_MICRO >= (micro))) +#endif + +#if !GST_CHECK_VERSION(0,10,4) +#define GST_QUERY_TYPE_NAME(query) (gst_query_type_get_name(GST_QUERY_TYPE(query))) +#endif + +#if !GST_CHECK_VERSION(0,10,6) +static inline GstBuffer * +gst_adapter_take_buffer (GstAdapter * adapter, guint nbytes) +{ + GstBuffer *buf = NULL; + + if (G_UNLIKELY (nbytes > adapter->size)) + return NULL; + + buf = gst_buffer_new_and_alloc (nbytes); + + if (G_UNLIKELY (!buf)) + return NULL; + + /* Slow... */ + memcpy (GST_BUFFER_DATA (buf), gst_adapter_peek (adapter, nbytes), nbytes); + + return buf; +} +#endif + +#if !GST_CHECK_VERSION(0,10,7) +#define GST_FLOW_CUSTOM_SUCCESS ((GstFlowReturn)100) +#define GST_FLOW_CUSTOM_ERROR ((GstFlowReturn)-100) +#define GST_FLOW_IS_SUCCESS(ret) ((ret) >= GST_FLOW_OK) +#endif + +#if !GST_CHECK_VERSION(0,10,9) +#define GST_BUFFER_IS_DISCONT(buffer) \ + (GST_BUFFER_FLAG_IS_SET (buffer, GST_BUFFER_FLAG_DISCONT)) +#endif + +#if !GST_CHECK_VERSION(0,10,10) +static inline GstPad * +gst_ghost_pad_new_from_template (const gchar * name, GstPad * target, + GstPadTemplate * templ) +{ + GstPad *ret; + + g_return_val_if_fail (GST_IS_PAD (target), NULL); + g_return_val_if_fail (!gst_pad_is_linked (target), NULL); + g_return_val_if_fail (templ != NULL, NULL); + g_return_val_if_fail (GST_PAD_TEMPLATE_DIRECTION (templ) == + GST_PAD_DIRECTION (target), NULL); + + if ((ret = gst_ghost_pad_new_no_target (name, GST_PAD_DIRECTION (target)))) { + if (!gst_ghost_pad_set_target (GST_GHOST_PAD (ret), target)) + goto set_target_failed; + g_object_set (ret, "template", templ, NULL); + } + + return ret; + + /* ERRORS */ +set_target_failed: + { + gst_object_unref (ret); + return NULL; + } +} +#endif + +#if !GST_CHECK_VERSION(0,10,11) +#define gst_message_new_buffering(elem,perc) \ + gst_message_new_custom (GST_MESSAGE_BUFFERING, \ + (elem), \ + gst_structure_new ("GstMessageBuffering", \ + "buffer-percent", G_TYPE_INT, (perc), NULL)) + +#endif + +#if !GST_CHECK_VERSION(0,10,14) +#define gst_element_class_set_details_simple(klass,longname,classification,description,author) \ + G_STMT_START{ \ + static GstElementDetails details = \ + GST_ELEMENT_DETAILS (longname,classification,description,author); \ + gst_element_class_set_details (klass, &details); \ + }G_STMT_END +#endif + +#if !GST_CHECK_VERSION(0,10,15) +#define gst_structure_get_uint(stru,fn,fv) \ + gst_structure_get_int(stru,fn,(gint*)fv) +#endif + +#if !GST_CHECK_VERSION(0,10,20) +static inline gboolean +gst_event_has_name (GstEvent * event, const gchar * name) +{ + g_return_val_if_fail (GST_IS_EVENT (event), FALSE); + + if (event->structure == NULL) + return FALSE; + + return gst_structure_has_name (event->structure, name); +} +#endif + +#if !GST_CHECK_VERSION(0,10,23) +#define GST_BUFFER_FLAG_MEDIA1 (GST_MINI_OBJECT_FLAG_LAST << 5) +#define GST_BUFFER_FLAG_MEDIA2 (GST_MINI_OBJECT_FLAG_LAST << 6) +#define GST_BUFFER_FLAG_MEDIA3 (GST_MINI_OBJECT_FLAG_LAST << 7) + +#define GST_MEMDUMP(_title, _data, _length) while (0) +#define GST_MEMDUMP_OBJECT(_object, _title, _data, _length) while (0) +#endif + +#if !GST_CHECK_VERSION(0,10,24) +static inline void +gst_object_ref_sink (gpointer object) +{ + g_return_if_fail (GST_IS_OBJECT (object)); + + GST_OBJECT_LOCK (object); + if (G_LIKELY (GST_OBJECT_IS_FLOATING (object))) { + GST_OBJECT_FLAG_UNSET (object, GST_OBJECT_FLOATING); + GST_OBJECT_UNLOCK (object); + } else { + GST_OBJECT_UNLOCK (object); + gst_object_ref (object); + } +} +#endif + +#if !GST_CHECK_VERSION(0,10,26) +static inline void +gst_caps_set_value (GstCaps *caps, const char *field, const GValue *value) +{ + GstStructure *structure; + structure = gst_caps_get_structure (caps, 0); + gst_structure_set_value (structure, field, value); +} +#endif + +#if !GST_CHECK_VERSION(0,10,30) +static inline GstStructure * +gst_caps_steal_structure (GstCaps * caps, guint index) +{ + GstStructure *s; + g_return_val_if_fail (caps != NULL, NULL); + g_return_val_if_fail ((g_atomic_int_get (&(caps)->refcount) == 1), NULL); + + if (G_UNLIKELY (index >= caps->structs->len)) + return NULL; + + s = (GstStructure *)g_ptr_array_remove_index (caps->structs, index); + gst_structure_set_parent_refcount (s, NULL); + return s; +} + +#define GST_TRACE_OBJECT(...) G_STMT_START{ }G_STMT_END +#define GST_TRACE(...) G_STMT_START{ }G_STMT_END +#endif + +#if !GST_CHECK_VERSION(0,10,33) +#define GST_MINI_OBJECT_FLAG_RESERVED1 (1<<1) +#define GST_BUFFER_FLAG_MEDIA4 GST_MINI_OBJECT_FLAG_RESERVED1 +#endif + +#if !GST_CHECK_VERSION (1,0,0) + +typedef struct { + guint8 * data; + gsize size; +} GstMapInfo; + +typedef enum { + GST_MAP_READ = 1 << 0, + GST_MAP_WRITE = 1 << 1 +} GstMapFlags; + +static inline gboolean +gst_buffer_map (GstBuffer * buffer, GstMapInfo * info, GstMapFlags flags) +{ + info->data = GST_BUFFER_DATA (buffer); + info->size = GST_BUFFER_SIZE (buffer); + return TRUE; +} + +#define gst_buffer_unmap(buffer,info) while(0) +#define gst_buffer_get_size(buffer) ((gsize) GST_BUFFER_SIZE((buffer))) + +#define GST_FLOW_EOS GST_FLOW_UNEXPECTED +#define GST_FLOW_FLUSHING GST_FLOW_WRONG_STATE + +static inline GstBuffer * +gst_buffer_new_wrapped (gpointer data, gsize size) +{ + GstBuffer * buffer = gst_buffer_new (); + + GST_BUFFER_DATA (buffer) = GST_BUFFER_MALLOCDATA (buffer) = (guint8 *) data; + GST_BUFFER_SIZE (buffer) = size; + + return buffer; +} + +#define gst_adapter_map gst_adapter_peek +#define gst_adapter_unmap(adapter) while(0) +#define gst_segment_do_seek gst_segment_set_seek +#define gst_tag_list_new_empty gst_tag_list_new + +#endif +#endif /* GST_COMPAT_H */ diff --git a/common/gst-demo.h b/common/gst-demo.h new file mode 100644 index 0000000..452f46d --- /dev/null +++ b/common/gst-demo.h @@ -0,0 +1,223 @@ +#ifndef _GST_DEMO_H_ +#define _GST_DEMO_H_ + +#if GST_CHECK_VERSION (1,0,0) +#include <gst/audio/gstaudiodecoder.h> +#include <gst/video/gstvideodecoder.h> +#include <gst/audio/gstaudioencoder.h> +#endif + +typedef struct _GstFluDemoStatistics { + gint64 max_duration; + gint64 decoded_duration; +} GstFluDemoStatistics; + +static inline void +gstflu_demo_reset_statistics (GstFluDemoStatistics * stats) +{ + /* 3 minutes case we can't figure out the duration of the clip */ + stats->max_duration = GST_SECOND * 60 * 3; + stats->decoded_duration = GST_CLOCK_TIME_NONE; +} + +static inline void +gstflu_demo_validate_duration (GstFluDemoStatistics * stats, gint64 duration) +{ +#if ENABLE_DEMO_PLUGIN + if (!GST_CLOCK_TIME_IS_VALID (stats->decoded_duration)) { + stats->max_duration = gst_util_uint64_scale_int (duration, DEMO_PERCENT, 100); + /* max 30 minutes */ + if (stats->max_duration > (GST_SECOND * 60 * 30)) + stats->max_duration = GST_SECOND * 60 * 30; + /* min 3 minutes */ + else if (stats->max_duration < (GST_SECOND * 60 * 3)) + stats->max_duration = GST_SECOND * 60 * 3; + stats->decoded_duration = 0; + } +#endif +} + +static inline void +gstflu_demo_setup_statistics (GstFluDemoStatistics * stats, GstPad * sink) +{ + GstQuery *q; + GstPad *peer; + GstFormat fmt; + gint64 duration; + + gstflu_demo_reset_statistics (stats); + + if (!sink) + goto done; + + peer = gst_pad_get_peer (sink); + if (!peer) + goto done; + + q = gst_query_new_duration (GST_FORMAT_TIME); + if (!q) goto p_out; + + if (!gst_pad_query (peer, q)) + goto q_out; + + gst_query_parse_duration (q, &fmt, &duration); + if (fmt == GST_FORMAT_TIME && GST_CLOCK_TIME_IS_VALID ((guint64)duration)) { + gstflu_demo_validate_duration (stats, duration); + } + +q_out: + gst_query_unref (q); +p_out: + gst_object_unref (peer); +done: + stats->decoded_duration = 0; +} + +static inline GstFlowReturn +gstflu_demo_check_buffer (GstFluDemoStatistics * stats, GstPad * sink, + GstPad * src, GstClockTime duration) +{ +#if ENABLE_DEMO_PLUGIN + GstElement *element; + + element = gst_pad_get_parent_element (src); + + if (GST_STATE_PLAYING != GST_STATE (element)) { + gst_object_unref (element); + return GST_FLOW_OK; + } + + if (!GST_CLOCK_TIME_IS_VALID (stats->decoded_duration)) { + gstflu_demo_setup_statistics (stats, sink); + stats->decoded_duration = 0; + } + + stats->decoded_duration += duration; + if (G_UNLIKELY (stats->decoded_duration >= stats->max_duration)) { + GST_ELEMENT_ERROR (element, STREAM, FAILED, + ("Fluendo decoders terminated playback of this media" + " stream as this is an evaluation version of Fluendo's" + " technology. To get a licensed copy of this Fluendo" + " product please contact sales@fluendo.com."), + (NULL)); + gst_object_unref (element); + return GST_FLOW_EOS; + } else { + gst_object_unref (element); + return GST_FLOW_OK; + } +#else + return GST_FLOW_OK; +#endif +} + +static inline GstFlowReturn +gstflu_demo_push_buffer (GstFluDemoStatistics * stats, GstPad * sink, + GstPad * src, GstBuffer * buf) +{ + GstFlowReturn ret; + if ((ret = gstflu_demo_check_buffer (stats, sink, src, + GST_BUFFER_DURATION (buf))) != GST_FLOW_OK) + gst_buffer_unref (buf); + else + ret = gst_pad_push (src, buf); + return ret; +} + +static inline GstFlowReturn +gstflu_demo_check_video_buffer (GstFluDemoStatistics * stats, GstPad * sink, + GstPad * src, gint fps_n, gint fps_d) +{ +#if ENABLE_DEMO_PLUGIN + return gstflu_demo_check_buffer (stats, sink, src, + gst_util_uint64_scale_int (fps_d, GST_SECOND, fps_n)); +#else + return GST_FLOW_OK; +#endif +} + +static inline GstFlowReturn +gstflu_demo_check_audio_buffer (GstFluDemoStatistics * stats, GstPad * sink, + GstPad * src, gsize size, gint rate, gint channels, gint width) +{ +#if ENABLE_DEMO_PLUGIN + gint bs = channels * rate * (width >> 3); + + return gstflu_demo_check_buffer (stats, sink, src, + gst_util_uint64_scale_int (size, GST_SECOND, bs)); +#else + return GST_FLOW_OK; +#endif +} + +#if GST_CHECK_VERSION (1,0,0) + +static inline GstFlowReturn +gstflu_demo_finish_audio_decoder_buffer (GstFluDemoStatistics * stats, + GstAudioDecoder * dec, GstBuffer * buf, gint frames) +{ + GstFlowReturn ret; + GstAudioInfo *info; + + info = gst_audio_decoder_get_audio_info (dec); + if ((ret = gstflu_demo_check_audio_buffer (stats, + GST_AUDIO_DECODER_SINK_PAD (dec), GST_AUDIO_DECODER_SRC_PAD (dec), + gst_buffer_get_size (buf), GST_AUDIO_INFO_RATE (info), + GST_AUDIO_INFO_CHANNELS (info), GST_AUDIO_INFO_DEPTH (info))) + == GST_FLOW_OK) + ret = gst_audio_decoder_finish_frame (dec, buf, frames); + else + gst_buffer_unref (buf); + return ret; +} + +static inline GstFlowReturn +gstflu_demo_check_video_decoder_frame (GstFluDemoStatistics * stats, + GstVideoDecoder * dec, GstVideoCodecFrame * frame) +{ +#if ENABLE_DEMO_PLUGIN + return gstflu_demo_check_buffer (stats, + GST_VIDEO_DECODER_SINK_PAD (dec), + GST_VIDEO_DECODER_SRC_PAD (dec), + frame->duration); +#else + return GST_FLOW_OK; +#endif +} + +static inline GstFlowReturn +gstflu_demo_finish_video_decoder_frame (GstFluDemoStatistics * stats, + GstVideoDecoder * dec, GstVideoCodecFrame * frame) +{ + GstFlowReturn ret; + + if ((ret = gstflu_demo_check_video_decoder_frame (stats, dec, frame)) + == GST_FLOW_OK) + ret = gst_video_decoder_finish_frame (dec, frame); + else + gst_video_decoder_drop_frame (dec, frame); + return ret; +} + +static inline GstFlowReturn +gstflu_demo_finish_audio_encoder_frame (GstFluDemoStatistics * stats, + GstAudioEncoder * enc, GstBuffer * buf, gint samples) +{ + GstFlowReturn ret; + GstAudioInfo *info; + + info = gst_audio_encoder_get_audio_info (enc); + if ((ret = gstflu_demo_check_audio_buffer (stats, + GST_AUDIO_ENCODER_SINK_PAD (enc), GST_AUDIO_ENCODER_SRC_PAD (enc), + gst_buffer_get_size (buf), GST_AUDIO_INFO_RATE (info), + GST_AUDIO_INFO_CHANNELS (info), GST_AUDIO_INFO_DEPTH (info))) + == GST_FLOW_OK) + ret = gst_audio_encoder_finish_frame (enc, buf, samples); + else + gst_buffer_unref (buf); + return ret; +} + +#endif + +#endif diff --git a/common/gst-fluendo.h b/common/gst-fluendo.h new file mode 100644 index 0000000..ee8ca10 --- /dev/null +++ b/common/gst-fluendo.h @@ -0,0 +1,57 @@ +#ifndef _GST_FLUENDO_H_ +#define _GST_FLUENDO_H_ + +#if (GST_VERSION_MAJOR == 1) +#define GST_PLUGIN_DEFINE_WRAP(major, minor, name, desc, init, version, license, pkg ,url) \ + GST_PLUGIN_DEFINE(major, minor, name, desc, init, version, license, pkg, url) +#else +#define GST_PLUGIN_DEFINE_WRAP(major, minor, name, desc, init, version, license, pkg, url) \ + GST_PLUGIN_DEFINE(major, minor, #name, desc, init, version, license, pkg, url) +#endif + +#ifndef GST_PLUGIN_DEFINE2 +#if defined(GST_PLUGIN_BUILD_STATIC) +#define GST_PLUGIN_DEFINE2(major, minor, name, desc, init, version, license, pkg, url) \ + gboolean gst_##name##_init_static() { \ + return gst_plugin_register_static(major, minor, #name, desc, init, \ + version, license, "Fluendo", pkg, url); \ + } +#else +#define GST_PLUGIN_DEFINE2 GST_PLUGIN_DEFINE_WRAP +#endif +#endif + +#if ENABLE_DEMO_PLUGIN +#define FLUENDO_PLUGIN_DEFINE(major, minor, name, fun, desc, init, version, \ + license,pkg,url) \ + GST_PLUGIN_DEFINE2(major, minor, fun, desc " [Demo Version]", init, version, license, pkg, url) +#else +#define FLUENDO_PLUGIN_DEFINE(major, minor, name, fun, desc, init, version, \ + license,pkg,url) \ + GST_PLUGIN_DEFINE2(major, minor, fun, desc, init, version, license, pkg, url) +#endif + +#if ENABLE_DEMO_PLUGIN && (!defined (_GST_DEMO_H_)) +#warning "To support Demo plugins include gst-demo.h" +#endif + +#define GSTFLU_SETUP_STATISTICS(sink, stats) +#define GSTFLU_PAD_PUSH(src, buf, stats) gst_pad_push (src, buf) +#define GSTFLU_STATISTICS + + +#ifndef GST_COMPAT_H +#ifndef POST_10_14 +#ifndef POST_1_0 +#define gst_element_class_set_details_simple( \ + klass, longname, classification, description, author) \ + { \ + GstElementDetails details = { \ + longname, classification, description, author}; \ + gst_element_class_set_details (klass, &details); \ + } +#endif +#endif +#endif + +#endif /* _GST_FLUENDO_H_ */ diff --git a/common/gst.supp b/common/gst.supp new file mode 100644 index 0000000..2ad59c1 --- /dev/null +++ b/common/gst.supp @@ -0,0 +1,717 @@ +### this file contains suppressions for valgrind when running +### the gstreamer unit tests +### it might be useful for wider use as well + +### syscall suppressions + +{ + <clone on Wim's Debian> + Memcheck:Param + clone(parent_tidptr) + fun:clone + fun:clone +} + +{ + <clone on Wim's Debian> + Memcheck:Param + clone(child_tidptr) + fun:clone + fun:clone +} + +{ + <clone on Wim's Debian> + Memcheck:Param + clone(tlsinfo) + fun:clone + fun:clone +} + +### glibc suppressions + +{ + <conditional jump on wim's debian 2/2/06> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file +} + +# glibc does not deallocate thread-local storage + +{ + <tls> + Memcheck:Leak + fun:calloc + fun:_dl_allocate_tls + fun:pthread_create@@* +} + +# I get an extra stack entry on x86/dapper +{ + <tls> + Memcheck:Leak + fun:calloc + obj:/lib/ld-2.3.*.so + fun:_dl_allocate_tls + fun:pthread_create@@* +} + + +{ + <pthread strstr> + Memcheck:Cond + fun:strstr + fun:__pthread_initialize_minimal + obj:/lib/libpthread-*.so + obj:/lib/libpthread-*.so + fun:call_init + fun:_dl_init + obj:/lib/ld-*.so +} + +# a thread-related free problem in glibc from Edgard +{ + __libc_freeres_rw_acess + Memcheck:Addr4 + obj:* + obj:* + obj:* + obj:* + obj:* + fun:__libc_freeres +} + +{ + <a conditional jump on wim's debian> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so +} + +# g_module_open-related problems +{ + <started showing up on fc4-quick> + Memcheck:Addr2 + fun:memcpy + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file + fun:gst_registry_scan_path_level + fun:gst_registry_scan_path_level + fun:gst_registry_scan_path_level + fun:init_post + fun:g_option_context_parse + fun:gst_init_check + fun:gst_init + fun:gst_check_init + fun:main +} + +{ + <started showing up on fc4-quick> + Memcheck:Addr4 + fun:memcpy + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file + fun:gst_registry_scan_path_level + fun:gst_registry_scan_path_level + fun:gst_registry_scan_path_level + fun:init_post + fun:g_option_context_parse + fun:gst_init_check + fun:gst_init + fun:gst_check_init + fun:main +} + +{ + <g_module_open on wim's debian> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:do_sym + fun:_dl_sym + fun:dlsym_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlsym + fun:g_module_symbol + fun:g_module_open + fun:gst_plugin_load_file +} + +{ + <g_module_open on wim's debian> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file +} +{ + <g_module_open on wim's debian> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file + fun:gst_plugin_load_by_name + fun:gst_plugin_feature_load +} + +{ + <leak on wim's debian in g_module_open> + Memcheck:Leak + fun:malloc + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open + fun:gst_plugin_load_file + fun:gst_plugin_load_by_name +} + +{ + <invalid read on wim's debian> + Memcheck:Addr4 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so +} + +{ + <invalid read on wim's debian> + Memcheck:Addr4 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run +} + +{ + <invalid read on wim's debian - 2006-02-02> + Memcheck:Addr4 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <invalid read on wim's debian - 2006-02-02> + Memcheck:Addr4 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:dl_open_worker + obj:/lib/ld-2.3.*.so + fun:_dl_open + fun:dlopen_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <invalid read on wim's debian - 2006-02-02> + Memcheck:Addr4 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:do_sym + fun:_dl_sym + fun:dlsym_doit + obj:/lib/ld-2.3.*.so + fun:_dlerror_run + fun:dlsym + fun:g_module_symbol + fun:g_module_open +} + +{ + <futex on Andy's 64-bit ubuntu> + Memcheck:Param + futex(uaddr2) + fun:pthread_once + obj:/lib/libc-2.3.*.so + obj:/lib/libc-2.3.*.so + fun:mbsnrtowcs + fun:vfprintf + fun:vsprintf + fun:sprintf + obj:/lib/libc-2.3.*.so + fun:tmpfile + fun:setup_pipe + fun:setup_messaging_with_key + fun:setup_messaging +} + +# valgrind doesn't allow me to specify a suppression for Addr1, Addr2, Addr4 +# as Addr*, so 3 copies for that; and then 2 of each for that pesky memcpy +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr1 + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr2 + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr4 + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr1 + fun:memcpy + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr2 + fun:memcpy + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} +{ + <Invalid read of size 1, 2, 4 on thomas's FC4> + Memcheck:Addr4 + fun:memcpy + fun:_dl_signal_error + fun:_dl_map_object_deps + fun:dl_open_worker + fun:_dl_catch_error + fun:_dl_open + fun:dlopen_doit + fun:_dl_catch_error + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 + fun:g_module_open +} + +{ + <Addr8 on Andy's AMD64 ubuntu in dl_open> + Memcheck:Addr8 + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/libc-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:_dl_open + obj:/lib/libdl-2.3.*.so + obj:/lib/ld-2.3.*.so +} + +{ + <Conditional jump on Andy's AMD64 ubuntu> + Memcheck:Cond + obj:/lib/ld-2.3.*.so + obj:/lib/libc-2.3.*.so + obj:/lib/ld-2.3.*.so + fun:_dl_open + obj:/lib/libdl-2.3.*.so + obj:/lib/ld-2.3.*.so + obj:/lib/libdl-2.3.*.so + fun:dlopen + fun:g_module_open + fun:gst_plugin_load_file + fun:gst_plugin_load_by_name + fun:gst_plugin_feature_load +} + +{ + <Mike's x86 dapper> + Memcheck:Addr4 + obj:/lib/ld-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libc-2.3.6.so + obj:/lib/ld-2.3.6.so + fun:_dl_open + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + fun:dlopen +} + +{ + <Mike's x86 dapper> + Memcheck:Cond + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libc-2.3.6.so + obj:/lib/ld-2.3.6.so + fun:_dl_open + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + fun:dlopen +} + +{ + <Another dapper one> + Memcheck:Cond + obj:/lib/ld-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libc-2.3.6.so + obj:/lib/ld-2.3.6.so + fun:_dl_open + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/tls/i686/cmov/libdl-2.3.6.so + fun:dlopen +} + +### glib suppressions +{ + <g_parse_debug_string> + Memcheck:Cond + fun:g_parse_debug_string + obj:/usr/lib*/libglib-2.0.so.* + fun:g_slice_alloc + fun:g_slice_alloc0 +} + +{ + <g_type_init malloc> + Memcheck:Leak + fun:malloc + fun:g_malloc + fun:g_strdup + fun:g_quark_from_string + obj:* + obj:* + fun:g_type_register_fundamental + obj:* + fun:g_type_init_with_debug_flags + fun:g_type_init + fun:init_pre +} + +{ + <g_type_init calloc> + Memcheck:Leak + fun:calloc + fun:g_malloc0 + obj:* + obj:* + fun:g_type_register_fundamental +} + +{ + <g_type_init calloc 2> + Memcheck:Leak + fun:calloc + fun:g_malloc0 + obj:* + obj:* + fun:g_type_init_with_debug_flags +} + +{ + <g_type_init calloc 3, GSlice version> + Memcheck:Leak + fun:calloc + fun:g_malloc0 + fun:g_slice_alloc + obj:* + obj:* + fun:g_type_init_with_debug_flags +} + +#pthread memleaks + +{ + Thread creation leak + Memcheck:Leak + fun:calloc + fun:allocate_dtv + fun:_dl_allocate* + fun:_dl_allocate* + fun:__pthread_initialize_minimal +} + +{ + Thread management leak + Memcheck:Leak + fun:calloc + fun:allocate_dtv + fun:_dl_allocate* + fun:_dl_allocate* + fun:__pthread_* +} + +{ + Thread management leak 2 + Memcheck:Leak + fun:memalign + fun:_dl_allocate* + fun:_dl_allocate* + fun:__pthread_* +} + +{ + pthread_create Syscall param write(buf) points to uninitialised byte(s) + Memcheck:Param + write(buf) + fun:pthread_create@@GLIBC_2.2.5 + fun:g_thread_create* + +} + +# nss_parse_* memleak (used by g_option_context_parse) +{ + nss_parse_* memleak + Memcheck:Leak + fun:malloc + fun:nss_parse_service_list + fun:__nss_database_lookup +} + +# liboil suppressions +{ + <liboil cpu_fault_check_try> + Memcheck:Value8 + obj:/usr/lib/liboil-0.3.so.0.1.0 + obj:/usr/lib/liboil-0.3.so.0.1.0 + obj:/usr/lib/liboil-0.3.so.0.1.0 + fun:oil_cpu_fault_check_try + fun:oil_test_check_impl + fun:oil_class_optimize + fun:oil_optimize_all + fun:oil_init +} + +{ + <annoying read error inside dlopen stuff on Ubuntu Dapper x86_64> + Memcheck:Addr8 + obj:/lib/ld-2.3.6.so +} + +{ + <Ubuntu Dapper x86_64> + Memcheck:Param + futex(uaddr2) + fun:pthread_once + obj:/lib/libc-2.3.6.so + obj:/lib/libc-2.3.6.so + fun:setlocale + fun:init_pre + fun:g_option_context_parse + fun:gst_init_check + fun:gst_init + fun:gst_check_init + fun:main +} + +{ + <Ubuntu Dapper x86_64 dlopen stuff again> + Memcheck:Cond + obj:/lib/ld-2.3.6.so + obj:/lib/ld-2.3.6.so + fun:_dl_open + obj:/lib/libdl-2.3.6.so + obj:/lib/ld-2.3.6.so + obj:/lib/libdl-2.3.6.so + fun:dlopen + fun:g_module_open + fun:gst_plugin_load_file +} +# this exists in a bunch of different variations, hence the short tail/trace +{ + <dlopen invalid read of size 4 suppression on tpm's Ubuntu edgy/x86> + Memcheck:Addr4 + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so +} +{ + <and the same for 64bit systems> + Memcheck:Addr8 + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so +} + +# More edgy suppressions (Mike) +{ + <dlopen Condition jump suppressions for Ubuntu Edgy/x86> + Memcheck:Cond + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + fun:dlopen_doit + obj:/lib/ld-2.4.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 +} + +{ + <dlopen Condition jump suppressions for Ubuntu Edgy/x86> + Memcheck:Cond + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + fun:dlopen_doit + obj:/lib/ld-2.4.so + fun:_dlerror_run + fun:dlopen@@GLIBC_2.1 +} + +{ + <dlopen Condition jump suppressions for Ubuntu Edgy/x86> + Memcheck:Cond + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + fun:do_sym + fun:_dl_sym +} + +# This one's overly general, but there's zero other information in the stack +# trace - just these five lines! +{ + <dlopen Condition jump suppressions for Ubuntu Edgy/x86> + Memcheck:Cond + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so +} + +{ + <tls leaks on Edgy/x86> + Memcheck:Leak + fun:calloc + obj:/lib/ld-2.4.so + fun:_dl_allocate_tls + fun:pthread_create@@GLIBC_2.1 +} + diff --git a/common/m4/Makefile.am b/common/m4/Makefile.am new file mode 100644 index 0000000..4106332 --- /dev/null +++ b/common/m4/Makefile.am @@ -0,0 +1,5 @@ +EXTRA_DIST = \ + as-ac-expand.m4 as-version.m4 as-compiler-flag.m4 \ + gst-arch.m4 gst-args.m4 gst-check.m4 gst-error.m4 \ + gst-fionread.m4 gst-plugindir.m4 gst-valgrind.m4 \ + gst-cpu-tune.m4 diff --git a/common/m4/as-ac-expand.m4 b/common/m4/as-ac-expand.m4 new file mode 100644 index 0000000..d6c9e33 --- /dev/null +++ b/common/m4/as-ac-expand.m4 @@ -0,0 +1,43 @@ +dnl as-ac-expand.m4 0.2.0 +dnl autostars m4 macro for expanding directories using configure's prefix +dnl thomas@apestaart.org + +dnl AS_AC_EXPAND(VAR, CONFIGURE_VAR) +dnl example +dnl AS_AC_EXPAND(SYSCONFDIR, $sysconfdir) +dnl will set SYSCONFDIR to /usr/local/etc if prefix=/usr/local + +AC_DEFUN([AS_AC_EXPAND], +[ + EXP_VAR=[$1] + FROM_VAR=[$2] + + dnl first expand prefix and exec_prefix if necessary + prefix_save=$prefix + exec_prefix_save=$exec_prefix + + dnl if no prefix given, then use /usr/local, the default prefix + if test "x$prefix" = "xNONE"; then + prefix="$ac_default_prefix" + fi + dnl if no exec_prefix given, then use prefix + if test "x$exec_prefix" = "xNONE"; then + exec_prefix=$prefix + fi + + full_var="$FROM_VAR" + dnl loop until it doesn't change anymore + while true; do + new_full_var="`eval echo $full_var`" + if test "x$new_full_var" = "x$full_var"; then break; fi + full_var=$new_full_var + done + + dnl clean up + full_var=$new_full_var + AC_SUBST([$1], "$full_var") + + dnl restore prefix and exec_prefix + prefix=$prefix_save + exec_prefix=$exec_prefix_save +]) diff --git a/common/m4/as-compiler-flag.m4 b/common/m4/as-compiler-flag.m4 new file mode 100644 index 0000000..2f0ba19 --- /dev/null +++ b/common/m4/as-compiler-flag.m4 @@ -0,0 +1,25 @@ +dnl as-compiler-flag.m4 0.0.1 +dnl autostars m4 macro for detection of compiler flags +dnl +dnl ds@schleef.org + +AC_DEFUN([AS_COMPILER_FLAG], +[ + AC_MSG_CHECKING([to see if compiler understands $1]) + + save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS $1" + + AC_TRY_COMPILE([ ], [], [flag_ok=yes], [flag_ok=no]) + CFLAGS="$save_CFLAGS" + + if test "X$flag_ok" = Xyes ; then + $2 + true + else + $3 + true + fi + AC_MSG_RESULT([$flag_ok]) +]) + diff --git a/common/m4/as-version.m4 b/common/m4/as-version.m4 new file mode 100644 index 0000000..a5b4399 --- /dev/null +++ b/common/m4/as-version.m4 @@ -0,0 +1,71 @@ +dnl as-version.m4 0.2.0 + +dnl autostars m4 macro for versioning + +dnl Thomas Vander Stichele <thomas at apestaart dot org> + +dnl $Id: as-version.m4,v 1.4 2004/06/01 09:40:05 thomasvs Exp $ + +dnl AS_VERSION + +dnl example +dnl AS_VERSION + +dnl this macro +dnl - AC_SUBST's PACKAGE_VERSION_MAJOR, _MINOR, _MICRO +dnl - AC_SUBST's PACKAGE_VERSION_RELEASE, +dnl which can be used for rpm release fields +dnl - doesn't call AM_INIT_AUTOMAKE anymore because it prevents +dnl maintainer mode from running correctly +dnl +dnl don't forget to put #undef PACKAGE_VERSION_RELEASE in acconfig.h +dnl if you use acconfig.h + +AC_DEFUN([AS_VERSION], +[ + PACKAGE_VERSION_MAJOR=$(echo AC_PACKAGE_VERSION | cut -d'.' -f1) + PACKAGE_VERSION_MINOR=$(echo AC_PACKAGE_VERSION | cut -d'.' -f2) + PACKAGE_VERSION_MICRO=$(echo AC_PACKAGE_VERSION | cut -d'.' -f3) + + AC_SUBST(PACKAGE_VERSION_MAJOR) + AC_SUBST(PACKAGE_VERSION_MINOR) + AC_SUBST(PACKAGE_VERSION_MICRO) +]) + +dnl AS_NANO(ACTION-IF-NO-NANO, [ACTION-IF-NANO]) + +dnl requires AC_INIT to be called before +dnl For projects using a fourth or nano number in your versioning to indicate +dnl development or prerelease snapshots, this macro allows the build to be +dnl set up differently accordingly. + +dnl this macro: +dnl - parses AC_PACKAGE_VERSION, set by AC_INIT, and extracts the nano number +dnl - sets the variable PACKAGE_VERSION_NANO +dnl - sets the variable PACKAGE_VERSION_RELEASE, which can be used +dnl for rpm release fields +dnl - executes ACTION-IF-NO-NANO or ACTION-IF-NANO + +dnl example: +dnl AS_NANO(RELEASE="yes", RELEASE="no") + +AC_DEFUN([AS_NANO], +[ + AC_MSG_CHECKING(nano version) + + NANO=$(echo AC_PACKAGE_VERSION | cut -d'.' -f4) + + if test x"$NANO" = x || test "x$NANO" = "x0" ; then + AC_MSG_RESULT([0 (release)]) + NANO=0 + PACKAGE_VERSION_RELEASE=1 + ifelse([$1], , :, [$1]) + else + AC_MSG_RESULT($NANO) + PACKAGE_VERSION_RELEASE=0.`date +%Y%m%d.%H%M%S` + ifelse([$2], , :, [$2]) + fi + PACKAGE_VERSION_NANO=$NANO + AC_SUBST(PACKAGE_VERSION_NANO) + AC_SUBST(PACKAGE_VERSION_RELEASE) +]) diff --git a/common/m4/ax_check_compile_flag.m4 b/common/m4/ax_check_compile_flag.m4 new file mode 100644 index 0000000..c3a8d69 --- /dev/null +++ b/common/m4/ax_check_compile_flag.m4 @@ -0,0 +1,72 @@ +# =========================================================================== +# http://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS]) +# +# DESCRIPTION +# +# Check whether the given FLAG works with the current language's compiler +# or gives an error. (Warnings, however, are ignored) +# +# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on +# success/failure. +# +# If EXTRA-FLAGS is defined, it is added to the current language's default +# flags (e.g. CFLAGS) when the check is done. The check is thus made with +# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to +# force the compiler to issue an error when a bad flag is given. +# +# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this +# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG. +# +# LICENSE +# +# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de> +# Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com> +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation, either version 3 of the License, or (at your +# option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program. If not, see <http://www.gnu.org/licenses/>. +# +# As a special exception, the respective Autoconf Macro's copyright owner +# gives unlimited permission to copy, distribute and modify the configure +# scripts that are the output of Autoconf when processing the Macro. You +# need not follow the terms of the GNU General Public License when using +# or distributing such scripts, even though portions of the text of the +# Macro appear in them. The GNU General Public License (GPL) does govern +# all other use of the material that constitutes the Autoconf Macro. +# +# This special exception to the GPL applies to versions of the Autoconf +# Macro released by the Autoconf Archive. When you make and distribute a +# modified version of the Autoconf Macro, you may extend this special +# exception to the GPL to apply to your modified version as well. + +#serial 2 + +AC_DEFUN([AX_CHECK_COMPILE_FLAG], +[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX +AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl +AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ + ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS + _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], + [AS_VAR_SET(CACHEVAR,[yes])], + [AS_VAR_SET(CACHEVAR,[no])]) + _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) +AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], + [m4_default([$2], :)], + [m4_default([$3], :)]) +AS_VAR_POPDEF([CACHEVAR])dnl +])dnl AX_CHECK_COMPILE_FLAGS diff --git a/common/m4/ax_create_stdint_h.m4 b/common/m4/ax_create_stdint_h.m4 new file mode 100644 index 0000000..061619f --- /dev/null +++ b/common/m4/ax_create_stdint_h.m4 @@ -0,0 +1,569 @@ +dnl @synopsis AX_CREATE_STDINT_H [( HEADER-TO-GENERATE [, HEDERS-TO-CHECK])] +dnl +dnl the "ISO C9X: 7.18 Integer types <stdint.h>" section requires the +dnl existence of an include file <stdint.h> that defines a set of +dnl typedefs, especially uint8_t,int32_t,uintptr_t. +dnl Many older installations will not provide this file, but some will +dnl have the very same definitions in <inttypes.h>. In other enviroments +dnl we can use the inet-types in <sys/types.h> which would define the +dnl typedefs int8_t and u_int8_t respectivly. +dnl +dnl This macros will create a local "_stdint.h" or the headerfile given as +dnl an argument. In many cases that file will just "#include <stdint.h>" +dnl or "#include <inttypes.h>", while in other environments it will provide +dnl the set of basic 'stdint's definitions/typedefs: +dnl int8_t,uint8_t,int16_t,uint16_t,int32_t,uint32_t,intptr_t,uintptr_t +dnl int_least32_t.. int_fast32_t.. intmax_t +dnl which may or may not rely on the definitions of other files, +dnl or using the AC_CHECK_SIZEOF macro to determine the actual +dnl sizeof each type. +dnl +dnl if your header files require the stdint-types you will want to create an +dnl installable file mylib-int.h that all your other installable header +dnl may include. So if you have a library package named "mylib", just use +dnl AX_CREATE_STDINT_H(mylib-int.h) +dnl in configure.ac and go to install that very header file in Makefile.am +dnl along with the other headers (mylib.h) - and the mylib-specific headers +dnl can simply use "#include <mylib-int.h>" to obtain the stdint-types. +dnl +dnl Remember, if the system already had a valid <stdint.h>, the generated +dnl file will include it directly. No need for fuzzy HAVE_STDINT_H things... +dnl +dnl @, (status: used on new platforms) (see http://ac-archive.sf.net/gstdint/) +dnl @version $Id: ax_create_stdint_h.m4,v 1.2 2004/03/09 14:57:53 thomasvs Exp $ +dnl @author Guido Draheim <guidod@gmx.de> + +AC_DEFUN([AX_CREATE_STDINT_H], +[# ------ AX CREATE STDINT H ------------------------------------- +AC_MSG_CHECKING([for stdint types]) +ac_stdint_h=`echo ifelse($1, , _stdint.h, $1)` +# try to shortcircuit - if the default include path of the compiler +# can find a "stdint.h" header then we assume that all compilers can. +AC_CACHE_VAL([ac_cv_header_stdint_t],[ +old_CXXFLAGS="$CXXFLAGS" ; CXXFLAGS="" +old_CPPFLAGS="$CPPFLAGS" ; CPPFLAGS="" +old_CFLAGS="$CFLAGS" ; CFLAGS="" +AC_TRY_COMPILE([#include <stdint.h>],[int_least32_t v = 0;], +[ac_cv_stdint_result="(assuming C99 compatible system)" + ac_cv_header_stdint_t="stdint.h"; ], +[ac_cv_header_stdint_t=""]) +CXXFLAGS="$old_CXXFLAGS" +CPPFLAGS="$old_CPPFLAGS" +CFLAGS="$old_CFLAGS" ]) + +v="... $ac_cv_header_stdint_h" +if test "$ac_stdint_h" = "stdint.h" ; then + AC_MSG_RESULT([(are you sure you want them in ./stdint.h?)]) +elif test "$ac_stdint_h" = "inttypes.h" ; then + AC_MSG_RESULT([(are you sure you want them in ./inttypes.h?)]) +elif test "_$ac_cv_header_stdint_t" = "_" ; then + AC_MSG_RESULT([(putting them into $ac_stdint_h)$v]) +else + ac_cv_header_stdint="$ac_cv_header_stdint_t" + AC_MSG_RESULT([$ac_cv_header_stdint (shortcircuit)]) +fi + +if test "_$ac_cv_header_stdint_t" = "_" ; then # can not shortcircuit.. + +dnl .....intro message done, now do a few system checks..... +dnl btw, all CHECK_TYPE macros do automatically "DEFINE" a type, therefore +dnl we use the autoconf implementation detail _AC CHECK_TYPE_NEW instead + +inttype_headers=`echo $2 | sed -e 's/,/ /g'` + +ac_cv_stdint_result="(no helpful system typedefs seen)" +AC_CACHE_CHECK([for stdint uintptr_t], [ac_cv_header_stdint_x],[ + ac_cv_header_stdint_x="" # the 1997 typedefs (inttypes.h) + AC_MSG_RESULT([(..)]) + for i in stdint.h inttypes.h sys/inttypes.h $inttype_headers ; do + unset ac_cv_type_uintptr_t + unset ac_cv_type_uint64_t + _AC_CHECK_TYPE_NEW(uintptr_t,[ac_cv_header_stdint_x=$i],dnl + continue,[#include <$i>]) + AC_CHECK_TYPE(uint64_t,[and64="/uint64_t"],[and64=""],[#include<$i>]) + ac_cv_stdint_result="(seen uintptr_t$and64 in $i)" + break; + done + AC_MSG_CHECKING([for stdint uintptr_t]) + ]) + +if test "_$ac_cv_header_stdint_x" = "_" ; then +AC_CACHE_CHECK([for stdint uint32_t], [ac_cv_header_stdint_o],[ + ac_cv_header_stdint_o="" # the 1995 typedefs (sys/inttypes.h) + AC_MSG_RESULT([(..)]) + for i in inttypes.h sys/inttypes.h stdint.h $inttype_headers ; do + unset ac_cv_type_uint32_t + unset ac_cv_type_uint64_t + AC_CHECK_TYPE(uint32_t,[ac_cv_header_stdint_o=$i],dnl + continue,[#include <$i>]) + AC_CHECK_TYPE(uint64_t,[and64="/uint64_t"],[and64=""],[#include<$i>]) + ac_cv_stdint_result="(seen uint32_t$and64 in $i)" + break; + done + AC_MSG_CHECKING([for stdint uint32_t]) + ]) +fi + +if test "_$ac_cv_header_stdint_x" = "_" ; then +if test "_$ac_cv_header_stdint_o" = "_" ; then +AC_CACHE_CHECK([for stdint u_int32_t], [ac_cv_header_stdint_u],[ + ac_cv_header_stdint_u="" # the BSD typedefs (sys/types.h) + AC_MSG_RESULT([(..)]) + for i in sys/types.h inttypes.h sys/inttypes.h $inttype_headers ; do + unset ac_cv_type_u_int32_t + unset ac_cv_type_u_int64_t + AC_CHECK_TYPE(u_int32_t,[ac_cv_header_stdint_u=$i],dnl + continue,[#include <$i>]) + AC_CHECK_TYPE(u_int64_t,[and64="/u_int64_t"],[and64=""],[#include<$i>]) + ac_cv_stdint_result="(seen u_int32_t$and64 in $i)" + break; + done + AC_MSG_CHECKING([for stdint u_int32_t]) + ]) +fi fi + +dnl if there was no good C99 header file, do some typedef checks... +if test "_$ac_cv_header_stdint_x" = "_" ; then + AC_MSG_CHECKING([for stdint datatype model]) + AC_MSG_RESULT([(..)]) + AC_CHECK_SIZEOF(char) + AC_CHECK_SIZEOF(short) + AC_CHECK_SIZEOF(int) + AC_CHECK_SIZEOF(long) + AC_CHECK_SIZEOF(void*) + ac_cv_stdint_char_model="" + ac_cv_stdint_char_model="$ac_cv_stdint_char_model$ac_cv_sizeof_char" + ac_cv_stdint_char_model="$ac_cv_stdint_char_model$ac_cv_sizeof_short" + ac_cv_stdint_char_model="$ac_cv_stdint_char_model$ac_cv_sizeof_int" + ac_cv_stdint_long_model="" + ac_cv_stdint_long_model="$ac_cv_stdint_long_model$ac_cv_sizeof_int" + ac_cv_stdint_long_model="$ac_cv_stdint_long_model$ac_cv_sizeof_long" + ac_cv_stdint_long_model="$ac_cv_stdint_long_model$ac_cv_sizeof_voidp" + name="$ac_cv_stdint_long_model" + case "$ac_cv_stdint_char_model/$ac_cv_stdint_long_model" in + 122/242) name="$name, IP16 (standard 16bit machine)" ;; + 122/244) name="$name, LP32 (standard 32bit mac/win)" ;; + 122/*) name="$name (unusual int16 model)" ;; + 124/444) name="$name, ILP32 (standard 32bit unixish)" ;; + 124/488) name="$name, LP64 (standard 64bit unixish)" ;; + 124/448) name="$name, LLP64 (unusual 64bit unixish)" ;; + 124/*) name="$name (unusual int32 model)" ;; + 128/888) name="$name, ILP64 (unusual 64bit numeric)" ;; + 128/*) name="$name (unusual int64 model)" ;; + 222/*|444/*) name="$name (unusual dsptype)" ;; + *) name="$name (very unusal model)" ;; + esac + AC_MSG_RESULT([combined for stdint datatype model... $name]) +fi + +if test "_$ac_cv_header_stdint_x" != "_" ; then + ac_cv_header_stdint="$ac_cv_header_stdint_x" +elif test "_$ac_cv_header_stdint_o" != "_" ; then + ac_cv_header_stdint="$ac_cv_header_stdint_o" +elif test "_$ac_cv_header_stdint_u" != "_" ; then + ac_cv_header_stdint="$ac_cv_header_stdint_u" +else + ac_cv_header_stdint="stddef.h" +fi + +AC_MSG_CHECKING([for extra inttypes in chosen header]) +AC_MSG_RESULT([($ac_cv_header_stdint)]) +dnl see if int_least and int_fast types are present in _this_ header. +unset ac_cv_type_int_least32_t +unset ac_cv_type_int_fast32_t +AC_CHECK_TYPE(int_least32_t,,,[#include <$ac_cv_header_stdint>]) +AC_CHECK_TYPE(int_fast32_t,,,[#include<$ac_cv_header_stdint>]) +AC_CHECK_TYPE(intmax_t,,,[#include <$ac_cv_header_stdint>]) + +fi # shortcircut to system "stdint.h" +# ------------------ PREPARE VARIABLES ------------------------------ +if test "$GCC" = "yes" ; then +ac_cv_stdint_message="using gnu compiler "`$CC --version | head -n 1` +else +ac_cv_stdint_message="using $CC" +fi + +AC_MSG_RESULT([make use of $ac_cv_header_stdint in $ac_stdint_h dnl +$ac_cv_stdint_result]) + +# ----------------- DONE inttypes.h checks START header ------------- +AC_CONFIG_COMMANDS([$ac_stdint_h],[ +AC_MSG_NOTICE(creating $ac_stdint_h : $_ac_stdint_h) +ac_stdint=$tmp/_stdint.h + +echo "#ifndef" $_ac_stdint_h >$ac_stdint +echo "#define" $_ac_stdint_h "1" >>$ac_stdint +echo "#ifndef" _GENERATED_STDINT_H >>$ac_stdint +echo "#define" _GENERATED_STDINT_H '"'$PACKAGE $VERSION'"' >>$ac_stdint +echo "/* generated $ac_cv_stdint_message */" >>$ac_stdint +if test "_$ac_cv_header_stdint_t" != "_" ; then +echo "#define _STDINT_HAVE_STDINT_H" "1" >>$ac_stdint +fi + +cat >>$ac_stdint <<STDINT_EOF + +/* ................... shortcircuit part ........................... */ + +#if defined HAVE_STDINT_H || defined _STDINT_HAVE_STDINT_H +#include <stdint.h> +#else +#include <stddef.h> + +/* .................... configured part ............................ */ + +STDINT_EOF + +echo "/* whether we have a C99 compatible stdint header file */" >>$ac_stdint +if test "_$ac_cv_header_stdint_x" != "_" ; then + ac_header="$ac_cv_header_stdint_x" + echo "#define _STDINT_HEADER_INTPTR" '"'"$ac_header"'"' >>$ac_stdint +else + echo "/* #undef _STDINT_HEADER_INTPTR */" >>$ac_stdint +fi + +echo "/* whether we have a C96 compatible inttypes header file */" >>$ac_stdint +if test "_$ac_cv_header_stdint_o" != "_" ; then + ac_header="$ac_cv_header_stdint_o" + echo "#define _STDINT_HEADER_UINT32" '"'"$ac_header"'"' >>$ac_stdint +else + echo "/* #undef _STDINT_HEADER_UINT32 */" >>$ac_stdint +fi + +echo "/* whether we have a BSD compatible inet types header */" >>$ac_stdint +if test "_$ac_cv_header_stdint_u" != "_" ; then + ac_header="$ac_cv_header_stdint_u" + echo "#define _STDINT_HEADER_U_INT32" '"'"$ac_header"'"' >>$ac_stdint +else + echo "/* #undef _STDINT_HEADER_U_INT32 */" >>$ac_stdint +fi + +echo "" >>$ac_stdint + +if test "_$ac_header" != "_" ; then if test "$ac_header" != "stddef.h" ; then + echo "#include <$ac_header>" >>$ac_stdint + echo "" >>$ac_stdint +fi fi + +echo "/* which 64bit typedef has been found */" >>$ac_stdint +if test "$ac_cv_type_uint64_t" = "yes" ; then +echo "#define _STDINT_HAVE_UINT64_T" "1" >>$ac_stdint +else +echo "/* #undef _STDINT_HAVE_UINT64_T */" >>$ac_stdint +fi +if test "$ac_cv_type_u_int64_t" = "yes" ; then +echo "#define _STDINT_HAVE_U_INT64_T" "1" >>$ac_stdint +else +echo "/* #undef _STDINT_HAVE_U_INT64_T */" >>$ac_stdint +fi +echo "" >>$ac_stdint + +echo "/* which type model has been detected */" >>$ac_stdint +if test "_$ac_cv_stdint_char_model" != "_" ; then +echo "#define _STDINT_CHAR_MODEL" "$ac_cv_stdint_char_model" >>$ac_stdint +echo "#define _STDINT_LONG_MODEL" "$ac_cv_stdint_long_model" >>$ac_stdint +else +echo "/* #undef _STDINT_CHAR_MODEL // skipped */" >>$ac_stdint +echo "/* #undef _STDINT_LONG_MODEL // skipped */" >>$ac_stdint +fi +echo "" >>$ac_stdint + +echo "/* whether int_least types were detected */" >>$ac_stdint +if test "$ac_cv_type_int_least32_t" = "yes"; then +echo "#define _STDINT_HAVE_INT_LEAST32_T" "1" >>$ac_stdint +else +echo "/* #undef _STDINT_HAVE_INT_LEAST32_T */" >>$ac_stdint +fi +echo "/* whether int_fast types were detected */" >>$ac_stdint +if test "$ac_cv_type_int_fast32_t" = "yes"; then +echo "#define _STDINT_HAVE_INT_FAST32_T" "1" >>$ac_stdint +else +echo "/* #undef _STDINT_HAVE_INT_FAST32_T */" >>$ac_stdint +fi +echo "/* whether intmax_t type was detected */" >>$ac_stdint +if test "$ac_cv_type_intmax_t" = "yes"; then +echo "#define _STDINT_HAVE_INTMAX_T" "1" >>$ac_stdint +else +echo "/* #undef _STDINT_HAVE_INTMAX_T */" >>$ac_stdint +fi +echo "" >>$ac_stdint + + cat >>$ac_stdint <<STDINT_EOF +/* .................... detections part ............................ */ + +/* whether we need to define bitspecific types from compiler base types */ +#ifndef _STDINT_HEADER_INTPTR +#ifndef _STDINT_HEADER_UINT32 +#ifndef _STDINT_HEADER_U_INT32 +#define _STDINT_NEED_INT_MODEL_T +#else +#define _STDINT_HAVE_U_INT_TYPES +#endif +#endif +#endif + +#ifdef _STDINT_HAVE_U_INT_TYPES +#undef _STDINT_NEED_INT_MODEL_T +#endif + +#ifdef _STDINT_CHAR_MODEL +#if _STDINT_CHAR_MODEL+0 == 122 || _STDINT_CHAR_MODEL+0 == 124 +#ifndef _STDINT_BYTE_MODEL +#define _STDINT_BYTE_MODEL 12 +#endif +#endif +#endif + +#ifndef _STDINT_HAVE_INT_LEAST32_T +#define _STDINT_NEED_INT_LEAST_T +#endif + +#ifndef _STDINT_HAVE_INT_FAST32_T +#define _STDINT_NEED_INT_FAST_T +#endif + +#ifndef _STDINT_HEADER_INTPTR +#define _STDINT_NEED_INTPTR_T +#ifndef _STDINT_HAVE_INTMAX_T +#define _STDINT_NEED_INTMAX_T +#endif +#endif + + +/* .................... definition part ............................ */ + +/* some system headers have good uint64_t */ +#ifndef _HAVE_UINT64_T +#if defined _STDINT_HAVE_UINT64_T || defined HAVE_UINT64_T +#define _HAVE_UINT64_T +#elif defined _STDINT_HAVE_U_INT64_T || defined HAVE_U_INT64_T +#define _HAVE_UINT64_T +typedef u_int64_t uint64_t; +#endif +#endif + +#ifndef _HAVE_UINT64_T +/* .. here are some common heuristics using compiler runtime specifics */ +#if defined __STDC_VERSION__ && defined __STDC_VERSION__ >= 199901L +#define _HAVE_UINT64_T +typedef long long int64_t; +typedef unsigned long long uint64_t; + +#elif !defined __STRICT_ANSI__ +#if defined _MSC_VER || defined __WATCOMC__ || defined __BORLANDC__ +#define _HAVE_UINT64_T +typedef __int64 int64_t; +typedef unsigned __int64 uint64_t; + +#elif defined __GNUC__ || defined __MWERKS__ || defined __ELF__ +/* note: all ELF-systems seem to have loff-support which needs 64-bit */ +#if !defined _NO_LONGLONG +#define _HAVE_UINT64_T +typedef long long int64_t; +typedef unsigned long long uint64_t; +#endif + +#elif defined __alpha || (defined __mips && defined _ABIN32) +#if !defined _NO_LONGLONG +typedef long int64_t; +typedef unsigned long uint64_t; +#endif + /* compiler/cpu type to define int64_t */ +#endif +#endif +#endif + +#if defined _STDINT_HAVE_U_INT_TYPES +/* int8_t int16_t int32_t defined by inet code, redeclare the u_intXX types */ +typedef u_int8_t uint8_t; +typedef u_int16_t uint16_t; +typedef u_int32_t uint32_t; + +/* glibc compatibility */ +#ifndef __int8_t_defined +#define __int8_t_defined +#endif +#endif + +#ifdef _STDINT_NEED_INT_MODEL_T +/* we must guess all the basic types. Apart from byte-adressable system, */ +/* there a few 32-bit-only dsp-systems that we guard with BYTE_MODEL 8-} */ +/* (btw, those nibble-addressable systems are way off, or so we assume) */ + +dnl /* have a look at "64bit and data size neutrality" at */ +dnl /* http://unix.org/version2/whatsnew/login_64bit.html */ +dnl /* (the shorthand "ILP" types always have a "P" part) */ + +#if defined _STDINT_BYTE_MODEL +#if _STDINT_LONG_MODEL+0 == 242 +/* 2:4:2 = IP16 = a normal 16-bit system */ +typedef unsigned char uint8_t; +typedef unsigned short uint16_t; +typedef unsigned long uint32_t; +#ifndef __int8_t_defined +#define __int8_t_defined +typedef char int8_t; +typedef short int16_t; +typedef long int32_t; +#endif +#elif _STDINT_LONG_MODEL+0 == 244 || _STDINT_LONG_MODEL == 444 +/* 2:4:4 = LP32 = a 32-bit system derived from a 16-bit */ +/* 4:4:4 = ILP32 = a normal 32-bit system */ +typedef unsigned char uint8_t; +typedef unsigned short uint16_t; +typedef unsigned int uint32_t; +#ifndef __int8_t_defined +#define __int8_t_defined +typedef char int8_t; +typedef short int16_t; +typedef int int32_t; +#endif +#elif _STDINT_LONG_MODEL+0 == 484 || _STDINT_LONG_MODEL+0 == 488 +/* 4:8:4 = IP32 = a 32-bit system prepared for 64-bit */ +/* 4:8:8 = LP64 = a normal 64-bit system */ +typedef unsigned char uint8_t; +typedef unsigned short uint16_t; +typedef unsigned int uint32_t; +#ifndef __int8_t_defined +#define __int8_t_defined +typedef char int8_t; +typedef short int16_t; +typedef int int32_t; +#endif +/* this system has a "long" of 64bit */ +#ifndef _HAVE_UINT64_T +#define _HAVE_UINT64_T +typedef unsigned long uint64_t; +typedef long int64_t; +#endif +#elif _STDINT_LONG_MODEL+0 == 448 +/* LLP64 a 64-bit system derived from a 32-bit system */ +typedef unsigned char uint8_t; +typedef unsigned short uint16_t; +typedef unsigned int uint32_t; +#ifndef __int8_t_defined +#define __int8_t_defined +typedef char int8_t; +typedef short int16_t; +typedef int int32_t; +#endif +/* assuming the system has a "long long" */ +#ifndef _HAVE_UINT64_T +#define _HAVE_UINT64_T +typedef unsigned long long uint64_t; +typedef long long int64_t; +#endif +#else +#define _STDINT_NO_INT32_T +#endif +#else +#define _STDINT_NO_INT8_T +#define _STDINT_NO_INT32_T +#endif +#endif + +/* + * quote from SunOS-5.8 sys/inttypes.h: + * Use at your own risk. As of February 1996, the committee is squarely + * behind the fixed sized types; the "least" and "fast" types are still being + * discussed. The probability that the "fast" types may be removed before + * the standard is finalized is high enough that they are not currently + * implemented. + */ + +#if defined _STDINT_NEED_INT_LEAST_T +typedef int8_t int_least8_t; +typedef int16_t int_least16_t; +typedef int32_t int_least32_t; +#ifdef _HAVE_UINT64_T +typedef int64_t int_least64_t; +#endif + +typedef uint8_t uint_least8_t; +typedef uint16_t uint_least16_t; +typedef uint32_t uint_least32_t; +#ifdef _HAVE_UINT64_T +typedef uint64_t uint_least64_t; +#endif + /* least types */ +#endif + +#if defined _STDINT_NEED_INT_FAST_T +typedef int8_t int_fast8_t; +typedef int int_fast16_t; +typedef int32_t int_fast32_t; +#ifdef _HAVE_UINT64_T +typedef int64_t int_fast64_t; +#endif + +typedef uint8_t uint_fast8_t; +typedef unsigned uint_fast16_t; +typedef uint32_t uint_fast32_t; +#ifdef _HAVE_UINT64_T +typedef uint64_t uint_fast64_t; +#endif + /* fast types */ +#endif + +#ifdef _STDINT_NEED_INTMAX_T +#ifdef _HAVE_UINT64_T +typedef int64_t intmax_t; +typedef uint64_t uintmax_t; +#else +typedef long intmax_t; +typedef unsigned long uintmax_t; +#endif +#endif + +#ifdef _STDINT_NEED_INTPTR_T +#ifndef __intptr_t_defined +#define __intptr_t_defined +/* we encourage using "long" to store pointer values, never use "int" ! */ +#if _STDINT_LONG_MODEL+0 == 242 || _STDINT_LONG_MODEL+0 == 484 +typedef unsinged int uintptr_t; +typedef int intptr_t; +#elif _STDINT_LONG_MODEL+0 == 244 || _STDINT_LONG_MODEL+0 == 444 +typedef unsigned long uintptr_t; +typedef long intptr_t; +#elif _STDINT_LONG_MODEL+0 == 448 && defined _HAVE_UINT64_T +typedef uint64_t uintptr_t; +typedef int64_t intptr_t; +#else /* matches typical system types ILP32 and LP64 - but not IP16 or LLP64 */ +typedef unsigned long uintptr_t; +typedef long intptr_t; +#endif +#endif +#endif + + /* shortcircuit*/ +#endif + /* once */ +#endif +#endif +STDINT_EOF + if cmp -s $ac_stdint_h $ac_stdint 2>/dev/null; then + AC_MSG_NOTICE([$ac_stdint_h is unchanged]) + else + ac_dir=`AS_DIRNAME(["$ac_stdint_h"])` + AS_MKDIR_P(["$ac_dir"]) + rm -f $ac_stdint_h + mv $ac_stdint $ac_stdint_h + fi +],[# variables for create stdint.h replacement +PACKAGE="$PACKAGE" +VERSION="$VERSION" +ac_stdint_h="$ac_stdint_h" +_ac_stdint_h=AS_TR_CPP(_$PACKAGE-$ac_stdint_h) +ac_cv_stdint_message="$ac_cv_stdint_message" +ac_cv_header_stdint_t="$ac_cv_header_stdint_t" +ac_cv_header_stdint_x="$ac_cv_header_stdint_x" +ac_cv_header_stdint_o="$ac_cv_header_stdint_o" +ac_cv_header_stdint_u="$ac_cv_header_stdint_u" +ac_cv_type_uint64_t="$ac_cv_type_uint64_t" +ac_cv_type_u_int64_t="$ac_cv_type_u_int64_t" +ac_cv_stdint_char_model="$ac_cv_stdint_char_model" +ac_cv_stdint_long_model="$ac_cv_stdint_long_model" +ac_cv_type_int_least32_t="$ac_cv_type_int_least32_t" +ac_cv_type_int_fast32_t="$ac_cv_type_int_fast32_t" +ac_cv_type_intmax_t="$ac_cv_type_intmax_t" +]) +]) diff --git a/common/m4/check.m4 b/common/m4/check.m4 new file mode 100644 index 0000000..19784ae --- /dev/null +++ b/common/m4/check.m4 @@ -0,0 +1,181 @@ +dnl _AM_TRY_CHECK(MINIMUM-VERSION, EXTRA-CFLAGS, EXTRA-LIBS, CHECK-LIB-NAME +dnl [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]) +dnl Test for check, and define CHECK_CFLAGS and CHECK_LIBS +dnl Done this way because of the brokenness that is +dnl https://launchpad.net/distros/ubuntu/+source/check/+bug/5840 +dnl + +AC_DEFUN([_AM_TRY_CHECK], +[ + min_check_version=$1 + extra_cflags=$2 + extra_libs=$3 + check_lib_name=$4 + + CHECK_CFLAGS="$extra_cflags" + CHECK_LIBS="$extra_libs -l$check_lib_name" + + ac_save_CFLAGS="$CFLAGS" + ac_save_LIBS="$LIBS" + + CFLAGS="$CFLAGS $CHECK_CFLAGS" + LIBS="$CHECK_LIBS $LIBS" + + AC_MSG_CHECKING(for check named $check_lib_name - version >= $min_check_version) + + rm -f conf.check-test + dnl unset no_check, since in our second run it would have been set to yes + dnl before + no_check= + AC_TRY_RUN([ +#include <stdio.h> +#include <stdlib.h> + +#include <check.h> + +int main () +{ + int major, minor, micro; + char *tmp_version; + + system ("touch conf.check-test"); + + /* HP/UX 9 (%@#!) writes to sscanf strings */ + tmp_version = strdup("$min_check_version"); + if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + printf("%s, bad version string\n", "$min_check_version"); + return 1; + } + + if ((CHECK_MAJOR_VERSION != check_major_version) || + (CHECK_MINOR_VERSION != check_minor_version) || + (CHECK_MICRO_VERSION != check_micro_version)) + { + printf("\n*** The check header file (version %d.%d.%d) does not match\n", + CHECK_MAJOR_VERSION, CHECK_MINOR_VERSION, CHECK_MICRO_VERSION); + printf("*** the check library (version %d.%d.%d).\n", + check_major_version, check_minor_version, check_micro_version); + return 1; + } + + if ((check_major_version > major) || + ((check_major_version == major) && (check_minor_version > minor)) || + ((check_major_version == major) && (check_minor_version == minor) && (check_micro_version >= micro))) + { + return 0; + } + else + { + printf("\n*** An old version of check (%d.%d.%d) was found.\n", + check_major_version, check_minor_version, check_micro_version); + printf("*** You need a version of check being at least %d.%d.%d.\n", major, minor, micro); + printf("***\n"); + printf("*** If you have already installed a sufficiently new version, this error\n"); + printf("*** probably means that the wrong copy of the check library and header\n"); + printf("*** file is being found. Rerun configure with the --with-check=PATH option\n"); + printf("*** to specify the prefix where the correct version was installed.\n"); + } + + return 1; +} +],, no_check=yes, [echo $ac_n "cross compiling; assumed OK... $ac_c"]) + + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + + if test "x$no_check" = x ; then + AC_MSG_RESULT(yes) + ifelse([$5], , :, [$5]) + else + AC_MSG_RESULT(no) + if test -f conf.check-test ; then + : + else + echo "*** Could not run check test program, checking why..." + CFLAGS="$CFLAGS $CHECK_CFLAGS" + LIBS="$CHECK_LIBS $LIBS" + AC_TRY_LINK([ +#include <stdio.h> +#include <stdlib.h> + +#include <check.h> +], , [ echo "*** The test program compiled, but did not run. This usually means" + echo "*** that the run-time linker is not finding check. You'll need to set your" + echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" + echo "*** to the installed location Also, make sure you have run ldconfig if that" + echo "*** is required on your system" + echo "***" + echo "*** If you have an old version installed, it is best to remove it, although" + echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"], + [ echo "*** The test program failed to compile or link. See the file config.log for" + echo "*** the exact error that occured." ]) + + CFLAGS="$ac_save_CFLAGS" + LIBS="$ac_save_LIBS" + fi + + CHECK_CFLAGS="" + CHECK_LIBS="" + + rm -f conf.check-test + ifelse([$6], , AC_MSG_ERROR([check not found]), [$6]) + fi +]) + + +dnl AM_PATH_CHECK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl Test for check, and define CHECK_CFLAGS and CHECK_LIBS +dnl + +AC_DEFUN([AM_PATH_CHECK], +[ + AC_ARG_WITH(check, + [ --with-check=PATH prefix where check is installed [default=auto]]) + + AC_ARG_WITH(checklibname, + AC_HELP_STRING([--with-check-lib-name=NAME], + [name of the PIC check library (default=check)])) + + min_check_version=ifelse([$1], ,0.8.2,$1) + + if test x$with_check = xno; then + AC_MSG_RESULT(disabled) + ifelse([$3], , AC_MSG_ERROR([disabling check is not supported]), [$3]) + else + if test "x$with_check" != x; then + CHECK_EXTRA_CFLAGS="-I$with_check/include" + CHECK_EXTRA_LIBS="-L$with_check/lib" + else + CHECK_EXTRA_CFLAGS="" + CHECK_EXTRA_LIBS="" + fi + + if test x$with_checklibname = x; then + _AM_TRY_CHECK($min_check_version, $CHECK_EXTRA_CFLAGS, $CHECK_EXTRA_LIBS, + check_pic, [have_check=true], [have_check=false]) + if test x$have_check = xtrue; then + ifelse([$2], , :, [$2]) + else + _AM_TRY_CHECK($min_check_version, $CHECK_EXTRA_CFLAGS, $CHECK_EXTRA_LIBS, + check, [have_check=true], [have_check=false]) + if test x$have_check = xtrue; then + ifelse([$2], , :, [$2]) + else + ifelse([$3], , AC_MSG_ERROR([check not found]), [$3]) + fi + fi + else + _AM_TRY_CHECK($min_check_version, $CHECK_EXTRA_CFLAGS, $CHECK_EXTRA_LIBS, + $with_checklibname, [have_check=true], [have_check=false]) + if test x$have_check = xtrue; then + ifelse([$2], , :, [$2]) + else + ifelse([$3], , AC_MSG_ERROR([check not found]), [$3]) + fi + fi + + AC_SUBST(CHECK_CFLAGS) + AC_SUBST(CHECK_LIBS) + rm -f conf.check-test + fi +]) diff --git a/common/m4/gst-arch.m4 b/common/m4/gst-arch.m4 new file mode 100644 index 0000000..8a32bd2 --- /dev/null +++ b/common/m4/gst-arch.m4 @@ -0,0 +1,123 @@ +dnl AG_GST_ARCH +dnl sets up defines and automake conditionals for host architecture +dnl checks endianness +dnl defines HOST_CPU + +AC_DEFUN([AG_GST_ARCH], +[ + AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use host_ variables + + dnl Determine CPU + case "x${host_cpu}" in + xi?86 | xk? | xi?86_64) + HAVE_CPU_I386=yes + AC_DEFINE(HAVE_CPU_I386, 1, [Define if the host CPU is an x86]) + + dnl FIXME could use some better detection + dnl (ie CPUID) + case "x${host_cpu}" in + xi386 | xi486) ;; + *) + 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 host CPU is a PowerPC]) ;; + xpowerpc64) + HAVE_CPU_PPC64=yes + AC_DEFINE(HAVE_CPU_PPC64, 1, [Define if the host CPU is a 64 bit PowerPC]) ;; + xalpha*) + HAVE_CPU_ALPHA=yes + AC_DEFINE(HAVE_CPU_ALPHA, 1, [Define if the host CPU is an Alpha]) ;; + xarm*) + HAVE_CPU_ARM=yes + AC_DEFINE(HAVE_CPU_ARM, 1, [Define if the host CPU is an ARM]) ;; + xsparc*) + HAVE_CPU_SPARC=yes + AC_DEFINE(HAVE_CPU_SPARC, 1, [Define if the host CPU is a SPARC]) ;; + xmips*) + HAVE_CPU_MIPS=yes + AC_DEFINE(HAVE_CPU_MIPS, 1, [Define if the host CPU is a MIPS]) ;; + xhppa*) + HAVE_CPU_HPPA=yes + AC_DEFINE(HAVE_CPU_HPPA, 1, [Define if the host CPU is a HPPA]) ;; + xs390*) + HAVE_CPU_S390=yes + AC_DEFINE(HAVE_CPU_S390, 1, [Define if the host CPU is a S390]) ;; + xia64*) + HAVE_CPU_IA64=yes + AC_DEFINE(HAVE_CPU_IA64, 1, [Define if the host CPU is a IA64]) ;; + xm68k*) + HAVE_CPU_M68K=yes + AC_DEFINE(HAVE_CPU_M68K, 1, [Define if the host CPU is a M68K]) ;; + xx86_64) + HAVE_CPU_X86_64=yes + AC_DEFINE(HAVE_CPU_X86_64, 1, [Define if the host CPU is a x86_64]) ;; + xcris) + HAVE_CPU_CRIS=yes + AC_DEFINE(HAVE_CPU_CRIS, 1, [Define if the host CPU is a CRIS]) ;; + xcrisv32) + HAVE_CPU_CRISV32=yes + AC_DEFINE(HAVE_CPU_CRISV32, 1, [Define if the host CPU is a CRISv32]) ;; + esac + + dnl Determine endianness + AC_C_BIGENDIAN + + AM_CONDITIONAL(HAVE_CPU_I386, test "x$HAVE_CPU_I386" = "xyes") + AM_CONDITIONAL(HAVE_CPU_PPC, test "x$HAVE_CPU_PPC" = "xyes") + AM_CONDITIONAL(HAVE_CPU_PPC64, test "x$HAVE_CPU_PPC64" = "xyes") + AM_CONDITIONAL(HAVE_CPU_ALPHA, test "x$HAVE_CPU_ALPHA" = "xyes") + AM_CONDITIONAL(HAVE_CPU_ARM, test "x$HAVE_CPU_ARM" = "xyes") + AM_CONDITIONAL(HAVE_CPU_SPARC, test "x$HAVE_CPU_SPARC" = "xyes") + AM_CONDITIONAL(HAVE_CPU_HPPA, test "x$HAVE_CPU_HPPA" = "xyes") + AM_CONDITIONAL(HAVE_CPU_MIPS, test "x$HAVE_CPU_MIPS" = "xyes") + AM_CONDITIONAL(HAVE_CPU_S390, test "x$HAVE_CPU_S390" = "xyes") + AM_CONDITIONAL(HAVE_CPU_IA64, test "x$HAVE_CPU_IA64" = "xyes") + AM_CONDITIONAL(HAVE_CPU_M68K, test "x$HAVE_CPU_M68K" = "xyes") + AM_CONDITIONAL(HAVE_CPU_X86_64, test "x$HAVE_CPU_X86_64" = "xyes") + AM_CONDITIONAL(HAVE_CPU_CRIS, test "x$HAVE_CPU_CRIS" = "xyes") + AM_CONDITIONAL(HAVE_CPU_CRISV32, test "x$HAVE_CPU_CRISV32" = "xyes") + + AC_DEFINE_UNQUOTED(HOST_CPU, "$host_cpu", [the host CPU]) +]) + +dnl check if unaligned memory access works correctly +AC_DEFUN([AG_GST_UNALIGNED_ACCESS], [ + AC_MSG_CHECKING([if unaligned memory access works correctly]) + if test x"$as_cv_unaligned_access" = x ; then + case $host in + alpha*|arm*|hp*|mips*|sh*|sparc*|ia64*) + _AS_ECHO_N([(blacklisted) ]) + as_cv_unaligned_access=no + ;; + i?86*|powerpc*|m68k*|cris*) + _AS_ECHO_N([(whitelisted) ]) + as_cv_unaligned_access=yes + ;; + esac + else + _AS_ECHO_N([(cached) ]) + fi + if test x"$as_cv_unaligned_access" = x ; then + AC_TRY_RUN([ +int main(int argc, char **argv) +{ + char array[] = "ABCDEFGH"; + unsigned int iarray[2]; + memcpy(iarray,array,8); +#define GET(x) (*(unsigned int *)((char *)iarray + (x))) + if(GET(0) != 0x41424344 && GET(0) != 0x44434241) return 1; + if(GET(1) != 0x42434445 && GET(1) != 0x45444342) return 1; + if(GET(2) != 0x43444546 && GET(2) != 0x46454443) return 1; + if(GET(3) != 0x44454647 && GET(3) != 0x47464544) return 1; + return 0; +} + ], as_cv_unaligned_access="yes", as_cv_unaligned_access="no") + fi + AC_MSG_RESULT($as_cv_unaligned_access) + if test "$as_cv_unaligned_access" = "yes"; then + AC_DEFINE_UNQUOTED(HAVE_UNALIGNED_ACCESS, 1, + [defined if unaligned memory access works correctly]) + fi +]) diff --git a/common/m4/gst-args.m4 b/common/m4/gst-args.m4 new file mode 100644 index 0000000..786d3ba --- /dev/null +++ b/common/m4/gst-args.m4 @@ -0,0 +1,275 @@ +dnl configure-time options shared among gstreamer modules + +dnl AG_GST_ARG_DEBUG +dnl AG_GST_ARG_PROFILING +dnl AG_GST_ARG_VALGRIND +dnl AG_GST_ARG_GCOV + +dnl AG_GST_ARG_EXAMPLES + +dnl AG_GST_ARG_WITH_PKG_CONFIG_PATH +dnl AG_GST_ARG_WITH_PACKAGE_NAME +dnl AG_GST_ARG_WITH_PACKAGE_ORIGIN + +dnl AG_GST_ARG_WITH_PLUGINS + +dnl AG_GST_ARG_ENABLE_EXTERNAL +dnl AG_GST_ARG_ENABLE_EXPERIMENTAL +dnl AG_GST_ARG_ENABLE_BROKEN + +AC_DEFUN([AG_GST_ARG_DEBUG], +[ + dnl debugging stuff + AC_ARG_ENABLE(debug, + AC_HELP_STRING([--disable-debug],[disable addition of -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=yes]) dnl Default value +]) + +AC_DEFUN([AG_GST_ARG_PROFILING], +[ + AC_ARG_ENABLE(profiling, + AC_HELP_STRING([--enable-profiling], + [adds -pg to compiler commandline, for profiling]), + [ + case "${enableval}" in + yes) USE_PROFILING=yes ;; + no) USE_PROFILING=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --enable-profiling) ;; + esac + ], + [USE_PROFILING=no]) dnl Default value +]) + +AC_DEFUN([AG_GST_ARG_VALGRIND], +[ + dnl valgrind inclusion + AC_ARG_ENABLE(valgrind, + AC_HELP_STRING([--disable-valgrind],[disable run-time valgrind detection]), + [ + case "${enableval}" in + yes) USE_VALGRIND="$USE_DEBUG" ;; + no) USE_VALGRIND=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --enable-valgrind) ;; + esac + ], + [USE_VALGRIND="$USE_DEBUG"]) dnl Default value + VALGRIND_REQ="2.1" + if test "x$USE_VALGRIND" = xyes; then + PKG_CHECK_MODULES(VALGRIND, valgrind > $VALGRIND_REQ, + USE_VALGRIND="yes", + [ + USE_VALGRIND="no" + AC_MSG_RESULT([no]) + ]) + fi + if test "x$USE_VALGRIND" = xyes; then + AC_DEFINE(HAVE_VALGRIND, 1, [Define if valgrind should be used]) + AC_MSG_NOTICE(Using extra code paths for valgrind) + fi +]) + +AC_DEFUN([AG_GST_ARG_GCOV], +[ + AC_ARG_ENABLE(gcov, + AC_HELP_STRING([--enable-gcov], + [compile with coverage profiling instrumentation (gcc only)]), + enable_gcov=$enableval, + enable_gcov=no) + if test x$enable_gcov = xyes ; then + if test "x$GCC" != "xyes" + then + AC_MSG_ERROR([gcov only works if gcc is used]) + fi + + AS_COMPILER_FLAG(["-fprofile-arcs"], + [GCOV_CFLAGS="$GCOV_CFLAGS -fprofile-arcs"], + true) + AS_COMPILER_FLAG(["-ftest-coverage"], + [GCOV_CFLAGS="$GCOV_CFLAGS -ftest-coverage"], + true) + dnl remove any -O flags - FIXME: is this needed ? + GCOV_CFLAGS=`echo "$GCOV_CFLAGS" | sed -e 's/-O[[0-9]]*//g'` + dnl libtool 1.5.22 and lower strip -fprofile-arcs from the flags + dnl passed to the linker, which is a bug; -fprofile-arcs implicitly + dnl links in -lgcov, so we do it explicitly here for the same effect + GCOV_LIBS=-lgcov + AC_SUBST(GCOV_CFLAGS) + AC_SUBST(GCOV_LIBS) + GCOV=`echo $CC | sed s/gcc/gcov/g` + AC_SUBST(GCOV) + + GST_GCOV_ENABLED=yes + AC_DEFINE_UNQUOTED(GST_GCOV_ENABLED, 1, + [Defined if gcov is enabled to force a rebuild due to config.h changing]) + dnl if gcov is used, we do not want default -O2 CFLAGS + if test "x$GST_GCOV_ENABLED" = "xyes" + then + CFLAGS="-O0" + AC_SUBST(CFLAGS) + CXXFLAGS="-O0" + AC_SUBST(CXXFLAGS) + FFLAGS="-O0" + AC_SUBST(FFLAGS) + CCASFLAGS="-O0" + AC_SUBST(CCASFLAGS) + AC_MSG_NOTICE([gcov enabled, setting CFLAGS and friends to $CFLAGS]) + fi + fi + AM_CONDITIONAL(GST_GCOV_ENABLED, test x$enable_gcov = xyes) +]) + +AC_DEFUN([AG_GST_ARG_EXAMPLES], +[ + AC_ARG_ENABLE(examples, + AC_HELP_STRING([--disable-examples], [disable building examples]), + [ + case "${enableval}" in + yes) BUILD_EXAMPLES=yes ;; + no) BUILD_EXAMPLES=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --disable-examples) ;; + esac + ], + [BUILD_EXAMPLES=yes]) dnl Default value + AM_CONDITIONAL(BUILD_EXAMPLES, test "x$BUILD_EXAMPLES" = "xyes") +]) + +AC_DEFUN([AG_GST_ARG_WITH_PKG_CONFIG_PATH], +[ + dnl possibly 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} + AC_MSG_NOTICE(Set PKG_CONFIG_PATH to $PKG_CONFIG_PATH) + ]) +]) + + +AC_DEFUN([AG_GST_ARG_WITH_PACKAGE_NAME], +[ + dnl package name in plugins + AC_ARG_WITH(package-name, + AC_HELP_STRING([--with-package-name], + [specify package name to use in plugins]), + [ + case "${withval}" in + yes) AC_MSG_ERROR(bad value ${withval} for --with-package-name) ;; + no) AC_MSG_ERROR(bad value ${withval} for --with-package-name) ;; + *) GST_PACKAGE_NAME="${withval}" ;; + esac + ], + [ + P="$1" + if test "x$P" = "x" + then + P=$PACKAGE_NAME + fi + + dnl default value + if test "x$GST_CVS" = "xyes" + then + dnl nano >= 1 + GST_PACKAGE_NAME="$P CVS/prerelease" + else + GST_PACKAGE_NAME="$P source release" + fi + ] + ) + AC_MSG_NOTICE(Using $GST_PACKAGE_NAME as package name) + AC_DEFINE_UNQUOTED(GST_PACKAGE_NAME, "$GST_PACKAGE_NAME", + [package name in plugins]) + AC_SUBST(GST_PACKAGE_NAME) +]) + +AC_DEFUN([AG_GST_ARG_WITH_PACKAGE_ORIGIN], +[ + dnl package origin URL + AC_ARG_WITH(package-origin, + AC_HELP_STRING([--with-package-origin], + [specify package origin URL to use in plugins]), + [ + case "${withval}" in + yes) AC_MSG_ERROR(bad value ${withval} for --with-package-origin) ;; + no) AC_MSG_ERROR(bad value ${withval} for --with-package-origin) ;; + *) GST_PACKAGE_ORIGIN="${withval}" ;; + esac + ], + [GST_PACKAGE_ORIGIN="[Unknown package origin]"] dnl Default value + ) + AC_MSG_NOTICE(Using $GST_PACKAGE_ORIGIN as package origin) + AC_DEFINE_UNQUOTED(GST_PACKAGE_ORIGIN, "$GST_PACKAGE_ORIGIN", + [package origin]) + AC_SUBST(GST_PACKAGE_ORIGIN) +]) + +dnl sets GST_PLUGINS_SELECTED to the list given as an argument, or to +dnl GST_PLUGINS_ALL +AC_DEFUN([AG_GST_ARG_WITH_PLUGINS], +[ + AC_ARG_WITH(plugins, + AC_HELP_STRING([--with-plugins], + [comma-separated list of dependencyless plug-ins to compile]), + [ + for i in `echo $withval | tr , ' '`; do + if echo $GST_PLUGINS_ALL | grep $i > /dev/null + then + GST_PLUGINS_SELECTED="$GST_PLUGINS_SELECTED $i" + else + echo "plug-in $i not recognized, ignoring..." + fi + done], + [GST_PLUGINS_SELECTED=$GST_PLUGINS_ALL]) +]) + +AC_DEFUN([AG_GST_ARG_ENABLE_EXTERNAL], +[ + AG_GST_CHECK_FEATURE(EXTERNAL, [enable building of plug-ins with external deps],, + HAVE_EXTERNAL=yes, enabled, + [ + AC_MSG_NOTICE(building external plug-ins) + BUILD_EXTERNAL="yes" + ],[ + AC_MSG_WARN(all plug-ins with external dependencies will not be built) + BUILD_EXTERNAL="no" + ]) + # make BUILD_EXTERNAL available to Makefile.am + AM_CONDITIONAL(BUILD_EXTERNAL, test "x$BUILD_EXTERNAL" = "xyes") +]) + +dnl experimental plug-ins; stuff that hasn't had the dust settle yet +dnl read 'builds, but might not work' +AC_DEFUN([AG_GST_ARG_ENABLE_EXPERIMENTAL], +[ + AG_GST_CHECK_FEATURE(EXPERIMENTAL, + [building of experimental plug-ins],, + HAVE_EXPERIMENTAL=yes, enabled, + [ + AC_MSG_WARN(building experimental plug-ins) + BUILD_EXPERIMENTAL="yes" + ],[ + AC_MSG_NOTICE(not building experimental plug-ins) + BUILD_EXPERIMENTAL="no" + ]) + # make BUILD_EXPERIMENTAL available to Makefile.am + AM_CONDITIONAL(BUILD_EXPERIMENTAL, test "x$BUILD_EXPERIMENTAL" = "xyes") +]) + +dnl broken plug-ins; stuff that doesn't seem to build at the moment +AC_DEFUN([AG_GST_ARG_ENABLE_BROKEN], +[ + AG_GST_CHECK_FEATURE(BROKEN, [enable building of broken plug-ins],, + HAVE_BROKEN=yes, disabled, + [ + AC_MSG_WARN([building broken plug-ins -- no bug reports on these, only patches ...]) + ],[ + AC_MSG_NOTICE([not building broken plug-ins]) + ]) +]) diff --git a/common/m4/gst-check.m4 b/common/m4/gst-check.m4 new file mode 100644 index 0000000..ebc4eb8 --- /dev/null +++ b/common/m4/gst-check.m4 @@ -0,0 +1,251 @@ +dnl pkg-config-based checks for GStreamer modules and dependency modules + +dnl generic: +dnl AG_GST_PKG_CHECK_MODULES([PREFIX], [WHICH], [REQUIRED]) +dnl sets HAVE_[$PREFIX], [$PREFIX]_* +dnl AG_GST_CHECK_MODULES([PREFIX], [MODULE], [MINVER], [NAME], [REQUIRED]) +dnl sets HAVE_[$PREFIX], [$PREFIX]_* + +dnl specific: +dnl AG_GST_CHECK_GST([MAJMIN], [MINVER], [REQUIRED]) +dnl also sets/ACSUBSTs GST_TOOLS_DIR and GST_PLUGINS_DIR +dnl AG_GST_CHECK_GST_BASE([MAJMIN], [MINVER], [REQUIRED]) +dnl AG_GST_CHECK_GST_GDP([MAJMIN], [MINVER], [REQUIRED]) +dnl AG_GST_CHECK_GST_CONTROLLER([MAJMIN], [MINVER], [REQUIRED]) +dnl AG_GST_CHECK_GST_CHECK([MAJMIN], [MINVER], [REQUIRED]) +dnl AG_GST_CHECK_GST_PLUGINS_BASE([MAJMIN], [MINVER], [REQUIRED]) +dnl also sets/ACSUBSTs GSTPB_PLUGINS_DIR + +AC_DEFUN([AG_GST_PKG_CHECK_MODULES], +[ + which="[$2]" + dnl not required by default, since we use this mostly for plugin deps + required=ifelse([$3], , "no", [$3]) + + PKG_CHECK_MODULES([$1], $which, + [ + HAVE_[$1]="yes" + ], + [ + HAVE_[$1]="no" + AC_MSG_RESULT(no) + if test "x$required" = "xyes"; then + AC_MSG_ERROR($[$1]_PKG_ERRORS) + else + AC_MSG_NOTICE($[$1]_PKG_ERRORS) + fi + ]) + + dnl AC_SUBST of CFLAGS and LIBS was not done before automake 1.7 + dnl It gets done automatically in automake >= 1.7, which we now require +]) + +AC_DEFUN([AG_GST_CHECK_MODULES], +[ + module=[$2] + minver=[$3] + name="[$4]" + required=ifelse([$5], , "yes", [$5]) dnl required by default + + PKG_CHECK_MODULES([$1], $module >= $minver, + [ + HAVE_[$1]="yes" + ], + [ + HAVE_[$1]="no" + AC_MSG_RESULT(no) + AC_MSG_NOTICE($[$1]_PKG_ERRORS) + if test "x$required" = "xyes"; then + AC_MSG_ERROR([no $module >= $minver ($name) found]) + else + AC_MSG_NOTICE([no $module >= $minver ($name) found]) + fi + ]) + + dnl AC_SUBST of CFLAGS and LIBS was not done before automake 1.7 + dnl It gets done automatically in automake >= 1.7, which we now require +]) + +AC_DEFUN([AG_GST_DETECT_VERSION], +[ + AC_ARG_WITH(gstreamer-api, + AC_HELP_STRING([--with-gstreamer-api], + [manually set the gstreamer API version 0.10 or 1.0 are valid values]), + [USE_GSTREAMER_API="${withval}"]) + + case "$USE_GSTREAMER_API" in + 1.0) + PKG_CHECK_MODULES(GST_VER_1_0, gstreamer-1.0 >= [$1], + [GST_REQ=[$1] + GST_MAJORMINOR=1.0], + AC_MSG_ERROR([Could not find gstreamer 1.0 in the system]) + ) + ;; + 0.10) + PKG_CHECK_MODULES(GST_VER_0_10, gstreamer-0.10 >= [$2], + [GST_REQ=[$2] + GST_MAJORMINOR=0.10], + AC_MSG_ERROR([Could not find gstreamer 0.10 in the system]) + ) + ;; + *) + PKG_CHECK_MODULES(GST_VER_1_0, gstreamer-1.0 >= [$1], + [GST_REQ=[$1] + GST_MAJORMINOR=1.0], + [PKG_CHECK_MODULES(GST_VER_0_10, gstreamer-0.10 >= [$2], + [GST_REQ=[$2] + GST_MAJORMINOR=0.10], + AC_MSG_ERROR([Could not find a valid version of gstreamer in the system]) + )] + ) + ;; + esac + + AM_CONDITIONAL([GST_VER_1_0], [test "x$GST_MAJORMINOR" = "x1.0"]) + AM_CONDITIONAL([GST_VER_0_10], [test "x$GST_MAJORMINOR" = "x0.10"]) +]) + +AC_DEFUN([AG_GST_CHECK_GST], +[ + AG_GST_CHECK_MODULES(GST, gstreamer-[$1], [$2], [GStreamer], [$3]) + dnl allow setting before calling this macro to override + if test -z $GST_TOOLS_DIR; then + GST_TOOLS_DIR=`$PKG_CONFIG --variable=toolsdir gstreamer-[$1]` + if test -z $GST_TOOLS_DIR; then + AC_MSG_ERROR( + [no tools dir set in GStreamer pkg-config file, core upgrade needed.]) + fi + fi + AC_MSG_NOTICE([using GStreamer tools in $GST_TOOLS_DIR]) + AC_SUBST(GST_TOOLS_DIR) + + dnl check for where core plug-ins got installed + dnl this is used for unit tests + dnl allow setting before calling this macro to override + if test -z $GST_PLUGINS_DIR; then + GST_PLUGINS_DIR=`$PKG_CONFIG --variable=pluginsdir gstreamer-[$1]` + if test -z $GST_PLUGINS_DIR; then + AC_MSG_ERROR( + [no pluginsdir set in GStreamer pkg-config file, core upgrade needed.]) + fi + fi + AC_MSG_NOTICE([using GStreamer plug-ins in $GST_PLUGINS_DIR]) + AC_SUBST(GST_PLUGINS_DIR) + + if test "x$1" = "x0.10"; then + dnl Check if gestreamer is 0.10.10 or newer, required to know for + dnl printf segment extension. + PKG_CHECK_MODULES(GST_10_10, gstreamer-0.10 >= 0.10.10, + POST_10_10=1, POST_10_10=0) + AC_DEFINE_UNQUOTED(POST_10_10, $POST_10_10, + [GStreamer version is >= 0.10.10]) + + PKG_CHECK_MODULES(GST_10_11, gstreamer-0.10 >= 0.10.11, + POST_10_11=1, POST_10_11=0) + AC_DEFINE_UNQUOTED(POST_10_11, $POST_10_11, + [GStreamer version is >= 0.10.11]) + + PKG_CHECK_MODULES(GST_10_12, gstreamer-0.10 >= 0.10.12, + POST_10_12=1, POST_10_12=0) + AC_DEFINE_UNQUOTED(POST_10_12, $POST_10_12, + [GStreamer version is >= 0.10.12]) + + PKG_CHECK_MODULES(GST_10_13, gstreamer-0.10 >= 0.10.13, + POST_10_13=1, POST_10_13=0) + AC_DEFINE_UNQUOTED(POST_10_13, $POST_10_13, + [GStreamer version is >= 0.10.13]) + + PKG_CHECK_MODULES(GST_10_14, gstreamer-0.10 >= 0.10.14, + POST_10_14=1, POST_10_14=0) + AC_DEFINE_UNQUOTED(POST_10_14, $POST_10_14, + [GStreamer version is >= 0.10.14]) + + PKG_CHECK_MODULES(GST_10_21, gstreamer-0.10 >= 0.10.21, + POST_10_21=1, POST_10_21=0) + AC_DEFINE_UNQUOTED(POST_10_21, $POST_10_21, + [GStreamer version is >= 0.10.21]) + + PKG_CHECK_MODULES(GST_10_25, gstreamer-0.10 >= 0.10.25, + POST_10_25=1, POST_10_25=0) + AC_DEFINE_UNQUOTED(POST_10_25, $POST_10_25, + [GStreamer version is >= 0.10.25]) + + PKG_CHECK_MODULES(GST_10_26, gstreamer-0.10 >= 0.10.26, + POST_10_26=1, POST_10_26=0) + AC_DEFINE_UNQUOTED(POST_10_26, $POST_10_26, + [GStreamer version is >= 0.10.26]) + else + PKG_CHECK_MODULES(GST_1_0, gstreamer-1.0 >= 1.0, + POST_1_0_0=1, POST_1_0_0=0) + AC_DEFINE_UNQUOTED(POST_1_0, $POST_1_0, + [GStreamer version is >= 1.0.0]) + fi +]) + +AC_DEFUN([AG_GST_CHECK_GST_BASE], +[ + AG_GST_CHECK_MODULES(GST_BASE, gstreamer-base-[$1], [$2], + [GStreamer Base Libraries], [$3]) +]) + +AC_DEFUN([AG_GST_CHECK_GST_GDP], +[ + AG_GST_CHECK_MODULES(GST_GDP, gstreamer-dataprotocol-[$1], [$2], + [GStreamer Data Protocol Library], [$3]) +]) + +AC_DEFUN([AG_GST_CHECK_GST_CONTROLLER], +[ + AG_GST_CHECK_MODULES(GST_CONTROLLER, gstreamer-controller-[$1], [$2], + [GStreamer Controller Library], [$3]) +]) + +AC_DEFUN([AG_GST_CHECK_GST_AUDIO], +[ + AG_GST_CHECK_MODULES(GST_AUDIO, gstreamer-audio-[$1], [$2], + [GStreamer Audio Library], no) + dnl package config files are only available since 0.10.16 + if test "x$HAVE_GST_AUDIO" = "xno"; then + GST_AUDIO_CFLAGS="" + GST_AUDIO_LIBS="-lgstaudio-$GST_MAJORMINOR" + AC_SUBST(GST_AUDIO_CFLAGS) + AC_SUBST(GST_AUDIO_LIBS) + fi +]) + +AC_DEFUN([AG_GST_CHECK_GST_VIDEO], +[ + AG_GST_CHECK_MODULES(GST_VIDEO, gstreamer-video-[$1], [$2], + [GStreamer Video Library], no) + dnl package config files are only available since 0.10.16 + if test "x$HAVE_GST_VIDEO" = "xno"; then + GST_VIDEO_CFLAGS="" + GST_VIDEO_LIBS="-lgstvideo-$GST_MAJORMINOR" + AC_SUBST(GST_VIDEO_CFLAGS) + AC_SUBST(GST_VIDEO_LIBS) + fi +]) + +AC_DEFUN([AG_GST_CHECK_GST_CHECK], +[ + AG_GST_CHECK_MODULES(GST_CHECK, gstreamer-check-[$1], [$2], + [GStreamer Check unittest Library], [$3]) +]) + +AC_DEFUN([AG_GST_CHECK_GST_PLUGINS_BASE], +[ + AG_GST_CHECK_MODULES(GST_PLUGINS_BASE, gstreamer-plugins-base-[$1], [$2], + [GStreamer Base Plug-ins Library], [$3]) + + dnl check for where base plug-ins got installed + dnl this is used for unit tests + dnl allow setting before calling this macro to override + if test -z $GSTPB_PLUGINS_DIR; then + GSTPB_PLUGINS_DIR=`$PKG_CONFIG --variable=pluginsdir gstreamer-plugins-base-[$1]` + if test -z $GSTPB_PLUGINS_DIR; then + GSTPB_PLUGINS_DIR=${libdir}/gstreamer-${GST_MAJORMINOR} + fi + fi + AC_MSG_NOTICE([using GStreamer Base Plug-ins in $GSTPB_PLUGINS_DIR]) + AC_SUBST(GSTPB_PLUGINS_DIR) +]) diff --git a/common/m4/gst-cpu-tune.m4 b/common/m4/gst-cpu-tune.m4 new file mode 100644 index 0000000..2c5d0e7 --- /dev/null +++ b/common/m4/gst-cpu-tune.m4 @@ -0,0 +1,317 @@ +dnl This macros is intended to define platform specific tuned CFLAGS/CCASFLAGS +AC_DEFUN([AG_GST_CPU_TUNE], +[ + CPU_TUNE_CFLAGS="" + CPU_TUNE_CCASFLAGS="" + CPU_TUNE_LDFLAGS="" + + dnl tune build for Atom + AC_ARG_ENABLE(cpu-tune-atom, + AC_HELP_STRING([--enable-cpu-tune-atom], + [enable CFLAGS/CCASFLAGS tuned for Intel Atom]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + AC_MSG_NOTICE(Build will be tuned for Intel Atom) + AS_COMPILER_FLAG(-O3, + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -O3") + AS_COMPILER_FLAG(-march=atom, [march_atom=yes], [march_atom=no]) + if test "x$march_atom" = xyes; then + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -march=atom" + else + AS_COMPILER_FLAG(-msse3, + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -msse3") + AS_COMPILER_FLAG(-march=nocona, + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -march=nocona") + fi + AS_COMPILER_FLAG(-mfpmath=sse, + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -mfpmath=sse") + fi + + dnl tune build for Nokia N800 + AC_ARG_ENABLE(cpu-tune-n800, + AC_HELP_STRING([--enable-cpu-tune-n800], + [enable CFLAGS/CCASFLAGS tuned for Nokia N800]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AC_MSG_NOTICE(Build will be tuned for Nokia N800) + AS_COMPILER_FLAG(-march=armv6j, + NEW_FLAGS="$NEW_FLAGS -march=armv6j") + AS_COMPILER_FLAG(-mtune=arm1136j-s, + NEW_FLAGS="$NEW_FLAGS -mtune=arm1136j-s") + dnl Some assembly code requires -fomit-frame-pointer + AS_COMPILER_FLAG(-fomit-frame-pointer, + NEW_FLAGS="$NEW_FLAGS -fomit-frame-pointer") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARMV6_SIMD, TRUE, [Build with ARM v6 optimizations]) + fi + + dnl tune build for Raspberry PI + AC_ARG_ENABLE(cpu-tune-rpi, + AC_HELP_STRING([--enable-cpu-tune-rpi], + [enable CFLAGS/CCASFLAGS tuned for Raspberry PI]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AC_MSG_NOTICE(Build will be tuned for Raspberry PI) + AS_COMPILER_FLAG(-march=armv6j, + NEW_FLAGS="$NEW_FLAGS -march=armv6j") + AS_COMPILER_FLAG(-mtune=arm1176jzf-s, + NEW_FLAGS="$NEW_FLAGS -mtune=arm1176jzf-s") + + dnl Some assembly code requires -fomit-frame-pointer + AS_COMPILER_FLAG(-fomit-frame-pointer, + NEW_FLAGS="$NEW_FLAGS -fomit-frame-pointer") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARMV6_SIMD, TRUE, [Build with ARM v6 optimizations]) + fi + + dnl tune build for Marvell Dove + AC_ARG_ENABLE(cpu-tune-dove, + AC_HELP_STRING([--enable-cpu-tune-dove], + [enable CFLAGS/CCASFLAGS tuned for Marvell Dove]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AC_MSG_NOTICE(Build will be tuned for Marvell Dove) + + AS_COMPILER_FLAG(-march=armv7-a, + NEW_FLAGS="$NEW_FLAGS -march=armv7-a") + + AS_COMPILER_FLAG(-mtune=marvell-pj4, [mtune_pj4=yes], [mtune_pj4=no]) + if test "x$mtune_pj4" = xyes; then + dnl FIXME: we should use -mcpu=marvell-pj4 too instead of -march + dnl but doesn't work in Ubuntu gcc 4.8 from ppa:ubuntu-toolchain-r + NEW_FLAGS="$NEW_FLAGS -mtune=marvell-pj4" + else + AS_COMPILER_FLAG(-mtune=cortex-a9, + NEW_FLAGS="$NEW_FLAGS -mtune=cortex-a9") + fi + + AS_COMPILER_FLAG(-mthumb, + NEW_FLAGS="$NEW_FLAGS -mthumb") + AS_COMPILER_FLAG(-mfloat-abi=softfp, + NEW_FLAGS="$NEW_FLAGS -mfloat-abi=softfp") + AS_COMPILER_FLAG(-mfpu=vfpv3-d16, + NEW_FLAGS="$NEW_FLAGS -mfpu=vfpv3-d16") + dnl Some assembly code requires -fomit-frame-pointer + AS_COMPILER_FLAG(-fomit-frame-pointer, + NEW_FLAGS="$NEW_FLAGS -fomit-frame-pointer") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARMV6_SIMD, TRUE, [Build with ARM v6 optimizations]) + fi + + dnl Build the ARM v6 code + AC_ARG_ENABLE(armv6-code, + AC_HELP_STRING([--enable-armv6-code], + [enable conditional code for armv6]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + AC_MSG_NOTICE(Build with ARM v6 assembly optimized code) + AC_DEFINE(USE_ARMV6_SIMD, TRUE, [Build with ARM v6 optimizations]) + fi + + dnl tune build for ARM Cortex A8 cpus + AC_ARG_ENABLE(cpu-tune-cortex-a8, + AC_HELP_STRING([--enable-cpu-tune-cortex-a8], + [enable CFLAGS/CCASFLAGS tuned for ARM Cortex A8]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AC_MSG_NOTICE(Build will be tuned for ARM Cortex A8) + AS_COMPILER_FLAG(-mcpu=cortex-a8, [mcpu_a8=yes], [mcpu_a8=no]) + if test "x$mcpu_a8" = xyes; then + NEW_FLAGS="$NEW_FLAGS -mcpu=cortex-a8" + else + AS_COMPILER_FLAG(-march=armv7-a, + NEW_FLAGS="$NEW_FLAGS -march=armv7-a") + AS_COMPILER_FLAG(-mtune=cortex-a8, + NEW_FLAGS="$NEW_FLAGS -mtune=cortex-a8") + fi + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + fi + + dnl tune build for ARM Cortex A9 cpus + AC_ARG_ENABLE(cpu-tune-cortex-a9, + AC_HELP_STRING([--enable-cpu-tune-cortex-a9], + [enable CFLAGS/CCASFLAGS tuned for ARM Cortex A9]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AC_MSG_NOTICE(Build will be tuned for ARM Cortex A9) + AS_COMPILER_FLAG(-mcpu=cortex-a9, [mcpu_a9=yes], [mcpu_a9=no]) + if test "x$mcpu_a9" = xyes; then + NEW_FLAGS="$NEW_FLAGS -mcpu=cortex-a9" + else + AS_COMPILER_FLAG(-march=armv7-a, + NEW_FLAGS="$NEW_FLAGS -march=armv7-a") + AS_COMPILER_FLAG(-mtune=cortex-a9, + NEW_FLAGS="$NEW_FLAGS -mtune=cortex-a9") + fi + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + fi + + dnl tune build using vfp+softfp + AC_ARG_ENABLE(cpu-tune-vfp, + AC_HELP_STRING([--enable-cpu-tune-vfp], + [enable build of ARM vfp optimizations]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AS_COMPILER_FLAG(-marm, + NEW_FLAGS="$NEW_FLAGS -marm") + AS_COMPILER_FLAG(-mfloat-abi=softfp, + NEW_FLAGS="$NEW_FLAGS -mfloat-abi=softfp") + AS_COMPILER_FLAG(-mfpu=vfp, + NEW_FLAGS="$NEW_FLAGS -mfpu=vfp") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARM_VFP, TRUE, [Build with ARM vfp optimizations]) + fi + AM_CONDITIONAL(USE_ARM_VFP, test "x$TUNE" = "xyes") + + dnl tune build using vfp+hardfp + AC_ARG_ENABLE(cpu-tune-vfp-hf, + AC_HELP_STRING([--enable-cpu-tune-vfp-hf], + [enable build of ARM vfp optimizations]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AS_COMPILER_FLAG(-marm, + NEW_FLAGS="$NEW_FLAGS -marm") + AS_COMPILER_FLAG(-mfloat-abi=hard, + NEW_FLAGS="$NEW_FLAGS -mfloat-abi=hard") + AS_COMPILER_FLAG(-mfpu=vfp, + NEW_FLAGS="$NEW_FLAGS -mfpu=vfp") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARM_VFP, TRUE, [Build with ARM vfp optimizations]) + fi + AM_CONDITIONAL(USE_ARM_VFP, test "x$TUNE" = "xyes") + + dnl tune build using neon+softfp + AC_ARG_ENABLE(cpu-tune-neon, + AC_HELP_STRING([--enable-cpu-tune-neon], + [enable build of with ARM neon optimizations]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AS_COMPILER_FLAG(-marm, + NEW_FLAGS="$NEW_FLAGS -marm") + AS_COMPILER_FLAG(-mfloat-abi=softfp, + NEW_FLAGS="$NEW_FLAGS -mfloat-abi=softfp") + AS_COMPILER_FLAG(-mfpu=neon, + NEW_FLAGS="$NEW_FLAGS -mfpu=neon") + AS_COMPILER_FLAG(-ffast-math, + NEW_FLAGS="$NEW_FLAGS -ffast-math") + AS_COMPILER_FLAG(-fsingle-precision-constant, + NEW_FLAGS="$NEW_FLAGS -fsingle-precision-constant") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARM_NEON, TRUE, [Build with ARM neon optimizations]) + fi + + dnl tune build using neon+hardfp + AC_ARG_ENABLE(cpu-tune-neon-hf, + AC_HELP_STRING([--enable-cpu-tune-neon-hf], + [enable build of with ARM neon optimizations]), + [TUNE=yes], + [TUNE=no]) dnl Default value + + if test "x$TUNE" = xyes; then + NEW_FLAGS="" + AS_COMPILER_FLAG(-marm, + NEW_FLAGS="$NEW_FLAGS -marm") + AS_COMPILER_FLAG(-mfloat-abi=hard, + NEW_FLAGS="$NEW_FLAGS -mfloat-abi=hard") + AS_COMPILER_FLAG(-mfpu=neon, + NEW_FLAGS="$NEW_FLAGS -mfpu=neon") + AS_COMPILER_FLAG(-ffast-math, + NEW_FLAGS="$NEW_FLAGS -ffast-math") + AS_COMPILER_FLAG(-fsingle-precision-constant, + NEW_FLAGS="$NEW_FLAGS -fsingle-precision-constant") + + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS $NEW_FLAGS" + CPU_TUNE_CCASFLAGS="$CPU_TUNE_CCASFLAGS $NEW_FLAGS" + AC_DEFINE(USE_ARM_NEON, TRUE, [Build with ARM neon optimizations]) + fi + + AM_CONDITIONAL(USE_ARM_NEON, test "x$TUNE" = "xyes") + + dnl tune build on Solaris with Sun Forte CC + AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) + if test "x$SUNCC" == "xyes"; then + AS_COMPILER_FLAG([-xO5], + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -xO5") + AS_COMPILER_FLAG([-xspace], + CPU_TUNE_CFLAGS="$CPU_TUNE_CFLAGS -xspace") + fi + + dnl No execstack depends on the platform + case "$host" in + *darwin*) + ;; + *mingw*) + ;; + *-sun-* | *pc-solaris* ) + AC_CHECK_FILE([/usr/lib/ld/map.noexstk], + [CPU_TUNE_LDFLAGS="${CPU_TUNE_LDFLAGS} -Wl,-M/usr/lib/ld/map.noexstk -static-libgcc"]) + ;; + *) + dnl FIXME: this is a test for compiler flags but we are testing a linker flag + AS_COMPILER_FLAG([-Wl,-znoexecstack], + [CPU_TUNE_LDFLAGS="$CPU_TUNE_LDFLAGS -Wl,-znoexecstack"]) + ;; + esac + + dnl libtool requires -no-udefined to build a DLL in windows + case "$host" in + *mingw*) + CPU_TUNE_LDFLAGS="$CPU_TUNE_LDFLAGS -no-undefined" + ;; + esac + + AC_SUBST(CPU_TUNE_CFLAGS) + AC_SUBST(CPU_TUNE_CCASFLAGS) + AC_SUBST(CPU_TUNE_LDFLAGS) + + if test "x$CPU_TUNE_CFLAGS" != "x"; then + AC_MSG_NOTICE(CPU_TUNE_CFLAGS : $CPU_TUNE_CFLAGS) + AC_MSG_NOTICE(CPU_TUNE_CCASFLAGS: $CPU_TUNE_CCASFLAGS) + AC_MSG_NOTICE(CPU_TUNE_LDFLAGS : $CPU_TUNE_LDFLAGS) + fi +]) + diff --git a/common/m4/gst-demo-plugin.m4 b/common/m4/gst-demo-plugin.m4 new file mode 100644 index 0000000..f13c0a9 --- /dev/null +++ b/common/m4/gst-demo-plugin.m4 @@ -0,0 +1,32 @@ +dnl Options to build a demo codec + +AC_DEFUN([AG_GST_ARG_DEMO_PLUGIN], +[ + AC_ARG_ENABLE(demo-plugin, + AC_HELP_STRING([--enable-demo-plugin], + [Build a demo plugin, the decoding or encoding will be limited]), + [DEMO_PLUGIN=yes], + [DEMO_PLUGIN=no]) + + AC_ARG_ENABLE(demo-percent, + AC_HELP_STRING([--enable-demo-percent[=number] Specify the percentage + of the video that can be played]), + [ if test $enableval -lt 0 -o $enableval -gt 100 ; then + DEMO_PERCENT=10 + else + DEMO_PERCENT=$enableval + fi + ], + [DEMO_PERCENT=10]) + + if test "x$DEMO_PLUGIN" = xyes; then + ENABLE_DEMO_PLUGIN=1 + else + ENABLE_DEMO_PLUGIN=0 + fi + AC_DEFINE_UNQUOTED(ENABLE_DEMO_PLUGIN, ${ENABLE_DEMO_PLUGIN}, [Demo plugin support]) + AC_DEFINE_UNQUOTED(DEMO_PERCENT, ${DEMO_PERCENT}, [Demo plugin percentage]) + AC_SUBST(ENABLE_DEMO_PLUGIN) + AC_SUBST(DEMO_PERCENT) +]) + diff --git a/common/m4/gst-error.m4 b/common/m4/gst-error.m4 new file mode 100644 index 0000000..8011fbe --- /dev/null +++ b/common/m4/gst-error.m4 @@ -0,0 +1,81 @@ +dnl handle various error-related things + +dnl Thomas Vander Stichele <thomas@apestaart.org> + +dnl Last modification: 2005-10-16 + +dnl AG_GST_SET_ERROR_CFLAGS([ADD-WERROR]) +dnl AG_GST_SET_LEVEL_DEFAULT([IS-CVS-VERSION]) + + +dnl Sets ERROR_CFLAGS to something the compiler will accept. +dnl AC_SUBST them so they are available in Makefile + +dnl -Wall is added if it is supported +dnl -Werror is added if ADD-WERROR is not "no" + +dnl These flags can be overridden at make time: +dnl make ERROR_CFLAGS= +AC_DEFUN([AG_GST_SET_ERROR_CFLAGS], +[ + AC_REQUIRE([AC_PROG_CC]) + AC_REQUIRE([AS_COMPILER_FLAG]) + + + dnl if we support -Wall, set it unconditionally + AS_COMPILER_FLAG(-Wall, + ERROR_CFLAGS="-Wall", + ERROR_CFLAGS="") + + dnl if asked for, add -Werror if supported + if test "x$1" != "xno" + then + AS_COMPILER_FLAG(-Werror, ERROR_CFLAGS="$ERROR_CFLAGS -Werror") + + dnl if -Werror isn't suported + if test "x$ERROR_CFLAGS" == "x" + then + dnl try -errwarn=%all,no%E_EMPTY_DECLARATION,no%E_STATEMENT_NOT_REACHED (Sun Forte case) + dnl For Forte we need disable "empty declaration" warning produced by un-needed semicolon + dnl "statement not reached" disabled because there is g_assert_not_reached () in some places + AS_COMPILER_FLAG([-errwarn=%all,no%E_EMPTY_DECLARATION,no%E_STATEMENT_NOT_REACHED], + [ERROR_CFLAGS="-errwarn=%all,no%E_EMPTY_DECLARATION,no%E_STATEMENT_NOT_REACHED"]) + + dnl We are disallowing the new use of extern and inline used together, so that + dnl the compiler doesn't freak out on Solaris. + AS_COMPILER_FLAG([-features=no%extinl], + [ERROR_CFLAGS="$ERROR_CFLAGS -features=no%extinl"]) + + dnl if this also isn't suported, try only for -errwarn=%all + if test "x$ERROR_CFLAGS" == "x" + then + AS_COMPILER_FLAG(-errwarn=%all, + ERROR_CFLAGS="-errwarn=%all") + fi + else + dnl Due the glib threading API changes there's a lot of deprecation warnings on stuff like + dnl GST_PAD_STREAM_LOCK and some other owned mutex/cond/thread stuff. + dnl We can just disable the deprecation checks to make build in new glib less traumatic. + ERROR_CFLAGS="$ERROR_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS" + fi + fi + + AC_SUBST(ERROR_CFLAGS) + AC_MSG_NOTICE([set ERROR_CFLAGS to $ERROR_CFLAGS]) +]) + +dnl Sets the default error level for debugging messages +AC_DEFUN([AG_GST_SET_LEVEL_DEFAULT], +[ + dnl define correct errorlevel for debugging messages. We want to have + dnl GST_ERROR messages printed when running cvs builds + if test "x[$1]" = "xyes"; then + GST_LEVEL_DEFAULT=GST_LEVEL_ERROR + else + GST_LEVEL_DEFAULT=GST_LEVEL_NONE + fi + AC_DEFINE_UNQUOTED(GST_LEVEL_DEFAULT, $GST_LEVEL_DEFAULT, + [Default errorlevel to use]) + dnl AC_SUBST so we can use it for win32/common/config.h + AC_SUBST(GST_LEVEL_DEFAULT) +]) diff --git a/common/m4/gst-fionread.m4 b/common/m4/gst-fionread.m4 new file mode 100644 index 0000000..603aa45 --- /dev/null +++ b/common/m4/gst-fionread.m4 @@ -0,0 +1,42 @@ +AC_DEFUN([GST_CHECK_FIONREAD], [ + + AC_MSG_CHECKING(for FIONREAD in sys/ioctl.h) + AC_CACHE_VAL(_cv_gst_fionread_in_sys_ioctl, [ + AC_TRY_COMPILE([ +#include <sys/types.h> +#include <sys/ioctl.h> +], [ +int x = FIONREAD; +if ( x ) + return 0; + ], _cv_gst_fionread_in_sys_ioctl="yes",_cv_gst_fionread_in_sys_ioctl="no") + ]) + + AC_MSG_RESULT($_cv_gst_fionread_in_sys_ioctl) + + if test "$_cv_gst_fionread_in_sys_ioctl" = "yes"; then + AC_DEFINE([HAVE_FIONREAD_IN_SYS_IOCTL], 1, [FIONREAD ioctl found in sys/ioclt.h]) + + else + + AC_MSG_CHECKING(for FIONREAD in sys/filio.h) + AC_CACHE_VAL(_cv_gst_fionread_in_sys_filio, [ + AC_TRY_COMPILE([ + #include <sys/types.h> + #include <sys/filio.h> + ], [ + int x = FIONREAD; + if ( x ) + return 0; + ], _cv_gst_fionread_in_sys_filio="yes",_cv_gst_fionread_in_sys_filio="no") + ]) + + AC_MSG_RESULT($_cv_gst_fionread_in_sys_filio) + + if test "$_cv_gst_fionread_in_sys_filio" = "yes"; then + AC_DEFINE([HAVE_FIONREAD_IN_SYS_FILIO], 1, [FIONREAD ioctl found in sys/filio.h]) + fi + + fi + +]) diff --git a/common/m4/gst-gettext.m4 b/common/m4/gst-gettext.m4 new file mode 100644 index 0000000..a63651b --- /dev/null +++ b/common/m4/gst-gettext.m4 @@ -0,0 +1,21 @@ +dnl gettext setup + +dnl AG_GST_GETTEXT([gettext-package]) +dnl defines GETTEXT_PACKAGE and LOCALEDIR + +AC_DEFUN([AG_GST_GETTEXT], +[ + if test "$USE_NLS" = "yes"; then + GETTEXT_PACKAGE=[$1] + else + GETTEXT_PACKAGE=[NULL] + fi + AC_SUBST(GETTEXT_PACKAGE) + AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], "$GETTEXT_PACKAGE", + [gettext package name]) + + dnl define LOCALEDIR in config.h + AS_AC_EXPAND(LOCALEDIR, $datadir/locale) + AC_DEFINE_UNQUOTED([LOCALEDIR], "$LOCALEDIR", + [gettext locale dir]) +]) diff --git a/common/m4/gst-plugindir.m4 b/common/m4/gst-plugindir.m4 new file mode 100644 index 0000000..09989d0 --- /dev/null +++ b/common/m4/gst-plugindir.m4 @@ -0,0 +1,17 @@ +dnl AG_GST_SET_PLUGINDIR + +dnl AC_DEFINE PLUGINDIR to the full location where plug-ins will be installed +dnl AC_SUBST plugindir, to be used in Makefile.am's + +AC_DEFUN([AG_GST_SET_PLUGINDIR], +[ + dnl define location of plugin directory + AS_AC_EXPAND(PLUGINDIR, ${libdir}/gstreamer-$GST_MAJORMINOR) + AC_DEFINE_UNQUOTED(PLUGINDIR, "$PLUGINDIR", + [directory where plugins are located]) + AC_MSG_NOTICE([Using $PLUGINDIR as the plugin install location]) + + dnl plugin directory configure-time variable for use in Makefile.am + plugindir="\$(libdir)/gstreamer-$GST_MAJORMINOR" + AC_SUBST(plugindir) +]) diff --git a/common/m4/gst-static-plugin.m4 b/common/m4/gst-static-plugin.m4 new file mode 100644 index 0000000..3b1acff --- /dev/null +++ b/common/m4/gst-static-plugin.m4 @@ -0,0 +1,27 @@ +dnl Disable pic build and + +AC_DEFUN([AG_GST_ARG_STATIC_PLUGIN], +[ + dnl build static plugins or not + AC_MSG_CHECKING([whether to build static plugins or not]) + AC_ARG_ENABLE( + static-plugin, + AC_HELP_STRING( + [--enable-static-plugin], + [build static plugin @<:@default=no@:>@]),, + [enable_static_plugin=no]) + AC_MSG_RESULT([$enable_static_plugin]) + if test "x$enable_static_plugin" = xyes; then + AC_ENABLE_STATIC(yes) dnl --enable-static + AC_LIBTOOL_PICMODE(default) dnl --without-pic + AC_DEFINE(GST_PLUGIN_BUILD_STATIC, 1, + [Define if static plugins should be built]) + fi + AM_CONDITIONAL(GST_PLUGIN_BUILD_STATIC, test "x$enable_static_plugin" = "xyes") +]) + +AC_DEFUN([AG_GST_ARG_STATIC_PLUGINS], +[ + dnl to avoid break in some revisions + AG_GST_ARG_STATIC_PLUGIN +]) diff --git a/common/m4/gst-valgrind.m4 b/common/m4/gst-valgrind.m4 new file mode 100644 index 0000000..93c2635 --- /dev/null +++ b/common/m4/gst-valgrind.m4 @@ -0,0 +1,35 @@ +AC_DEFUN([AG_GST_VALGRIND_CHECK], +[ + dnl valgrind inclusion + AC_ARG_ENABLE(valgrind, + AC_HELP_STRING([--disable-valgrind], [disable run-time valgrind detection]), + [ + case "${enableval}" in + yes) USE_VALGRIND="$USE_DEBUG" ;; + no) USE_VALGRIND=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --enable-valgrind) ;; + esac], + [ + USE_VALGRIND="$USE_DEBUG" + ]) dnl Default value + + VALGRIND_REQ="2.1" + if test "x$USE_VALGRIND" = xyes; then + PKG_CHECK_MODULES(VALGRIND, valgrind > $VALGRIND_REQ, + USE_VALGRIND="yes", + [ + USE_VALGRIND="no" + AC_MSG_RESULT([no]) + ]) + fi + + if test "x$USE_VALGRIND" = xyes; then + AC_DEFINE(HAVE_VALGRIND, 1, [Define if valgrind should be used]) + AC_MSG_NOTICE(Using extra code paths for valgrind) + fi + AC_SUBST(VALGRIND_CFLAGS) + AC_SUBST(VALGRIND_LIBS) + + AC_PATH_PROG(VALGRIND_PATH, valgrind, no) + AM_CONDITIONAL(HAVE_VALGRIND, test ! "x$VALGRIND_PATH" = "xno") +]) diff --git a/common/m4/gst.m4 b/common/m4/gst.m4 new file mode 100644 index 0000000..04b466f --- /dev/null +++ b/common/m4/gst.m4 @@ -0,0 +1,10 @@ +dnl AG_GST_INIT +dnl sets up use of GStreamer configure.ac macros +dnl all GStreamer autoconf macros are prefixed +dnl with AG_GST_ for public macros +dnl with _AG_GST_ for private macros + +AC_DEFUN([AG_GST_INIT], +[ + m4_pattern_forbid(^_?AG_GST_) +]) diff --git a/common/m4/ipp.m4 b/common/m4/ipp.m4 new file mode 100644 index 0000000..c1e24c5 --- /dev/null +++ b/common/m4/ipp.m4 @@ -0,0 +1,251 @@ +dnl Detection of Intel Integrated Performance Primitives IPP +dnl Usage: AG_CHEC_IPP([FUNCTION LIST PATH],[CPU_FAMILY]) +dnl FUNCTION LIST PATH is an optional argument +dnl CPU_FAMILY is an optional argument to select an specific library variant +AC_DEFUN([AG_CHECK_IPP], +[ + BUILD_IN_MACOS=false + BUILD_IN_UNIX=false + BUILD_IN_WINDOWS=false + BUILD_IPP_MERGED=false + case "$host_os" in + *darwin*) + BUILD_IN_MACOS=true + ;; + mingw*) + BUILD_IN_WINDOWS=true + ;; + linux* | solaris*) + BUILD_IN_UNIX=true + BUILD_IPP_MERGED=true + ;; + esac + AM_CONDITIONAL(BUILD_IN_MACOS, test "x$BUILD_IN_MACOS" = "xtrue") + AM_CONDITIONAL(BUILD_IN_UNIX, test "x$BUILD_IN_UNIX" = "xtrue") + AM_CONDITIONAL(BUILD_IN_WINDOWS, test "x$BUILD_IN_WINDOWS" = "xtrue") + + dnl Setup for finding IPP libraries. Attempt to detect by default. + CHECK_FOR_IPP=true + AC_MSG_CHECKING([for Intel Performance Primitives library]) + + AC_ARG_WITH(ipp, + AC_HELP_STRING([--with-ipp], + [Turn on/off use of Intel Programming Primitives (default=yes)]), + [if test "x$withval" = "xno"; then CHECK_FOR_IPP=false; fi]) + + AC_ARG_WITH(ipp-path, + AC_HELP_STRING([--with-ipp-path], + [manually set location of IPP files]), + [USE_IPP_PATH="${withval}"]) + + AC_ARG_WITH(ipp-arch, + AC_HELP_STRING([--with-ipp-arch], + [to include only one ipp implementation/architecture, valid values are: 0=all,1=px,2=a6,3=w7,4=t7,5=v8,6=p8,7=mx,8=m7,9=u8,10=y8,11=s8(lp32)]), + [IPP_ARCH="${withval}"], + [IPP_ARCH="0"]) + + AC_DEFINE_UNQUOTED(USE_SINGLE_IPP_ARCH, $IPP_ARCH, [Specify one IPP implementation]) + + if test -n "$USE_IPP_PATH"; then + IPP_PREFIX="$USE_IPP_PATH" + if test -f "$IPP_PREFIX/include/ipp.h"; then + HAVE_IPP=true + CHECK_FOR_IPP=false + else + IPP_AVAIL="." + fi + else + if test "x$BUILD_IN_MACOS" = "xtrue"; then + IPP_PREFIX="/Developer/opt/intel/ipp/" + fi + if test "x$BUILD_IN_WINDOWS" = "xtrue"; then + IPP_PREFIX="/c/Intel/IPP" + fi + if test "x$BUILD_IN_UNIX" = "xtrue"; then + IPP_PREFIX="/opt/intel/ipp" + fi + dnl Assumes that the latest directory created is the one with the correct + dnl version to use. + IPP_AVAIL="`ls -vrd $IPP_PREFIX/* | sed 's|.*/||' 2>/dev/null`" + HAVE_IPP=false + fi + + dnl IPP is only valid for x86 based archs + if test -z $2 ; then + IPP_CPU_FAMILY="${host_cpu}" + else + IPP_CPU_FAMILY=$2 + fi + + case "x${IPP_CPU_FAMILY}" in + xi?86) + if test "x$IPP_ARCH" = "x11" ; then + IPP_CPU="lp32" + IPP_SUFFIX="" + else + IPP_CPU="ia32" + IPP_SUFFIX="" + fi + ;; + xi?86_64 | xx86_64) + IPP_CPU="em64t" + IPP_SUFFIX="em64t" + ;; + *) + CHECK_FOR_IPP=false + HAVE_IPP=false + ;; + esac + + dnl For OSX there is no suffix nor cpu + if test "x$BUILD_IN_MACOS" = "xtrue" ; then + IPP_SUFFIX="" + IPP_CPU="" + fi + + if test "x$CHECK_FOR_IPP" = "xtrue"; then + HAVE_IPP=false + # Loop over IPP versions + for ver in $IPP_AVAIL; do + if test -f "${IPP_PREFIX}/${ver}/${IPP_CPU}/include/ipp.h"; then + IPP_PREFIX="${IPP_PREFIX}/${ver}/${IPP_CPU}" + HAVE_IPP=true + break + fi + done + fi + + AM_CONDITIONAL(USE_IPP, test "x$HAVE_IPP" = "xtrue") + + if test "x$HAVE_IPP" = "xtrue"; then + AC_DEFINE(USE_IPP, TRUE, [Define whether IPP is available]) + if test -z $1; then + IPP_FUNC_PATH="src" + else + IPP_FUNC_PATH=$1 + fi + AC_SUBST(IPP_FUNC_PATH) + + IPP_PATH="${IPP_PREFIX}" + IPP_INCLUDES="-I${IPP_PATH}/include" + + if test "x$BUILD_IPP_MERGED" = "xtrue" ; then + AC_DEFINE(USE_IPP_MERGED, TRUE, [Define whether USE_IPP_MERGED could be used]) + fi + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + + dnl define missing __int64 type used in the ipp headers + if test "x$BUILD_IN_WINDOWS" = "xtrue"; then + AC_CHECK_TYPE([__int64],, + [AC_DEFINE_UNQUOTED([__int64], [long long], + [Define to `long long' if <sys/types.h> does not define.])]) + fi + dnl ippmerged needs to know wheter to link or not when building a static or dynamic library + AM_CONDITIONAL(BUILD_STATIC, test "x$enable_static" = "xyes" -a "x$enable_shared" = "xno") + +]) + +dnl Given a list of ipp libraries to link with, set the needed variables for building +dnl Usage: AG_NEED_IPP([IPP LIBS], [FUNCTION LIST PATH], [CPU_FAMILY]) +dnl FUNCTION LIST PATH is an optional argument +dnl CPU_FAMILY is an optional argument to select an specific library variant +AC_DEFUN([AG_NEED_IPP], +[ + HAVE_IPP=false + AG_CHECK_IPP($2,$3) + if test "x$BUILD_IN_WINDOWS" = "xtrue" ; then + AR_EXT=.lib + AR_PRE= + else + AR_EXT=.a + AR_PRE=lib + fi + if test "$HAVE_IPP" = "false"; then + AC_MSG_WARN([Intel Performance Primitives not found in $IPP_PREFIX]) + else + NEED_LIST=$1 + IPP_TRAMPOLINE_LIST="" + IPP_LIST="" + if test "x$BUILD_IN_MACOS" = "xtrue" ; then + IPP_LIST+=${NEED_LIST} + IPP_SUFFIX+="_l" + else + for lib in ${NEED_LIST}; do + IPP_LIST+="${lib}merged " + IPP_TRAMPOLINE_LIST+="${lib}emerged " + done + fi + + + if test "x$BUILD_IN_WINDOWS" = "xtrue" ; then + IPP_CORE="ippcorel" + else + IPP_CORE="ippcore" + fi + + dnl put ippcore at the end, when linking the symbols are not resolved recursively + IPP_LIST+=" ${IPP_CORE}" + IPP_TRAMPOLINE_LIST+=" ${IPP_CORE}" + + IPP_LIBS="" + IPP_ARCHIVES="" + IPP_LIBDIR="${IPP_PREFIX}/lib" + + if test "x$THREAD_SAFE" = "xyes"; then + IPP_SUFFIX+="_t" + fi + + for lib in ${IPP_LIST}; do + ARCHIVE="${AR_PRE}${lib}${IPP_SUFFIX}${AR_EXT}" + IPP_LIBS+=" -l${lib}${IPP_SUFFIX}" + IPP_ARCHIVES+=" ${ARCHIVE}" + done + for lib in ${IPP_TRAMPOLINE_LIST}; do + ARCHIVE="${AR_PRE}${lib}${IPP_SUFFIX}${AR_EXT}" + IPP_TRAMPOLINE_LIBS+=" -l${lib}${IPP_SUFFIX}" + if test "x$BUILD_IN_WINDOWS" = "xtrue" ; then + IPP_LIBS=" -l${lib}${IPP_SUFFIX} ${IPP_LIBS}" + IPP_ARCHIVES+=" ${ARCHIVE}" + fi + done + + if test "x$THREAD_SAFE" = "xyes"; then + IPP_LIBS+=" -lirc -liomp5" + fi + + IPP_LIBS=" -L${IPP_LIBDIR} $IPP_LIBS " + fi + + dnl IPP libs are compiled with the buffer security check leading to + dnl an unresolved symbol __security_check_cookie, which is provided + dnl by bufferoverflowU.lib. This library can be found in the Windows + dnl Driver Kit. Nevertheless we add msvcrt first to make sure we don't + dnl start pulling tons of symbols provided by msvcrt from ntdll which could + dnl seriously break our build like sscanf. + if test "x$BUILD_IN_WINDOWS" = "xtrue" ; then + IPP_LIBS+=" -lbufferoverflowU -lmsvcrt -lntdll" + fi + + AC_SUBST(IPP_PATH) dnl source directory + AC_SUBST(IPP_INCLUDES) dnl cflags + AC_SUBST(IPP_LIBS) dnl ldflags + AC_SUBST(IPP_TRAMPOLINE_LIBS) dnl ldflags + AC_SUBST(IPP_ARCHIVES) dnl to iterate + AM_CONDITIONAL(USE_IPP, test "x$HAVE_IPP" = "xtrue") + + dnl Permit patching IPP library to avoid reallocation problems + ipp_patch_realloc=false + AC_ARG_WITH(ipp-patch-realloc, + AC_HELP_STRING([--with-ipp-patch-realloc], + [Turn on/off patching of IPP for reallocatable code (default=no)]), + [if test "x$withval" = "xyes"; then ipp_patch_realloc=true; fi]) + dnl Disable patching on 64 bits + if test "x$HAVE_CPU_X86_64" = "xyes" ; then + ipp_patch_realloc=false + fi + AM_CONDITIONAL(IPP_PATCH_REALLOC, ${ipp_patch_realloc}) +]) + diff --git a/common/m4/libtool.mk b/common/m4/libtool.mk new file mode 100644 index 0000000..162d894 --- /dev/null +++ b/common/m4/libtool.mk @@ -0,0 +1,245 @@ +# Libtool isn't very helpful when it comes to link partially a set of static +# libraries. This utility helps to create a link command where all the gstreamer +# libraries and gstreamer plugins are statically linked while the other dependencies +# are linked dynamically. It takes as input a list of gstreamer plugins +# in the form of -lgstfoo and returns the output to be used in the link +# command + +# ----------------------------------------------------------------------------- +# Function : libtool-link +# Arguments: 1: list of GStreamer plugins to link +# 2: list of Libraries +# 3: search path for gstreamer static plugins +# 4: Set to 1 to link GStreamer libs static +# Returns : a link command with all the dependencies resolved as done by libtool +# Usage : $(call libtool-link,<lib>) +# ----------------------------------------------------------------------------- +define libtool-link + $(call libtool-clear-vars)\ + $(if $(findstring 1, $4),\ + $(call __libtool_log, Linking with static gstreamer $4)\ + $(eval __libtool.static_gst_lib := "yes"),\ + $(call __libtool_log, Linking with dynamic gstreamer $4)\ + )\ + $(eval __libtool.gst_plugins := $(patsubst %,gst%, $1))\ + $(eval __libtool.link.command := $(patsubst %,-lgst%, $1) $2 -L$3)\ + $(call __libtool_log, original link command = $(__libtool.link.command))\ + $(eval __libtool.link.Lpath := $(call libtool-get-search-paths,$(__libtool.link.command)))\ + $(call __libtool_log, Library Search Paths = $(__libtool.link.Lpath))\ + $(eval __libtool.link.libs := $(call libtool-get-libs,$(__libtool.link.command)))\ + $(call __libtool_log, Libraries = $(__libtool.link.libs))\ + $(foreach library,$(__libtool.link.libs),$(call libtool-parse-lib,$(library)))\ + $(call libtool-gen-link-command) +endef + + +############################################################################### +# # +# These functions are private, don't use them directly # +# # +############################################################################### + +# ----------------------------------------------------------------------------- +# Function : libtool-parse-library +# Arguments: 1: library name +# Returns : "" +# Usage : $(call libtool-parse-library,<libname>) +# Note : Tries to find a libtool library for this name in the libraries search +# path and parses it as well as its dependencies +# ----------------------------------------------------------------------------- +define libtool-parse-lib + $(eval __tmpvar := $(strip $(call libtool-find-lib,$(patsubst -l%,%,$1))))\ + $(if $(__tmpvar), \ + $(call libtool-parse-file,$(__tmpvar),$(strip $(call libtool-name-from-filepath,$(__tmpvar)))),\ + $(call __libtool_log, libtool file not found for "$1" and will be added to the shared libs)\ + $(if $(findstring __-l, __$1),\ + $(eval __libtool.link.shared_libs += $1),\ + $(eval __libtool.link.shared_libs += -l$1)\ + )\ + ) +endef + +# ----------------------------------------------------------------------------- +# Function : libtool-parse-file +# Arguments: 1: libtool file +# 2: library name +# Returns : "" +# Usage : $(call libtool-parse-file,<file>,<libname>) +# Note : +# Parses a libtool library and its dependencies recursively +# +# For each library it sets the following variables: +# __libtool_libs.libname.LIBS -> non-libtool libraries linked with -lfoo +# __libtool_libs.libname.STATIC_LIB -> link statically this library +# __libtool_libs.libname.DYN_LIB -> link dynamically this library +# __libtool_libs.libname.LIBS_SEARCH_PATH -> libraries search path +# +# Processed libraries are stored in __libtool_libs.processed, and +# the list of libraries ordered by dependencies are stored in +# __libtool_lbs.ordered +# ----------------------------------------------------------------------------- +define libtool-parse-file + $(call __libtool_log, parsing file $1)\ + $(if $(strip $(call libtool-lib-processed,$2)),\ + $(call __libtool_log, library "$2" already parsed),\ + $(eval __libtool_libs.$2.STATIC_LIB := $(patsubst %.la,%.a,$1))\ + $(eval __libtool_libs.$2.DYN_LIB := -l$2)\ + $(eval __libtool_libs.$2.FLAGS := $(call libtool-get-inherited-linker-flags,$1))\ + $(eval __tmpvar.$2.dep_libs := $(call libtool-get-dependency-libs,$1))\ + $(eval __tmpvar.$2.dep_libs := $(call libtool-replace-prefixes,$(__tmpvar.$2.dep_libs)))\ + $(eval __libtool_libs.$2.LIBS := $(call libtool-get-libs,$(__tmpvar.$2.dep_libs)))\ + $(call __libtool_log, $2.libs = $(__libtool_libs.$2.LIBS))\ + $(eval __libtool_libs.$2.LIBS_SEARCH_PATH := $(call libtool-get-search-paths,$(__tmpvar.$2.dep_libs)))\ + $(call __libtool_log, $2.libs_seach_path = $(__libtool_libs.$2.LIBS_SEARCH_PATH))\ + $(eval __tmpvar.$2.file_deps := $(call libtool-get-libtool-deps,$(__tmpvar.$2.dep_libs)))\ + $(eval __libtool_libs.$2.DEPS := $(foreach path,$(__tmpvar.$2.file_deps), $(call libtool-name-from-filepath,$(path))))\ + $(call __libtool_log, $2.deps = $(__libtool_libs.$2.DEPS)) \ + $(eval __libtool_libs.processed += $2) \ + $(call __libtool_log, parsed libraries: $(__libtool_libs.processed))\ + $(foreach library,$(__libtool_libs.$2.DEPS), $(call libtool-parse-lib,$(library)))\ + $(eval __libtool_libs.ordered += $2)\ + $(call __libtool_log, ordered list of libraries: $(__libtool_libs.ordered))\ + ) +endef + +define __libtool_log + $(if $(strip $(LIBTOOL_DEBUG)),\ + $(call __libtool_info,$1),\ + ) +endef + +define __libtool_info + $(info LIBTOOL: $1) +endef + +define libtool-clear-vars + $(foreach lib,$(__libtool_libs.processed),\ + $(eval __libtool_libs.$(lib).LIBS := $(empty))\ + $(eval __libtool_libs.$(lib).STATIC_LIB := $(empty))\ + $(eval __libtool_libs.$(lib).DYN_LIB := $(empty))\ + $(eval __libtool_libs.$(lib).LIBS_SEARCH_PATH := $(empty))\ + )\ + $(eval __libtool_libs.ordered := $(empty))\ + $(eval __libtool_libs.processed := $(empty))\ + $(eval __libtool.link.Lpath := $(empty))\ + $(eval __libtool.link.command := $(empty))\ + $(eval __libtool.link.libs := $(empty))\ + $(eval __libtool.link.shared_libs := $(empty)) +endef + +define libtool-lib-processed + $(findstring ___$1___, $(foreach lib,$(__libtool_libs.processed), ___$(lib)___)) +endef + +define libtool-gen-link-command + $(eval __tmpvar.cmd := $(filter-out -L%,$(__libtool.link.command)))\ + $(eval __tmpvar.cmd := $(filter-out -l%,$(__tmpvar.cmd)))\ + $(eval __tmpvar.cmd += $(__libtool.link.Lpath))\ + $(eval __tmpvar.cmd += $(call libtool-get-libs-search-paths))\ + $(eval __tmpvar.cmd += $(call libtool-get-all-libs))\ + $(eval __tmpvar.cmd += $(__libtool.link.shared_libs))\ + $(eval __tmpvar.cmd += $(call libtool-get-flags))\ + $(call __libtool_log, "Link Command:" $(__tmpvar.cmd))\ + $(__tmpvar.cmd) +endef + +define libtool-get-libs-search-paths + $(eval __tmpvar.paths := $(empty))\ + $(foreach library,$(__libtool_libs.ordered),\ + $(foreach path,$(__libtool_libs.$(library).LIBS_SEARCH_PATH),\ + $(if $(findstring $(path), $(__tmpvar.paths)), ,\ + $(eval __tmpvar.paths += $(subst =,, $(path)))\ + )\ + )\ + )\ + $(call __libtool_log, search paths $(__tmpvar.paths))\ + $(strip $(__tmpvar.paths)) +endef + +define libtool-get-flags + $(eval __tmpvar.flags := $(empty))\ + $(foreach library,$(__libtool_libs.ordered),\ + $(foreach flag,$(__libtool_libs.$(library).FLAGS),\ + $(if $(findstring $(flag), $(__tmpvar.flags)), ,\ + $(eval __tmpvar.flags += $(subst =,, $(flag)))\ + )\ + )\ + )\ + $(call __libtool_log, flags $(__tmpvar.flags))\ + $(strip $(__tmpvar.flags)) +endef + +define libtool-get-all-libs + $(eval __tmpvar.static_libs_reverse := $(empty))\ + $(eval __tmpvar.static_libs := $(empty))\ + $(eval __tmpvar.libs := $(empty))\ + $(foreach library,$(__libtool_libs.ordered),\ + $(if $(findstring gst, $(library)),\ + $(call __libtool_log, Found GStreamer library $(library))\ + $(if $(__libtool.static_gst_lib),\ + $(call __libtool_log, Linking lib as static)\ + $(eval __tmpvar.static_libs_reverse += $(__libtool_libs.$(library).STATIC_LIB)),\ + $(if $(findstring $(library), $(__libtool.gst_plugins)),\ + $(call __libtoo Adding plugin to satic)\ + $(eval __tmpvar.static_libs_reverse += $(__libtool_libs.$(library).STATIC_LIB)),\ + $(call __libtoo Adding library to dynamic)\ + $(eval __tmpvar.libs += -l$(library)))),\ + $(call __libtoo Adding library to dynamic)\ + $(eval __tmpvar.libs += -l$(library))\ + )\ + $(foreach dylib,$(__libtool_libs.$(library).LIBS),\ + $(if $(findstring $(dylib), $(__tmpvar.libs)), ,\ + $(eval __tmpvar.libs += $(dylib))\ + )\ + )\ + )\ + $(foreach path,$(__tmpvar.static_libs_reverse),\ + $(call __libtool_log, static libs $(__tmpvar.static_libs))\ + $(eval __tmpvar.static_libs := $(path) $(__tmpvar.static_libs))\ + )\ + $(strip $(__tmpvar.static_libs) $(__tmpvar.libs)) +endef + +define libtool-find-lib + $(eval __tmpvar := $(empty))\ + $(foreach path,$(__libtool.link.Lpath),\ + $(eval __tmpvar += $(wildcard $(patsubst -L%,%,$(path))/lib$1.la))\ + ) \ + $(firstword $(__tmpvar)) +endef + +define libtool-name-from-filepath + $(patsubst lib%.la,%,$(notdir $1)) +endef + +define libtool-get-libtool-deps + $(filter %.la,$1) +endef + +define libtool-get-deps + $(filter %.la,$1) +endef + +define libtool-get-libs + $(filter -l%,$1) +endef + +define libtool-get-search-paths + $(filter -L%,$1) +endef + +define libtool-get-dependency-libs + $(shell sed -n "s/^dependency_libs='\(.*\)'/\1/p" $1) +endef + +define libtool-get-inherited-linker-flags + $(shell sed -n "s/^inherited_linker_flags='\(.*\)'/\1/p" $1) +endef + +define libtool-replace-prefixes + $(subst $(BUILD_PREFIX),$(prefix),$1 ) +endef + +define libtool-get-static-library + $(shell sed -n "s/^old_library='\(.*\)'/\1/p" $1) +endef diff --git a/common/m4/platform.m4 b/common/m4/platform.m4 new file mode 100644 index 0000000..57cde1f --- /dev/null +++ b/common/m4/platform.m4 @@ -0,0 +1,45 @@ +dnl Determine the Operating System +dnl sets and defines HAVE_OS_WINDOWS, HAVE_OS_LINUX, HAVE_OS_DARWIN, HAVE_OS_ANDROID + +AC_DEFUN([AG_PLATFORM], +[ +AC_MSG_CHECKING([for the OS type]) +ostype="" +case "x${host_os}" in + *darwin*) + HAVE_IOS="no" + AC_CHECK_HEADER(MobileCoreServices/MobileCoreServices.h, HAVE_IOS="yes", HAVE_IOS="no", [-]) + if test "x$HAVE_IOS" = "xno"; then + AC_DEFINE_UNQUOTED(HAVE_OS_DARWIN, 1, [Indicate we are building for OSX]) + ostype=Darwin + else + AC_DEFINE_UNQUOTED(HAVE_OS_IOS, 1, [Indicate we are building for iOS]) + ostype=iOS + fi + ;; + *linux*) + AC_DEFINE_UNQUOTED(HAVE_OS_LINUX, 1, [Indicate we are building for Linux]) + ostype=Linux + ;; + *cygwin*|*mingw*|*msvc*|*mks*) + AC_DEFINE_UNQUOTED(HAVE_OS_WINDOWS, 1, [Indicate we are building for Windows]) + ostype=Windows + ;; + *android*) + AC_DEFINE_UNQUOTED(HAVE_OS_ANDROID, 1, [Indicate we are building for Android]) + ostype=Android + ;; + *solaris*) + AC_DEFINE_UNQUOTED(HAVE_OS_SOLARIS, 1, [Indicate we are building for Solaris]) + ostype=Solaris + ;; +esac + +AM_CONDITIONAL(HAVE_OS_WINDOWS, test x$ostype = xWindows) +AM_CONDITIONAL(HAVE_OS_DARWIN, test x$ostype = xDarwin) +AM_CONDITIONAL(HAVE_OS_LINUX, test x$ostype = xLinux) +AM_CONDITIONAL(HAVE_OS_ANDROID, test x$ostype = xAndroid) +AM_CONDITIONAL(HAVE_OS_SOLARIS, test x$ostype = xSolaris) +AM_CONDITIONAL(HAVE_OS_IOS, test x$ostype = xiOS) +AC_MSG_RESULT($ostype) +]) diff --git a/common/m4/staticplugins.am b/common/m4/staticplugins.am new file mode 100644 index 0000000..318a345 --- /dev/null +++ b/common/m4/staticplugins.am @@ -0,0 +1,38 @@ +include $(top_srcdir)/common/m4/libtool.mk +# Generate list of plugin links (eg: -lcoreelements -lvideoscale) +GSTREAMER_STATIC_C := gstreamer_static.c + +define fix-plugin-name +$(subst gst$1 ,gst$2 ,$3) +endef + +GSTREAMER_PLUGINS_DECLARE := $(foreach plugin, $(GSTREAMER_STATIC_PLUGINS),\ + GST_PLUGIN_STATIC_DECLARE($(plugin));\n) +GSTREAMER_PLUGINS_REGISTER := $(foreach plugin, $(GSTREAMER_STATIC_PLUGINS),\ + GST_PLUGIN_STATIC_REGISTER($(plugin));\n) + +# Generates a source file that declares and registers all the required plugins +PRINTF=printf +$(GSTREAMER_STATIC_C):Makefile + @$(PRINTF) "#include <gst/gst.h>\n" > $(GSTREAMER_STATIC_C) + @$(PRINTF) "$(GSTREAMER_PLUGINS_DECLARE)\n" >> $(GSTREAMER_STATIC_C) + @$(PRINTF) "void gst_register_static_plugins (void) {\n" >> $(GSTREAMER_STATIC_C) + @$(PRINTF) "$(GSTREAMER_PLUGINS_REGISTER)\n" >> $(GSTREAMER_STATIC_C) + @$(PRINTF) "}\n" >> $(GSTREAMER_STATIC_C) + @sed -i s/playbin/playback/g $(GSTREAMER_STATIC_C) + @sed -i s/rtpmanager/gstrtpmanager/g $(GSTREAMER_STATIC_C) + @sed -i s/souphttpsrc/soup/g $(GSTREAMER_STATIC_C) + @sed -i s/decodebin2/uridecodebin/g $(GSTREAMER_STATIC_C) + @sed -i s/siren/gstsiren/g $(GSTREAMER_STATIC_C) + @sed -i s/pulse/pulseaudio/g $(GSTREAMER_STATIC_C) + @sed -i s/osxvideosink/osxvideo/g $(GSTREAMER_STATIC_C) + @sed -i s/directsoundsink/directsound/g $(GSTREAMER_STATIC_C) + @sed -i s/directdrawsink/directdraw/g $(GSTREAMER_STATIC_C) + @sed -i s/flud3dvideosink/d3dsinkwrapper/g $(GSTREAMER_STATIC_C) + @sed -i s/d3dvideosink/d3dsinkwrapper/g $(GSTREAMER_STATIC_C) + +define list-static-plugins-libs +$(call libtool-link, $(GSTREAMER_STATIC_PLUGINS),$1,$(GSTREAMER_STATIC_PLUGINS_DIR),$2) +endef + +CLEANFILES = $(GSTREAMER_STATIC_C) diff --git a/common/m4/wibu.m4 b/common/m4/wibu.m4 new file mode 100644 index 0000000..b699860 --- /dev/null +++ b/common/m4/wibu.m4 @@ -0,0 +1,104 @@ +dnl AG_WIBU([needs_wupi], [needs_codemeter]) +dnl check for AxProtector and CodeMeter headers and libraries +dnl sets WITH_WIBU, WUPI_LIBS, WUPI_FLAGS, CODEMETER_LIBS, CODEMETER_FLAGS +dnl defines BUILD_WIBU + +AC_DEFUN([AG_WIBU], +[ +# Requires AG_GST_ARCH and AG_PLATFORM +# WIBU CodeMeter (note we need arch to figure out library name...) + +needs_wupi=$1 +needs_codemeter=$2 +build_wibu=no + +AC_ARG_WITH(wibu, + AS_HELP_STRING([--with-wibu], + [use WIBU protection system]), + [with_wibu_val="${withval}"], [with_wibu_val="no"]) + +if [test "x$with_wibu_val" == "xyes"]; then + case "x${ostype}" in + xDarwin) + _WUPI_LIBS="-lwupienginemac -L/Developer/WIBU-SYSTEMS/AxProtector/lib" + _WUPI_CFLAGS='-I/Developer/WIBU-SYSTEMS/AxProtector/include' + _CODEMETER_LIBS="-F/Library/Frameworks -framework WibuCmMacX " + _CODEMETER_CFLAGS='-I/Developer/WIBU-SYSTEMS/CodeMeter/include' + ;; + xLinux) + if test "x$HAVE_CPU_X86_64" = "xyes"; then + _WUPI_LIBS="-lwupienginelin64" + _CODEMETER_LIBS="-lwibucmlin64" + else + _WUPI_LIBS="-lwupienginelin" + _CODEMETER_LIBS="-lwibucmlin" + fi + ;; + xWindows) + if test "x$HAVE_CPU_X86_64" = "xyes"; then + _WUPI_LIBS="-lWupiEngine64" + _CODEMETER_LIBS="-lWibuCm64" + else + _WUPI_LIBS="-lWupiEngine32" + _CODEMETER_LIBS="-lWibuCm32" + fi + ;; + esac + + if [ test "x$needs_wupi" = "xyes" ]; then + save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $_WUPI_CFLAGS" + save_LIBS="$LIBS" + LIBS="$LIBS $_WUPI_LIBS" + + dnl Check for wibuixap.h headers + AC_CHECK_HEADERS(wibuixap.h, [have_wupi_h="yes"], [have_wupi_h="no"]) + dnl Check for WupiGetLastError() + AC_LINK_IFELSE([AC_LANG_PROGRAM([ + #include <wibuixap.h>],[ + WupiGetLastError();])], [have_wupi="yes"],[have_wupi="no"]) + + if [ test "x$have_wupi" = "xno" ]; then + AC_MSG_ERROR([you need to have AxProtector installed ]) + fi + LIBS=$save_LIBS + CPPFLAGS=$save_CPPFLAGS + fi + + if [ test "x$needs_codemeter" = "xyes" ]; then + save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $_CODEMETER_CFLAGS" + save_LIBS="$LIBS" + LIBS="$LIBS $_CODEMETER_LIBS" + dnl Check for CodeMeter.h headers + AC_CHECK_HEADERS(CodeMeter.h, [have_codemeter_h="yes"], [have_codemeter_h="no"]) + + dnl Check for WupiGetLastError() + AC_LINK_IFELSE([AC_LANG_PROGRAM([ + #include <CodeMeter.h>],[ + CmGetLastErrorCode();])], [have_codemeter="yes"],[have_codemeter="no"]) + + if [ test "x$have_codemeter" = "xno" ]; then + AC_MSG_ERROR([you need to have CodeMeter installed ]) + fi + LIBS=$save_LIBS + CPPFLAGS=$save_CPPFLAGS + fi + + build_wibu="yes" + WUPI_LIBS=$_WUPI_LIBS + WUPI_CFLAGS=$_WUPI_CFLAGS + CODEMETER_LIBS=$_CODEMETER_LIBS + CODEMETER_CFLAGS=$_CODEMETER_CFLAGS +fi + +if [test "x$build_wibu" == "xyes" ]; then + AC_DEFINE(BUILD_WIBU, 1, [Build with WIBU CodeMeter support]) +fi +AC_SUBST(WUPI_CFLAGS) +AC_SUBST(WUPI_LIBS) +AC_SUBST(CODEMETER_CFLAGS) +AC_SUBST(CODEMETER_LIBS) +AM_CONDITIONAL(WITH_WIBU, [test "x$build_wibu" = "xyes"]) +]) + diff --git a/common/release.mak b/common/release.mak new file mode 100644 index 0000000..7e2ee50 --- /dev/null +++ b/common/release.mak @@ -0,0 +1,13 @@ +# include this snippet to add a common release: target by using +# include $(top_srcdir)/common/release.mak + +# make bz2 as well +AUTOMAKE_OPTIONS = dist-bzip2 + +release: dist + make $(PACKAGE)-$(VERSION).tar.gz.md5 + make $(PACKAGE)-$(VERSION).tar.bz2.md5 + +# generate md5 sum files +%.md5: % + md5sum $< > $@ |