diff -r 4aac30345986 -r f5f7abc760aa gst-gmyth/configure.ac --- a/gst-gmyth/configure.ac Tue May 01 16:31:26 2007 +0100 +++ b/gst-gmyth/configure.ac Wed May 30 23:14:38 2007 +0100 @@ -1,174 +1,141 @@ -# -*- Autoconf -*- -# Process this file with autoconf to produce a configure script. +dnl fill in your package name and version here +dnl autoconf configuration files for gst-plugins-dspbin +AC_INIT +AC_CANONICAL_TARGET -AC_PREREQ(2.50) +AC_CONFIG_MACRO_DIR([m4]) +dnl We disable static building for development, for time savings +dnl this goes before AS_LIBTOOL to appease autoconf +dnl *NOTE*: dnl this line before release, so release does static too +AM_DISABLE_STATIC -AC_INIT([mythtvsrc],[0.1]) - -dnl AC_CONFIG_SRCDIR([src]) -AC_CONFIG_HEADER(config.h) +dnl AM_MAINTAINER_MODE only provides the option to configure to enable it +AM_MAINTAINER_MODE dnl when going to/from release please set the nano (fourth number) right ! -dnl releases only do Wall, SVN and prerelease does Werror too -AS_VERSION(mythtvsrc, MYTHTVSRC, 0, 1, 0, 3, MYTHTVSRC_SVN="no", MYTHTVSRC_SVN="yes") +dnl releases only do Wall, cvs and prerelease does Werror too +AS_VERSION(gst-indt-plugins, GST_PLUGINS_VERSION, 0, 10, 0, 1, GST_CVS="no", GST_CVS="yes") -MYTHTVSRC_MAJORMINOR=$MYTHTVSRC_MAJOR_VERSION.$MYTHTVSRC_MINOR_VERSION +AM_INIT_AUTOMAKE($PACKAGE, $VERSION) -AC_SUBST(MYTHTVSRC_MAJORMINOR) +AM_PROG_LIBTOOL -dnl AM_MAINTAINER_MODE provides the option to enable maintainer mode -AM_MAINTAINER_MODE +AM_CONFIG_HEADER(config.h) + dnl make aclocal work in maintainer mode AC_SUBST(ACLOCAL_AMFLAGS, "-I m4") -# Checks for programs. -# check for tools -# Make sure CFLAGS is defined to stop AC_PROC_CC adding -g -CFLAGS="$CFLAGS -Wall" +dnl check for tools AC_PROG_CC -AC_PROG_LIBTOOL -# Checks for libraries. +AC_PROG_CC_STDC +AM_PROG_AS -# Checks for header files. -AC_HEADER_STDC -AC_CHECK_HEADERS([fcntl.h stdint.h stdlib.h string.h sys/ioctl.h sys/socket.h unistd.h]) +dnl decide on error flags +AS_COMPILER_FLAG(-Wall, GST_WALL="yes", GST_WALL="no") -# Checks for typedefs, structures, and compiler characteristics. -AC_C_CONST -AC_TYPE_PID_T -AC_STRUCT_TM +if test "x$GST_WALL" = "xyes"; then + ERROR_CFLAGS="$GST_ERROR -Wall" -# Checks for library functions. -AC_FUNC_FORK -AC_PROG_GCC_TRADITIONAL -AC_FUNC_MALLOC -AC_FUNC_MKTIME -AC_FUNC_VPRINTF -AC_CHECK_FUNCS([memset socket stime strstr strtoul]) + if test "x$GST_CVS" = "xyes"; then + AS_COMPILER_FLAG(-Werror,ERROR_CFLAGS="$ERROR_CFLAGS -Werror",ERROR_CFLAGS="$ERROR_CFLAGS") + fi +fi -AM_INIT_AUTOMAKE($PACKAGE, $VERSION) +AC_SUBST(ERROR_CFLAGS) -# Checks required packages +dnl determine c++ compiler +AC_PROG_CXX +dnl determine if c++ is available on this system +AC_CHECK_PROG(HAVE_CXX, $CXX, yes, no) +dnl determine c++ preprocessor +AC_PROG_CXXCPP +AC_ISC_POSIX -dnl Test if --disable-debug given -AC_ARG_ENABLE(debug, - [AC_HELP_STRING([--disable-debug], [disable debugging mode])], - enable_debug="$enableval", - enable_debug=yes) +AC_HEADER_STDC([]) +AC_C_INLINE -if test "x$enable_debug" = "xyes" ; then - CFLAGS="$CFLAGS -g" -else - AC_DEFINE( NDEBUG, 1, [disable debug messages] ) - CFLAGS="$CFLAGS -O2 -DG_DISABLE_CHECKS -DNDEBUG" -fi +dnl Check for pkgconfig first +AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no) -AM_CONDITIONAL( NDEBUG, test "x$enable_debug" = "xyes" ) - -# Check for pkgconfig -AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no) -# Give error and exit if we don't have pkgconfig +dnl Give error and exit if we don't have pkgconfig if test "x$HAVE_PKGCONFIG" = "xno"; then AC_MSG_ERROR(you need to have pkgconfig installed !) fi -# Check for Glib2.0 -PKG_CHECK_MODULES(GLIB, glib-2.0, HAVE_GLIB=yes,HAVE_GLIB=no) +dnl Now we're ready to ask for gstreamer libs and cflags +dnl And we can also ask for the right version of gstreamer -# Give error and exit if we don't have glib -if test "x$HAVE_GLIB" = "xno"; then - AC_MSG_ERROR(you need glib-2.0 installed) -fi - -# make GLIB_CFLAGS and GLIB_LIBS available -AC_SUBST(GLIB_CFLAGS) -AC_SUBST(GLIB_LIBS) - -# Check for GObject2.0 -PKG_CHECK_MODULES(GOBJECT, - gobject-2.0, - HAVE_GOBJECT=yes, HAVE_GOBJECT=no) - -# Give error and exit if we don't have gobject -if test "x$HAVE_GOBJECT" = "xno"; then - AC_MSG_ERROR(you need gobject-2.0 installed) -fi - -# make GOBJECT_CFLAGS and GOBJECT_LIBS available -AC_SUBST(GOBJECT_CFLAGS) -AC_SUBST(GOBJECT_LIBS) - -dnl *** MythTV *** -PKG_CHECK_MODULES(GMYTH, - gmyth, - HAVE_GMYTH=yes, HAVE_GMYTH=no) - -# Give error and exit if we don't have gobject -if test "x$HAVE_GMYTH" = "xno"; then - AC_MSG_ERROR(you need gmyth must to be installed) -fi - -# make GMYTH_CFLAGS and GMYTH_LIBS available -AC_SUBST(GMYTH_CFLAGS) -AC_SUBST(GMYTH_LIBS) - -# GStreamer version required -GST_REQUIRED=0.10 +GST_REQUIRED=0.10.3 GST_MAJORMINOR=0.10 -GST_PLUGINS_DIR=`$PKG_CONFIG gstreamer-plugins-base-$GST_MAJORMINOR --variable pluginsdir` -AC_SUBST(GST_PLUGINS_DIR) -AC_MSG_NOTICE(Using GStreamer Base Plugins in $GST_PLUGINS_DIR) - -dnl this really should only contain flags, not libs - they get added before -dnl whatevertarget_LIBS and -L flags here affect the rest of the linking -GST_PLUGIN_LDFLAGS="-module -avoid-version $GST_PLUGINS_DIR" -AC_SUBST(GST_PLUGIN_LDFLAGS) - -# check for gstreamer development files PKG_CHECK_MODULES(GST, \ gstreamer-$GST_MAJORMINOR >= $GST_REQUIRED, - HAVE_GST=yes, HAVE_GST=no) + HAVE_GST=yes,HAVE_GST=no) -# Give error and exit if we don't have gstreamer +dnl Give error and exit if we don't have gstreamer if test "x$HAVE_GST" = "xno"; then AC_MSG_ERROR(you need gstreamer development packages installed !) fi -# make GST_CFLAGS and GST_LIBS available +if test "x$USE_DEBUG" = xyes; then + GST_CFLAGS="$GST_CFLAGS -g" +fi + +dnl added because of the i18n headers +GST_CFLAGS="-I\$(top_builddir)/gst-libs $GST_CFLAGS" + +dnl make GST_CFLAGS and GST_LIBS available AC_SUBST(GST_CFLAGS) AC_SUBST(GST_LIBS) -# check for gstreamer-base plugins (xoverlay interface) -GST_BASE_REQUIRED=0.10 -GST_BASE_MAJORMINOR=0.10 -PKG_CHECK_MODULES(GST_BASE, \ - gstreamer-base-$GST_BASE_MAJORMINOR >= $GST_BASE_REQUIRED, - HAVE_GST_BASE=yes, HAVE_GST_BASE=no) +dnl make GST_MAJORMINOR available in Makefile.am +AC_SUBST(GST_MAJORMINOR) -# Give error and exit if we don't have gstreamer base libraries +dnl check for gstreamer-base; uninstalled is selected preferentially +PKG_CHECK_MODULES(GST_BASE, gstreamer-base-$GST_MAJORMINOR >= $GST_REQUIRED, + HAVE_GST_BASE="yes", HAVE_GST_BASE="no") + if test "x$HAVE_GST_BASE" = "xno"; then - AC_MSG_ERROR(you need gstreamer base development packages installed !) + AC_MSG_ERROR(no GStreamer Base Libs found) fi -# make GST_BASE_CFLAGS and GST_BASE_LIBS available +AC_SUBST(GST_BASE_LIBS) AC_SUBST(GST_BASE_CFLAGS) -AC_SUBST(GST_BASE_LIBS) -# make GST_MAJORMINOR available in Makefile.am -AC_SUBST(GST_MAJORMINOR) +dnl check for gstreamer-libs; uinstalled is selected preferentially +PKG_CHECK_MODULES(GST_PLUGINS_BASE, gstreamer-plugins-base-$GST_MAJORMINOR >= $GST_REQUIRED, + HAVE_GST_PLUGINS="yes", HAVE_GST_PLUGINS="no") + +if test "x$HAVE_GST_PLUGINS" = "xno"; then + AC_MSG_ERROR(no GStreamer Plugins Libs found) +fi + +AC_SUBST(GST_PLUGINS_BASE_LIBS) +AC_SUBST(GST_PLUGINS_BASE_CFLAGS) + +PKG_CHECK_MODULES(GMYTH, gmyth >= 0.3, HAVE_GMYTH=yes,HAVE_GMYTH=no) +if test "x$HAVE_GMYTH" = "xno"; then + AC_MSG_ERROR(you need gmyth >= 0.3 installed) +fi +AC_SUBST(GMYTH_CFLAGS) +AC_SUBST(GMYTH_LIBS) + +dnl set the plugindir where plugins should be installed +plugindir="\$(libdir)/gstreamer-$GST_MAJORMINOR" +AC_SUBST(plugindir) + +dnl set proper LDFLAGS for plugins +GST_PLUGIN_LDFLAGS='-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*' +AC_SUBST(GST_PLUGIN_LDFLAGS) AC_DEFINE(GST_LICENSE, "LGPL", [License for Distribution]) +AC_DEFINE(GST_PACKAGE_NAME, "INdT plugins to Gstreamer ", [package name]) +AC_DEFINE(GST_PACKAGE_ORIGIN, "https://svn.sourceforge.net/svnroot/gmyth/gst-gmyth", [Origin of this package] ) -AC_DEFINE(GST_PACKAGE_NAME, "GStreamer", [Gstremar package name]) +AC_OUTPUT( \ + Makefile \ + nuvdemux/Makefile \ + mythsrc/Makefile \ + concatmux/Makefile +) -AC_DEFINE(GST_PACKAGE_ORIGIN, "http://gstreamer.net/", [Origin of this package] ) - -AC_CONFIG_FILES([ -Makefile -mythtvsrc/Makefile -nuvdemux/Makefile -concatmux/Makefile -]) - -AC_OUTPUT