aboutsummaryrefslogtreecommitdiff
path: root/gst-vocschnipselssink/configure.ac
blob: b4c2c07705c396113a577ff2bb56577a5c6e9d29 (plain)
  1. dnl required version of autoconf
  2. AC_PREREQ([2.53])
  3. dnl TODO: fill in your package name and package version here
  4. AC_INIT([my-plugin-package],[1.0.0])
  5. dnl required versions of gstreamer and plugins-base
  6. GST_REQUIRED=1.0.0
  7. GSTPB_REQUIRED=1.0.0
  8. AC_CONFIG_SRCDIR([src/gstvocschnipselsink.c])
  9. AC_CONFIG_HEADERS([config.h])
  10. dnl required version of automake
  11. AM_INIT_AUTOMAKE([1.10])
  12. dnl enable mainainer mode by default
  13. AM_MAINTAINER_MODE([enable])
  14. dnl check for tools (compiler etc.)
  15. AC_PROG_CC
  16. dnl required version of libtool
  17. LT_PREREQ([2.2.6])
  18. LT_INIT
  19. dnl give error and exit if we don't have pkgconfig
  20. AC_CHECK_PROG(HAVE_PKGCONFIG, pkg-config, [ ], [
  21. AC_MSG_ERROR([You need to have pkg-config installed!])
  22. ])
  23. dnl Check for the required version of GStreamer core (and gst-plugins-base)
  24. dnl This will export GST_CFLAGS and GST_LIBS variables for use in Makefile.am
  25. dnl
  26. dnl If you need libraries from gst-plugins-base here, also add:
  27. dnl for libgstaudio-1.0: gstreamer-audio-1.0 >= $GST_REQUIRED
  28. dnl for libgstvideo-1.0: gstreamer-video-1.0 >= $GST_REQUIRED
  29. dnl for libgsttag-1.0: gstreamer-tag-1.0 >= $GST_REQUIRED
  30. dnl for libgstpbutils-1.0: gstreamer-pbutils-1.0 >= $GST_REQUIRED
  31. dnl for libgstfft-1.0: gstreamer-fft-1.0 >= $GST_REQUIRED
  32. dnl for libgstinterfaces-1.0: gstreamer-interfaces-1.0 >= $GST_REQUIRED
  33. dnl for libgstrtp-1.0: gstreamer-rtp-1.0 >= $GST_REQUIRED
  34. dnl for libgstrtsp-1.0: gstreamer-rtsp-1.0 >= $GST_REQUIRED
  35. dnl etc.
  36. PKG_CHECK_MODULES(GST, [
  37. gstreamer-1.0 >= $GST_REQUIRED
  38. gstreamer-base-1.0 >= $GST_REQUIRED
  39. gstreamer-controller-1.0 >= $GST_REQUIRED
  40. ], [
  41. AC_SUBST(GST_CFLAGS)
  42. AC_SUBST(GST_LIBS)
  43. ], [
  44. AC_MSG_ERROR([
  45. You need to install or upgrade the GStreamer development
  46. packages on your system. On debian-based systems these are
  47. libgstreamer1.0-dev and libgstreamer-plugins-base1.0-dev.
  48. on RPM-based systems gstreamer1.0-devel, libgstreamer1.0-devel
  49. or similar. The minimum version required is $GST_REQUIRED.
  50. ])
  51. ])
  52. dnl check if compiler understands -Wall (if yes, add -Wall to GST_CFLAGS)
  53. AC_MSG_CHECKING([to see if compiler understands -Wall])
  54. save_CFLAGS="$CFLAGS"
  55. CFLAGS="$CFLAGS -Wall"
  56. AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ ], [ ])], [
  57. GST_CFLAGS="$GST_CFLAGS -Wall"
  58. AC_MSG_RESULT([yes])
  59. ], [
  60. AC_MSG_RESULT([no])
  61. ])
  62. dnl set the plugindir where plugins should be installed (for src/Makefile.am)
  63. if test "x${prefix}" = "x$HOME"; then
  64. plugindir="$HOME/.gstreamer-1.0/plugins"
  65. else
  66. plugindir="\$(libdir)/gstreamer-1.0"
  67. fi
  68. AC_SUBST(plugindir)
  69. dnl set proper LDFLAGS for plugins
  70. GST_PLUGIN_LDFLAGS='-module -avoid-version -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).*'
  71. AC_SUBST(GST_PLUGIN_LDFLAGS)
  72. AC_CONFIG_FILES([Makefile src/Makefile])
  73. AC_OUTPUT