summaryrefslogtreecommitdiff
path: root/legacy/emotion/m4/gst-element-check.m4
blob: 4f4b3064a5b200aeaeb53a6aa977ebb54c4bbd14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
dnl Perform a check for a GStreamer element using gst-inspect
dnl Thomas Vander Stichele <thomas at apestaart dot org>
dnl Last modification: 25/01/2005

dnl AM_GST_ELEMENT_CHECK(ELEMENT-NAME, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)

AC_DEFUN([AM_GST_ELEMENT_CHECK],
[
  if test "x$GST_INSPECT" = "x"; then
    AC_CHECK_PROGS(GST_INSPECT, gst-inspect gst-inspect-0.10, [])
  fi

  if test "x$GST_INSPECT" != "x"; then
    AC_MSG_CHECKING(GStreamer element $1)
    if $GST_INSPECT $1 > /dev/null 2> /dev/null ; then
      AC_MSG_RESULT(found.)
      $2
    else
      AC_MSG_RESULT(not found.)
      $3
    fi
  fi
])