gst-plugins-mythtv/configure.ac
author melunko
Wed Apr 11 19:32:57 2007 +0100 (2007-04-11)
branchtrunk
changeset 524 d8d280de1550
parent 312 8587b24643e8
permissions -rw-r--r--
[svn r529] Fixed string conversion error at gmyth_scheduler_get_schedule_list()
leo_sobral@2
     1
#                                               -*- Autoconf -*-
leo_sobral@2
     2
# Process this file with autoconf to produce a configure script.
leo_sobral@2
     3
leo_sobral@2
     4
AC_PREREQ(2.50)
leo_sobral@2
     5
leo_sobral@2
     6
AC_INIT([mythtvsrc],[0.1])
leo_sobral@2
     7
abnerf@13
     8
dnl AC_CONFIG_SRCDIR([src])
leo_sobral@2
     9
AC_CONFIG_HEADER(config.h)
leo_sobral@2
    10
leo_sobral@2
    11
dnl when going to/from release please set the nano (fourth number) right !
leo_sobral@2
    12
dnl releases only do Wall, SVN and prerelease does Werror too
leo_sobral@2
    13
AS_VERSION(mythtvsrc, MYTHTVSRC, 0, 1, 0, 3, MYTHTVSRC_SVN="no", MYTHTVSRC_SVN="yes")
leo_sobral@2
    14
leo_sobral@2
    15
MYTHTVSRC_MAJORMINOR=$MYTHTVSRC_MAJOR_VERSION.$MYTHTVSRC_MINOR_VERSION
leo_sobral@2
    16
leo_sobral@2
    17
AC_SUBST(MYTHTVSRC_MAJORMINOR)
leo_sobral@2
    18
leo_sobral@2
    19
dnl AM_MAINTAINER_MODE provides the option to enable maintainer mode
leo_sobral@2
    20
AM_MAINTAINER_MODE
leo_sobral@2
    21
dnl make aclocal work in maintainer mode
leo_sobral@2
    22
AC_SUBST(ACLOCAL_AMFLAGS, "-I m4")
leo_sobral@2
    23
leo_sobral@2
    24
# Checks for programs.
leo_sobral@2
    25
# check for tools
leo_sobral@2
    26
# Make sure CFLAGS is defined to stop AC_PROC_CC adding -g
leo_sobral@2
    27
CFLAGS="$CFLAGS -Wall"
leo_sobral@2
    28
AC_PROG_CC
leo_sobral@2
    29
AC_PROG_LIBTOOL
leo_sobral@2
    30
# Checks for libraries.
leo_sobral@2
    31
leo_sobral@2
    32
# Checks for header files.
leo_sobral@2
    33
AC_HEADER_STDC
leo_sobral@2
    34
AC_CHECK_HEADERS([fcntl.h stdint.h stdlib.h string.h sys/ioctl.h sys/socket.h unistd.h])
leo_sobral@2
    35
leo_sobral@2
    36
# Checks for typedefs, structures, and compiler characteristics.
leo_sobral@2
    37
AC_C_CONST
leo_sobral@2
    38
AC_TYPE_PID_T
leo_sobral@2
    39
AC_STRUCT_TM
leo_sobral@2
    40
leo_sobral@2
    41
# Checks for library functions.
leo_sobral@2
    42
AC_FUNC_FORK
leo_sobral@2
    43
AC_PROG_GCC_TRADITIONAL
leo_sobral@2
    44
AC_FUNC_MALLOC
leo_sobral@2
    45
AC_FUNC_MKTIME
leo_sobral@2
    46
AC_FUNC_VPRINTF
leo_sobral@2
    47
AC_CHECK_FUNCS([memset socket stime strstr strtoul])
leo_sobral@2
    48
leo_sobral@2
    49
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
leo_sobral@2
    50
leo_sobral@2
    51
# Checks required packages
leo_sobral@2
    52
leo_sobral@2
    53
dnl Test if --disable-debug given
leo_sobral@2
    54
AC_ARG_ENABLE(debug,
leo_sobral@2
    55
	[AC_HELP_STRING([--disable-debug], [disable debugging mode])],
leo_sobral@2
    56
	enable_debug="$enableval",
leo_sobral@2
    57
	enable_debug=yes)
leo_sobral@2
    58
leo_sobral@2
    59
if test "x$enable_debug" = "xyes" ; then
leo_sobral@2
    60
      CFLAGS="$CFLAGS -g"
leo_sobral@2
    61
else
leo_sobral@2
    62
      AC_DEFINE( NDEBUG, 1, [disable debug messages] )
leo_sobral@2
    63
      CFLAGS="$CFLAGS -O2 -DG_DISABLE_CHECKS -DNDEBUG"
leo_sobral@2
    64
fi          
leo_sobral@2
    65
leo_sobral@2
    66
AM_CONDITIONAL( NDEBUG, test "x$enable_debug" = "xyes" )
leo_sobral@2
    67
leo_sobral@2
    68
# Check for pkgconfig
leo_sobral@2
    69
AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no)
leo_sobral@2
    70
# Give error and exit if we don't have pkgconfig
leo_sobral@2
    71
if test "x$HAVE_PKGCONFIG" = "xno"; then
leo_sobral@2
    72
  AC_MSG_ERROR(you need to have pkgconfig installed !)
leo_sobral@2
    73
fi
leo_sobral@2
    74
leo_sobral@2
    75
# Check for Glib2.0
leo_sobral@2
    76
PKG_CHECK_MODULES(GLIB, glib-2.0, HAVE_GLIB=yes,HAVE_GLIB=no)
leo_sobral@2
    77
leo_sobral@2
    78
# Give error and exit if we don't have glib
leo_sobral@2
    79
if test "x$HAVE_GLIB" = "xno"; then
leo_sobral@2
    80
  AC_MSG_ERROR(you need glib-2.0 installed)
leo_sobral@2
    81
fi
leo_sobral@2
    82
leo_sobral@2
    83
# make GLIB_CFLAGS and GLIB_LIBS available
leo_sobral@2
    84
AC_SUBST(GLIB_CFLAGS)
leo_sobral@2
    85
AC_SUBST(GLIB_LIBS)
leo_sobral@2
    86
leo_sobral@2
    87
# Check for GObject2.0
leo_sobral@2
    88
PKG_CHECK_MODULES(GOBJECT,
leo_sobral@2
    89
  gobject-2.0,
leo_sobral@2
    90
  HAVE_GOBJECT=yes, HAVE_GOBJECT=no)
leo_sobral@2
    91
leo_sobral@2
    92
# Give error and exit if we don't have gobject
leo_sobral@2
    93
if test "x$HAVE_GOBJECT" = "xno"; then
leo_sobral@2
    94
  AC_MSG_ERROR(you need gobject-2.0 installed)
leo_sobral@2
    95
fi
leo_sobral@2
    96
leo_sobral@2
    97
# make GOBJECT_CFLAGS and GOBJECT_LIBS available
leo_sobral@2
    98
AC_SUBST(GOBJECT_CFLAGS)
leo_sobral@2
    99
AC_SUBST(GOBJECT_LIBS)
leo_sobral@2
   100
leo_sobral@2
   101
dnl *** MythTV ***
leo_sobral@2
   102
PKG_CHECK_MODULES(GMYTH,
renatofilho@503
   103
  gmyth,
leo_sobral@2
   104
  HAVE_GMYTH=yes, HAVE_GMYTH=no)
leo_sobral@2
   105
leo_sobral@2
   106
# Give error and exit if we don't have gobject
leo_sobral@2
   107
if test "x$HAVE_GMYTH" = "xno"; then
renatofilho@503
   108
  AC_MSG_ERROR(you need gmyth must to be installed)
leo_sobral@2
   109
fi
leo_sobral@2
   110
leo_sobral@2
   111
# make GMYTH_CFLAGS and GMYTH_LIBS available
leo_sobral@2
   112
AC_SUBST(GMYTH_CFLAGS)
leo_sobral@2
   113
AC_SUBST(GMYTH_LIBS)
leo_sobral@2
   114
rosfran@8
   115
# GStreamer version required
leo_sobral@2
   116
GST_REQUIRED=0.10
leo_sobral@2
   117
GST_MAJORMINOR=0.10
rosfran@8
   118
rosfran@8
   119
GST_PLUGINS_DIR=`$PKG_CONFIG gstreamer-plugins-base-$GST_MAJORMINOR --variable pluginsdir`
rosfran@8
   120
AC_SUBST(GST_PLUGINS_DIR)
rosfran@8
   121
AC_MSG_NOTICE(Using GStreamer Base Plugins in $GST_PLUGINS_DIR)
rosfran@8
   122
rosfran@8
   123
dnl this really should only contain flags, not libs - they get added before
rosfran@8
   124
dnl whatevertarget_LIBS and -L flags here affect the rest of the linking
rosfran@9
   125
GST_PLUGIN_LDFLAGS="-module -avoid-version $GST_PLUGINS_DIR"
rosfran@8
   126
AC_SUBST(GST_PLUGIN_LDFLAGS)
rosfran@8
   127
rosfran@8
   128
# check for gstreamer development files
leo_sobral@2
   129
PKG_CHECK_MODULES(GST, \
leo_sobral@2
   130
  gstreamer-$GST_MAJORMINOR >= $GST_REQUIRED,
leo_sobral@2
   131
  HAVE_GST=yes, HAVE_GST=no)
leo_sobral@2
   132
leo_sobral@2
   133
# Give error and exit if we don't have gstreamer
leo_sobral@2
   134
if test "x$HAVE_GST" = "xno"; then
leo_sobral@2
   135
  AC_MSG_ERROR(you need gstreamer development packages installed !)
leo_sobral@2
   136
fi
leo_sobral@2
   137
leo_sobral@2
   138
# make GST_CFLAGS and GST_LIBS available
leo_sobral@2
   139
AC_SUBST(GST_CFLAGS)
leo_sobral@2
   140
AC_SUBST(GST_LIBS)
leo_sobral@2
   141
leo_sobral@2
   142
# check for gstreamer-base plugins (xoverlay interface)
leo_sobral@285
   143
GST_BASE_REQUIRED=0.10
leo_sobral@285
   144
GST_BASE_MAJORMINOR=0.10
leo_sobral@285
   145
PKG_CHECK_MODULES(GST_BASE, \
leo_sobral@285
   146
  gstreamer-base-$GST_BASE_MAJORMINOR >= $GST_BASE_REQUIRED,
leo_sobral@285
   147
  HAVE_GST_BASE=yes, HAVE_GST_BASE=no)
leo_sobral@2
   148
leo_sobral@2
   149
# Give error and exit if we don't have gstreamer base libraries
leo_sobral@285
   150
if test "x$HAVE_GST_BASE" = "xno"; then
leo_sobral@2
   151
  AC_MSG_ERROR(you need gstreamer base development packages installed !)
leo_sobral@2
   152
fi
leo_sobral@2
   153
leo_sobral@285
   154
# make GST_BASE_CFLAGS and GST_BASE_LIBS available
leo_sobral@285
   155
AC_SUBST(GST_BASE_CFLAGS)
leo_sobral@285
   156
AC_SUBST(GST_BASE_LIBS)
leo_sobral@2
   157
leo_sobral@2
   158
# make GST_MAJORMINOR available in Makefile.am
leo_sobral@2
   159
AC_SUBST(GST_MAJORMINOR)
leo_sobral@2
   160
rosfran@312
   161
AC_DEFINE(GST_LICENSE, "LGPL", [License for Distribution])
rosfran@312
   162
rosfran@312
   163
AC_DEFINE(GST_PACKAGE_NAME, "GStreamer", [Gstremar package name])
rosfran@312
   164
rosfran@312
   165
AC_DEFINE(GST_PACKAGE_ORIGIN, "http://gstreamer.net/", [Origin of this package] )
rosfran@312
   166
abnerf@13
   167
AC_CONFIG_FILES([
abnerf@13
   168
Makefile
abnerf@13
   169
src/Makefile
abnerf@13
   170
])
leo_sobral@2
   171
leo_sobral@2
   172
AC_OUTPUT