1 dnl required version of autoconf
4 dnl Package Name is gstnxvideodec version 0.1.0
5 AC_INIT(gstnxvideodec,[0.1.0])
7 dnl required versions of gstreamer and plugins-base
11 AC_CONFIG_SRCDIR([src])
12 AC_CONFIG_HEADERS([config.h])
14 dnl required version of automake
15 AM_INIT_AUTOMAKE([1.10 foreign dist-bzip2])
17 dnl enable mainainer mode by default
18 AM_MAINTAINER_MODE([enable])
20 dnl check for tools (compiler etc.)
23 dnl required version of libtool
27 dnl give error and exit if we don't have pkgconfig
28 AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, [ ], [
29 AC_MSG_ERROR([You need to have pkg-config installed!])
33 dnl our libraries and install dirs use GST_API_VERSION in the filename
34 dnl to allow side-by-side installation of different API versions
36 AC_SUBST(GST_API_VERSION)
37 AC_DEFINE_UNQUOTED(GST_API_VERSION, "$GST_API_VERSION",
38 [GStreamer API Version])
40 dnl Check for the required version of GStreamer core (and gst-plugins-base)
41 dnl This will export GST_CFLAGS and GST_LIBS variables for use in Makefile.am
43 dnl If you need libraries from gst-plugins-base here, also add:
44 dnl for libgstaudio-1.0: gstreamer-audio-1.0 >= $GST_REQUIRED
45 dnl for libgstvideo-1.0: gstreamer-video-1.0 >= $GST_REQUIRED
46 dnl for libgsttag-1.0: gstreamer-tag-1.0 >= $GST_REQUIRED
47 dnl for libgstpbutils-1.0: gstreamer-pbutils-1.0 >= $GST_REQUIRED
48 dnl for libgstfft-1.0: gstreamer-fft-1.0 >= $GST_REQUIRED
49 dnl for libgstinterfaces-1.0: gstreamer-interfaces-1.0 >= $GST_REQUIRED
50 dnl for libgstrtp-1.0: gstreamer-rtp-1.0 >= $GST_REQUIRED
51 dnl for libgstrtsp-1.0: gstreamer-rtsp-1.0 >= $GST_REQUIRED
53 PKG_CHECK_MODULES(GST, [
54 gstreamer-1.0 >= $GST_REQUIRED
55 gstreamer-base-1.0 >= $GST_REQUIRED
56 gstreamer-controller-1.0 >= $GST_REQUIRED
57 gstreamer-audio-1.0 >= $GST_REQUIRED
63 You need to install or upgrade the GStreamer development
64 packages on your system. On debian-based systems these are
65 libgstreamer1.0-dev and libgstreamer-plugins-base1.0-dev.
66 on RPM-based systems gstreamer1.0-devel, libgstreamer1.0-devel
67 or similar. The minimum version required is $GST_REQUIRED.
71 PKG_CHECK_MODULES(MM_COMMON, mm-common)
72 AC_SUBST(MM_COMMON_CFLAGS)
74 dnl check if compiler understands -Wall (if yes, add -Wall to GST_CFLAGS)
75 AC_MSG_CHECKING([to see if compiler understands -Wall])
77 CFLAGS="$CFLAGS -Wall"
78 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ ], [ ])], [
79 GST_CFLAGS="$GST_CFLAGS -Wall"
85 dnl set the plugindir where plugins should be installed (for src/Makefile.am)
86 if test "x${prefix}" = "x$HOME"; then
87 plugindir="$HOME/.gstreamer-1.0/plugins"
89 plugindir="\$(libdir)/gstreamer-1.0"
93 dnl set proper LDFLAGS for plugins
94 GST_PLUGIN_LDFLAGS='-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*'
95 AC_SUBST(GST_PLUGIN_LDFLAGS)
97 AC_CONFIG_FILES([Makefile src/Makefile])