diff -r 000000000000 -r 77f1bc48e05d gmyth-stream/client/configure.ac --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/gmyth-stream/client/configure.ac Wed Apr 11 19:31:15 2007 +0100 @@ -0,0 +1,79 @@ +# -*- Autoconf -*- +# Process this file with autoconf to produce a configure script. + +AC_PREREQ(2.50) + +AC_INIT([gmyth-stream],[0.1]) + +AC_CONFIG_MACRO_DIR([m4]) +AC_CONFIG_HEADER(config.h) + +AS_VERSION(gmyth-stream, GMYTH_STREAM, 0, 1, 0, 0, GMYTH_STREAM_SVN="no", GMYTH_STREAM_SVN="yes") +GMYTH_STREAM_MAJORMINOR=$GMYTH_STREAM_MAJOR_VERSION.$GMYTH_STREAM_MINOR_VERSION +AC_SUBST(GMYTH_STREAM_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 -DGMYTH_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 gobject-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) + +AC_SUBST(CFLAGS) +AC_SUBST(LDFLAGS) +AC_SUBST(LIBS) + +AC_OUTPUT([ +Makefile +gmyth-stream-client.pc +src/Makefile +test/Makefile +]) + +if test "x$enable_debug" != "xno"; then + AC_MSG_NOTICE([Debug: Enabled]) +else + AC_MSG_NOTICE([Debug: Disabled]) +fi +