File: listcomponents-bellagio

package info (click to toggle)
libomxalsa 0.1-3
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye
  • size: 1,536 kB
  • sloc: sh: 10,177; ansic: 2,136; makefile: 27
file content (38 lines) | stat: -rwxr-xr-x 955 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/bin/sh

set -e

DEB_BUILD_MULTIARCH=`dpkg-architecture -qDEB_BUILD_MULTIARCH`
TEMP=${AUTOPKGTEST_TMP:-${TMPDIR:-$(mktemp -d)}}
TDIR=$(mktemp -d $TEMP/lscompbellXXXXXX)

if [ -e /usr/lib/"$DEB_BUILD_MULTIARCH"/libomxil-bellagio.so.0 ]; then
    echo "Test for multi-arch"
    gst-omx-listcomponents \
	/usr/lib/"$DEB_BUILD_MULTIARCH"/libomxil-bellagio.so.0 \
	> "$TDIR"/list1.txt
elif [ -e /usr/lib/libomxil-bellagio.so.0 ]; then
    echo "Test for non-multiarch"
    gst-omx-listcomponents \
	/usr/lib/libomxil-bellagio.so.0 \
	> "$TDIR"/list1.txt
else
    echo "Did not found libomxil-bellagio.so.0"
    exit 1
fi

grep -q "OMX.st.alsa.alsasink" "$TDIR"/list1.txt
if [ $? -eq 0 ] ; then
    echo "Pass - OMX.st.alsa.alsasink"
else
    echo "Fail - OMX.st.alsa.alsasink"
    exit 4
fi

grep -q "OMX.st.alsa.alsasrc" "$TDIR"/list1.txt
if [ $? -eq 0 ] ; then
    echo "Pass - OMX.st.alsa.alsasrc"
else
    echo "Fail - OMX.st.alsa.alsasrc"
    exit 5
fi