diff -r a4529d0f8ede -r dda04b6cf0b2 gmyth-stream/gmencoder/configure.ac --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/gmyth-stream/gmencoder/configure.ac Wed Sep 26 19:04:24 2007 +0100 @@ -0,0 +1,93 @@ +# -*- Autoconf -*- +# Process this file with autoconf to produce a configure script. + +AC_PREREQ(2.50) + +AC_INIT([gmemcoder],[0.1]) + +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_HEADER(config.h) + +AS_VERSION(gmemcoder, GMEMCODER, 0, 1, 0, 0, GMEMCODER_SVN="no", GMEMCODER_SVN="yes") +GMEMCODER_MAJORMINOR=$GMEMCODER_VERSION.$GMEMCODER_MINOR_VERSION +AC_SUBST(GMEMCODER_MAJORMINOR) + +dnl AM_MAINTAINER_MODE provides the option to enable maintainer mode +AM_MAINTAINER_MODE +dnl make aclocal work in maintainer mode +AC_SUBST(ACLOCAL_AMFLAGS, "-I m4") + +AM_INIT_AUTOMAKE($PACKAGE, $VERSION) + +# Checks for programs. +# check for tools +# Make sure CFLAGS is defined to stop AC_PROC_CC adding -g +CFLAGS="$CFLAGS -Wall" +AC_PROG_CC +AC_PROG_LIBTOOL + +# Checks for libraries. + +# Checks for header files. +AC_HEADER_STDC + +#Test if --disable-debug given +AC_ARG_ENABLE(debug, + AC_HELP_STRING([--disable-debug], [enable debugging mode])) +if test x"$enable_debug" != xno; then + CFLAGS="$CFLAGS -g -DMYTH_STREAM_USE_DEBUG" +else + CFLAGS="$CFLAGS -O2 -DG_DISABLE_CHECKS" +fi + + +# Checks required packages #################################################### +############################################################################### + +## Check for pkgconfig ######################################################## +############################################################################### +AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no) +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) +if test "x$HAVE_GLIB" = "xno"; then + AC_MSG_ERROR(you need glib-2.0 installed) +fi +AC_SUBST(GLIB_CFLAGS) +AC_SUBST(GLIB_LIBS) + +## Check for GnomeVFS ########################################################## +############################################################################### +PKG_CHECK_MODULES(GVFS, gnome-vfs-2.0, HAVE_GVFS=yes,HAVE_GVFS=no) +if test "x$HAVE_GVFS" = "xno"; then + AC_MSG_ERROR(you need gnome-vfs-2.0 installed) +fi +AC_SUBST(GVFS_CFLAGS) +AC_SUBST(GVFS_LIBS) + + +## Check for gst-base ######################################################### +############################################################################### +PKG_CHECK_MODULES(GST, [gstreamer-base-0.10]) +AC_SUBST(GST_CFLAGS) +AC_SUBST(GST_LIBS) + +AC_SUBST(CFLAGS) +AC_SUBST(LDFLAGS) +AC_SUBST(LIBS) + +AC_OUTPUT([ +Makefile +src/Makefile +]) + +if test "x$enable_debug" != "xno"; then + AC_MSG_NOTICE([Debug: Enabled]) +else + AC_MSG_NOTICE([Debug: Disabled]) +fi +