melunko@917
|
1 |
dnl fill in your package name and version here
|
melunko@917
|
2 |
dnl autoconf configuration files for gst-plugins-dspbin
|
melunko@917
|
3 |
AC_INIT
|
melunko@917
|
4 |
AC_CANONICAL_TARGET
|
melunko@917
|
5 |
|
melunko@917
|
6 |
AC_CONFIG_MACRO_DIR([m4])
|
melunko@917
|
7 |
dnl We disable static building for development, for time savings
|
melunko@917
|
8 |
dnl this goes before AS_LIBTOOL to appease autoconf
|
melunko@917
|
9 |
dnl *NOTE*: dnl this line before release, so release does static too
|
melunko@917
|
10 |
AM_DISABLE_STATIC
|
melunko@917
|
11 |
|
melunko@917
|
12 |
dnl AM_MAINTAINER_MODE only provides the option to configure to enable it
|
melunko@917
|
13 |
AM_MAINTAINER_MODE
|
melunko@917
|
14 |
|
melunko@917
|
15 |
dnl when going to/from release please set the nano (fourth number) right !
|
melunko@917
|
16 |
dnl releases only do Wall, cvs and prerelease does Werror too
|
melunko@917
|
17 |
AS_VERSION(gst-indt-plugins, GST_PLUGINS_VERSION, 0, 10, 0, 1, GST_CVS="no", GST_CVS="yes")
|
melunko@917
|
18 |
|
melunko@917
|
19 |
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
|
melunko@917
|
20 |
|
melunko@917
|
21 |
AM_PROG_LIBTOOL
|
melunko@917
|
22 |
|
melunko@917
|
23 |
AM_CONFIG_HEADER(config.h)
|
melunko@917
|
24 |
|
melunko@917
|
25 |
dnl make aclocal work in maintainer mode
|
melunko@917
|
26 |
AC_SUBST(ACLOCAL_AMFLAGS, "-I m4")
|
melunko@917
|
27 |
|
melunko@917
|
28 |
dnl check for tools
|
melunko@917
|
29 |
AC_PROG_CC
|
melunko@917
|
30 |
AC_PROG_CC_STDC
|
melunko@917
|
31 |
AM_PROG_AS
|
melunko@917
|
32 |
|
melunko@917
|
33 |
dnl decide on error flags
|
melunko@917
|
34 |
AS_COMPILER_FLAG(-Wall, GST_WALL="yes", GST_WALL="no")
|
melunko@917
|
35 |
|
melunko@917
|
36 |
if test "x$GST_WALL" = "xyes"; then
|
melunko@917
|
37 |
ERROR_CFLAGS="$GST_ERROR -Wall"
|
melunko@917
|
38 |
|
melunko@917
|
39 |
if test "x$GST_CVS" = "xyes"; then
|
melunko@917
|
40 |
AS_COMPILER_FLAG(-Werror,ERROR_CFLAGS="$ERROR_CFLAGS -Werror",ERROR_CFLAGS="$ERROR_CFLAGS")
|
melunko@917
|
41 |
fi
|
melunko@917
|
42 |
fi
|
melunko@917
|
43 |
|
melunko@917
|
44 |
AC_SUBST(ERROR_CFLAGS)
|
melunko@917
|
45 |
|
melunko@917
|
46 |
dnl determine c++ compiler
|
melunko@917
|
47 |
AC_PROG_CXX
|
melunko@917
|
48 |
dnl determine if c++ is available on this system
|
melunko@917
|
49 |
AC_CHECK_PROG(HAVE_CXX, $CXX, yes, no)
|
melunko@917
|
50 |
dnl determine c++ preprocessor
|
melunko@917
|
51 |
AC_PROG_CXXCPP
|
melunko@917
|
52 |
AC_ISC_POSIX
|
melunko@917
|
53 |
|
melunko@917
|
54 |
AC_HEADER_STDC([])
|
melunko@917
|
55 |
AC_C_INLINE
|
melunko@917
|
56 |
|
melunko@917
|
57 |
dnl Check for pkgconfig first
|
melunko@917
|
58 |
AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, yes, no)
|
melunko@917
|
59 |
|
melunko@917
|
60 |
dnl Give error and exit if we don't have pkgconfig
|
melunko@917
|
61 |
if test "x$HAVE_PKGCONFIG" = "xno"; then
|
melunko@917
|
62 |
AC_MSG_ERROR(you need to have pkgconfig installed !)
|
melunko@917
|
63 |
fi
|
melunko@917
|
64 |
|
melunko@917
|
65 |
dnl Now we're ready to ask for gstreamer libs and cflags
|
melunko@917
|
66 |
dnl And we can also ask for the right version of gstreamer
|
melunko@917
|
67 |
|
melunko@917
|
68 |
GST_REQUIRED=0.10.14
|
melunko@917
|
69 |
GST_MAJORMINOR=0.10
|
melunko@917
|
70 |
|
melunko@917
|
71 |
PKG_CHECK_MODULES(GST, \
|
melunko@917
|
72 |
gstreamer-$GST_MAJORMINOR >= $GST_REQUIRED,
|
melunko@917
|
73 |
HAVE_GST=yes,HAVE_GST=no)
|
melunko@917
|
74 |
|
melunko@917
|
75 |
dnl Give error and exit if we don't have gstreamer
|
melunko@917
|
76 |
if test "x$HAVE_GST" = "xno"; then
|
melunko@917
|
77 |
AC_MSG_ERROR(you need gstreamer development packages installed !)
|
melunko@917
|
78 |
fi
|
melunko@917
|
79 |
|
melunko@917
|
80 |
if test "x$USE_DEBUG" = xyes; then
|
melunko@917
|
81 |
GST_CFLAGS="$GST_CFLAGS -g"
|
melunko@917
|
82 |
fi
|
melunko@917
|
83 |
|
melunko@917
|
84 |
dnl added because of the i18n headers
|
melunko@917
|
85 |
GST_CFLAGS="-I\$(top_builddir)/gst-libs $GST_CFLAGS"
|
melunko@917
|
86 |
|
melunko@917
|
87 |
dnl make GST_CFLAGS and GST_LIBS available
|
melunko@917
|
88 |
AC_SUBST(GST_CFLAGS)
|
melunko@917
|
89 |
AC_SUBST(GST_LIBS)
|
melunko@917
|
90 |
|
melunko@917
|
91 |
dnl make GST_MAJORMINOR available in Makefile.am
|
melunko@917
|
92 |
AC_SUBST(GST_MAJORMINOR)
|
melunko@917
|
93 |
|
melunko@917
|
94 |
dnl check for gstreamer-base; uninstalled is selected preferentially
|
melunko@917
|
95 |
PKG_CHECK_MODULES(GST_BASE, gstreamer-base-$GST_MAJORMINOR >= $GST_REQUIRED,
|
melunko@917
|
96 |
HAVE_GST_BASE="yes", HAVE_GST_BASE="no")
|
melunko@917
|
97 |
|
melunko@917
|
98 |
if test "x$HAVE_GST_BASE" = "xno"; then
|
melunko@917
|
99 |
AC_MSG_ERROR(no GStreamer Base Libs found)
|
melunko@917
|
100 |
fi
|
melunko@917
|
101 |
|
melunko@917
|
102 |
AC_SUBST(GST_BASE_LIBS)
|
melunko@917
|
103 |
AC_SUBST(GST_BASE_CFLAGS)
|
melunko@917
|
104 |
|
melunko@917
|
105 |
dnl check for gstreamer-libs; uinstalled is selected preferentially
|
melunko@917
|
106 |
PKG_CHECK_MODULES(GST_PLUGINS_BASE, gstreamer-plugins-base-$GST_MAJORMINOR >= $GST_REQUIRED,
|
melunko@917
|
107 |
HAVE_GST_PLUGINS="yes", HAVE_GST_PLUGINS="no")
|
melunko@917
|
108 |
|
melunko@917
|
109 |
if test "x$HAVE_GST_PLUGINS" = "xno"; then
|
melunko@917
|
110 |
AC_MSG_ERROR(no GStreamer Plugins Libs found)
|
melunko@917
|
111 |
fi
|
melunko@917
|
112 |
|
melunko@917
|
113 |
AC_SUBST(GST_PLUGINS_BASE_LIBS)
|
melunko@917
|
114 |
AC_SUBST(GST_PLUGINS_BASE_CFLAGS)
|
melunko@917
|
115 |
|
melunko@917
|
116 |
dnl set the plugindir where plugins should be installed
|
melunko@917
|
117 |
plugindir="\$(libdir)/gstreamer-$GST_MAJORMINOR"
|
melunko@917
|
118 |
AC_SUBST(plugindir)
|
melunko@917
|
119 |
|
melunko@917
|
120 |
dnl set proper LDFLAGS for plugins
|
melunko@917
|
121 |
GST_PLUGIN_LDFLAGS='-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*'
|
melunko@917
|
122 |
AC_SUBST(GST_PLUGIN_LDFLAGS)
|
melunko@917
|
123 |
|
melunko@917
|
124 |
AC_DEFINE(GST_LICENSE, "LGPL", [License for Distribution])
|
melunko@917
|
125 |
AC_DEFINE(GST_PACKAGE_NAME, "INdT plugins to Gstreamer ", [package name])
|
melunko@917
|
126 |
AC_DEFINE(GST_PACKAGE_ORIGIN, "https://svn.sourceforge.net/svnroot/gmyth/gst-gpac", [Origin of this package] )
|
melunko@917
|
127 |
|
melunko@917
|
128 |
AC_OUTPUT( \
|
melunko@917
|
129 |
Makefile \
|
melunko@917
|
130 |
src/Makefile
|
melunko@917
|
131 |
)
|
melunko@917
|
132 |
|