gstreamer/configure.ac

201 lines
5.4 KiB
Text
Raw Normal View History

AC_INIT(gstreamer-sharp, m4_esyscmd([tr -d '\n' < VERSION]))
2013-06-17 14:23:54 +00:00
AC_CONFIG_SRCDIR([README])
AC_CANONICAL_TARGET
AM_INIT_AUTOMAKE
AM_MAINTAINER_MODE
AC_PROG_INSTALL
AC_PROG_CC
LT_INIT
2013-06-17 14:23:54 +00:00
dnl Package settings
ASSEMBLY_VERSION=`cat VERSION`
2013-06-17 14:23:54 +00:00
ASSEMBLY_COMPANY=""
2017-08-18 15:29:59 +00:00
ASSEMBLY_COPYRIGHT="GStreamerSharp Contributors"
ASSEMBLY_DESCRIPTION="Gst-1.12 bindings for Mono"
ASSEMBLY_NAME="gstreamer-sharp"
2013-06-17 14:23:54 +00:00
ASSEMBLY_NAMESPACE="Gst"
ASSEMBLY_PC="gstreamer-sharp-1.0"
ASSEMBLY_SHORTNAME="gstreamer"
2013-06-17 14:23:54 +00:00
ASSEMBLY_TITLE="Gst#"
AC_SUBST([ACLOCAL_AMFLAGS], ["-I m4 \${ACLOCAL_FLAGS}"])
AC_SUBST(ASSEMBLY_NAME)
AC_SUBST(ASSEMBLY_VERSION)
AC_SUBST(ASSEMBLY_NAMESPACE)
AC_SUBST(ASSEMBLY_SHORTNAME)
AC_SUBST(ASSEMBLY_TITLE)
AC_SUBST(ASSEMBLY_DESCRIPTION)
AC_SUBST(ASSEMBLY_COMPANY)
AC_SUBST(ASSEMBLY_COPYRIGHT)
AC_SUBST(ASSEMBLY_PC)
dnl Check for pkg-config
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
if test "x$PKG_CONFIG" = "xno"; then
AC_MSG_ERROR(['pkg-config' is not in your PATH.])
fi
dnl Check for Mono
PKG_CHECK_MODULES(MONO_DEPENDENCY, mono >= 1.0, has_mono=true, has_mono=false)
if test "x$has_mono" = "xtrue"; then
AC_PATH_PROG(RUNTIME, mono, no)
AC_PATH_PROG(CSC, mcs, no)
2013-06-17 14:23:54 +00:00
LIB_PREFIX=.so
LIB_SUFFIX=
else
AC_PATH_PROG(CSC, csc.exe, no)
if test x$CSC = "xno"; then
AC_MSG_ERROR([You need to install either mono or .Net])
else
RUNTIME=
LIB_PREFIX=
LIB_SUFFIX=.dylib
fi
fi
CS="C#"
if test "x$CSC" = "xno" ; then
AC_MSG_ERROR([No $CS compiler found])
fi
AC_PATH_PROG(GACUTIL, gacutil, no)
if test "x$GACUTIL" = "xno" ; then
AC_MSG_ERROR([No gacutil tool found])
fi
GACUTIL_FLAGS="/package $ASSEMBLY_NAME /root "'$(DESTDIR)$(prefix)/lib'
AC_SUBST(RUNTIME)
AC_SUBST(CSC)
AC_SUBST(GACUTIL)
AC_SUBST(GACUTIL_FLAGS)
AC_SUBST(LIB_PREFIX)
AC_SUBST(LIB_SUFFIX)
2017-08-24 14:47:52 +00:00
GTK_SHARP_VERSION=3.22.6
2014-07-20 01:52:58 +00:00
dnl Check for glib-sharp
2014-08-01 13:07:22 +00:00
PKG_CHECK_MODULES(GLIB_SHARP, glib-sharp-3.0 >= $GTK_SHARP_VERSION)
AC_SUBST(GLIB_SHARP_CFLAGS)
AC_SUBST(GLIB_SHARP_LIBS)
2013-06-17 14:23:54 +00:00
gtksharp_prefix=`pkg-config --variable=prefix gtk-sharp-3.0`
2014-03-19 14:46:38 +00:00
gapidir=`pkg-config --variable=gapidir gtk-sharp-3.0`
2013-06-17 14:23:54 +00:00
AC_SUBST(gtksharp_prefix)
2014-03-19 14:46:38 +00:00
AC_SUBST(gapidir)
2013-06-17 14:23:54 +00:00
2014-07-20 01:52:58 +00:00
dnl Check for gio-sharp
2014-08-01 13:07:22 +00:00
PKG_CHECK_MODULES(GIO_SHARP, gio-sharp-3.0 >= $GTK_SHARP_VERSION)
2014-07-20 01:52:58 +00:00
AC_SUBST(GIO_SHARP_CFLAGS)
AC_SUBST(GIO_SHARP_LIBS)
2014-08-01 13:07:22 +00:00
dnl Check for gtk-sharp
PKG_CHECK_MODULES(GTK_SHARP, gtk-sharp-3.0 >= $GTK_SHARP_VERSION)
AC_SUBST(GTK_SHARP_CFLAGS)
AC_SUBST(GTK_SHARP_LIBS)
dnl Find GAPI
2014-08-01 13:07:22 +00:00
PKG_CHECK_MODULES(GAPI, gapi-3.0 >= $GTK_SHARP_VERSION)
2013-06-17 14:23:54 +00:00
dnl Check for gapi
AC_PATH_PROG(GAPI_PARSER, gapi3-parser, no)
if test "x$GAPI_PARSER" = "xno"; then
AC_MSG_CHECKING(for gapi3-parser.exe)
GAPI_PARSER=`which gapi3-parser.exe 2> /dev/null`
if test "x$GAPI_PARSER" = "xno" ; then
AC_MSG_ERROR(['gapi3_parser'/'gapi3-parser.exe' not found.])
fi
AC_MSG_RESULT($GAPI_PARSER)
GAPI_PARSER="$MONO $GAPI_PARSER"
fi
AC_SUBST(GAPI_PARSER)
AC_PATH_PROG(GAPI_FIXUP, gapi3-fixup, no)
if test "x$GAPI_FIXUP" = "xno"; then
AC_MSG_CHECKING(for gapi3-fixup.exe)
GAPI_FIXUP=`which gapi3-fixup.exe 2> /dev/null`
if test "x$GAPI_FIXUP" = "xno" ; then
AC_MSG_ERROR(['gapi3_fixup'/'gapi3-fixup.exe' not found.])
fi
AC_MSG_RESULT($GAPI_FIXUP)
GAPI_FIXUP="$MONO $GAPI_FIXUP"
fi
AC_SUBST(GAPI_FIXUP)
AC_PATH_PROG(GAPI_CODEGEN, gapi3-codegen, no)
if test "x$GAPI_CODEGEN" = "xno"; then
AC_MSG_CHECKING(for gapi3_codegen.exe)
GAPI_CODEGEN=`which gapi3_codegen.exe 2> /dev/null`
if test "x$GAPI_CODEGEN" = "xno" ; then
AC_MSG_ERROR(['gapi3-codegen'/'gapi3_codegen.exe' not found.])
fi
AC_MSG_RESULT([$GAPI_CODEGEN])
GAPI_CODEGEN="$MONO $GAPI_CODEGEN"
fi
AC_SUBST(GAPI_CODEGEN)
dnl Check for monodoc
AC_PATH_PROG(MDASSEMBLER, mdassembler, no)
AC_PATH_PROG(MONODOCER, monodocer, no)
2014-08-06 23:24:23 +00:00
AC_PATH_PROG(MONODOCS2HTML, monodocs2html, no)
2013-06-17 14:23:54 +00:00
if test "x$MONODOCER" = "xno" -o "x$MDASSEMBLER" = "xno"; then
enable_monodoc=no
doc_sources_dir=
else
enable_monodoc=yes
doc_sources_dir="`pkg-config --variable=sourcesdir monodoc`"
fi
AC_SUBST(MDASSEMBLER)
AC_SUBST(MONODOCER)
2014-08-06 23:24:23 +00:00
AC_SUBST(MONODOCS2HTML)
2013-06-17 14:23:54 +00:00
AM_CONDITIONAL(ENABLE_MONODOC, test "x$enable_monodoc" = "xyes")
2013-06-17 14:23:54 +00:00
dnl Check for Gst
2017-08-18 15:29:59 +00:00
GSTREAMER_REQUIRED_VERSION=1.12.0
PKG_CHECK_MODULES(GST,
gstreamer-1.0 >= $GSTREAMER_REQUIRED_VERSION
2014-08-08 22:38:32 +00:00
gstreamer-app-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-audio-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-base-1.0 >= $GSTREAMER_REQUIRED_VERSION
2014-08-08 22:38:32 +00:00
gstreamer-controller-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-fft-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-net-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-pbutils-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-riff-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-rtp-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-rtsp-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-sdp-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-tag-1.0 >= $GSTREAMER_REQUIRED_VERSION
2014-08-08 22:38:32 +00:00
gstreamer-video-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-plugins-bad-1.0 >= $GSTREAMER_REQUIRED_VERSION
gstreamer-plugins-base-1.0 >= $GSTREAMER_REQUIRED_VERSION
)
2014-08-01 13:07:22 +00:00
gstreamer_prefix=`pkg-config --variable=prefix gtk-sharp-3.0`
AC_SUBST(gstreamer_prefix)
AC_SUBST(GST_LIBS)
AC_SUBST(GST_CFLAGS)
2013-06-17 14:23:54 +00:00
GST_INCLUDEDIR=`pkg-config gstreamer-1.0 --variable=includedir`
AC_SUBST(GST_INCLUDEDIR)
2013-06-17 14:23:54 +00:00
AC_CONFIG_FILES([
Makefile
sources/Makefile
2014-08-01 13:07:22 +00:00
samples/Makefile
2013-06-17 14:23:54 +00:00
sources/AssemblyInfo.cs
gstreamer-sharp-1.0.pc
2013-06-17 14:23:54 +00:00
doc/Makefile
])
AC_OUTPUT
echo ""
echo "Configuration summary"
echo "---------------------"
echo ""
echo " * Installation prefix: $prefix"
echo " * compiler: $CSC"
echo " * Documentation: ($MONODOC)"
echo ""