gmyth-stream/gmemcoder/configure.ac
author renatofilho
Tue Jul 03 22:45:24 2007 +0100 (2007-07-03)
branchtrunk
changeset 772 47de5c5976bf
parent 600 7da2a5e32fa6
child 786 a4529d0f8ede
permissions -rw-r--r--
[svn r778] more properties type supported
renatofilho@584
     1
#                                               -*- Autoconf -*-
renatofilho@584
     2
# Process this file with autoconf to produce a configure script.
renatofilho@584
     3
renatofilho@584
     4
AC_PREREQ(2.50)
renatofilho@584
     5
renatofilho@584
     6
AC_INIT([gmemcoder],[0.1])
renatofilho@584
     7
renatofilho@584
     8
AC_CONFIG_MACRO_DIR([m4])
renatofilho@584
     9
AC_CONFIG_HEADER(config.h)
renatofilho@584
    10
renatofilho@584
    11
AS_VERSION(gmemcoder, GMEMCODER, 0, 1, 0, 0, GMEMCODER_SVN="no", GMEMCODER_SVN="yes")
renatofilho@584
    12
GMEMCODER_MAJORMINOR=$GMEMCODER_VERSION.$GMEMCODER_MINOR_VERSION
renatofilho@584
    13
AC_SUBST(GMEMCODER_MAJORMINOR)
renatofilho@584
    14
renatofilho@584
    15
dnl AM_MAINTAINER_MODE provides the option to enable maintainer mode
renatofilho@584
    16
AM_MAINTAINER_MODE
renatofilho@584
    17
dnl make aclocal work in maintainer mode
renatofilho@584
    18
AC_SUBST(ACLOCAL_AMFLAGS, "-I m4")
renatofilho@584
    19
renatofilho@584
    20
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
renatofilho@584
    21
renatofilho@584
    22
# Checks for programs.
renatofilho@584
    23
# check for tools
renatofilho@584
    24
# Make sure CFLAGS is defined to stop AC_PROC_CC adding -g
renatofilho@584
    25
CFLAGS="$CFLAGS -Wall"
renatofilho@584
    26
AC_PROG_CC
renatofilho@584
    27
AC_PROG_LIBTOOL
renatofilho@584
    28
renatofilho@584
    29
# Checks for libraries.
renatofilho@584
    30
renatofilho@584
    31
# Checks for header files.
renatofilho@584
    32
AC_HEADER_STDC
renatofilho@584
    33
renatofilho@584
    34
#Test if --disable-debug given
renatofilho@584
    35
AC_ARG_ENABLE(debug,
renatofilho@584
    36
	AC_HELP_STRING([--disable-debug], [enable debugging mode]))
renatofilho@584
    37
if test x"$enable_debug" != xno; then
renatofilho@584
    38
    CFLAGS="$CFLAGS -g -DMYTH_STREAM_USE_DEBUG"
renatofilho@584
    39
else
renatofilho@584
    40
    CFLAGS="$CFLAGS -O2 -DG_DISABLE_CHECKS"
renatofilho@584
    41
fi          
renatofilho@584
    42
renatofilho@584
    43
renatofilho@584
    44
# Checks required packages ####################################################
renatofilho@584
    45
###############################################################################
renatofilho@584
    46
renatofilho@584
    47
## Check for pkgconfig ########################################################
renatofilho@584
    48
###############################################################################
renatofilho@584
    49
AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no)
renatofilho@584
    50
if test "x$HAVE_PKGCONFIG" = "xno"; then
renatofilho@584
    51
  AC_MSG_ERROR(you need to have pkgconfig installed !)
renatofilho@584
    52
fi
renatofilho@584
    53
renatofilho@584
    54
## Check for Glib2.0 ##########################################################
renatofilho@584
    55
###############################################################################
renatofilho@584
    56
PKG_CHECK_MODULES(GLIB, glib-2.0, HAVE_GLIB=yes,HAVE_GLIB=no)
renatofilho@584
    57
if test "x$HAVE_GLIB" = "xno"; then
renatofilho@584
    58
  AC_MSG_ERROR(you need glib-2.0 installed)
renatofilho@584
    59
fi
renatofilho@584
    60
AC_SUBST(GLIB_CFLAGS)
renatofilho@584
    61
AC_SUBST(GLIB_LIBS)
renatofilho@584
    62
renatofilho@584
    63
## Check for gst-base #########################################################
renatofilho@584
    64
###############################################################################
renatofilho@584
    65
PKG_CHECK_MODULES(GST, [gstreamer-base-0.10])
renatofilho@584
    66
AC_SUBST(GST_CFLAGS)
renatofilho@584
    67
AC_SUBST(GST_LIBS)
renatofilho@584
    68
renatofilho@584
    69
AC_SUBST(CFLAGS)
renatofilho@584
    70
AC_SUBST(LDFLAGS)
renatofilho@584
    71
AC_SUBST(LIBS)
renatofilho@584
    72
renatofilho@584
    73
AC_OUTPUT([
renatofilho@584
    74
Makefile
renatofilho@584
    75
src/Makefile
renatofilho@584
    76
])
renatofilho@584
    77
renatofilho@584
    78
if test "x$enable_debug" != "xno"; then
renatofilho@584
    79
    AC_MSG_NOTICE([Debug: Enabled])
renatofilho@584
    80
else
renatofilho@584
    81
    AC_MSG_NOTICE([Debug: Disabled])
renatofilho@584
    82
fi          
renatofilho@584
    83