Tizen 2.0 Release
[framework/graphics/cairo.git] / src / check-plt.sh
1 #!/bin/sh
2
3 LC_ALL=C
4 export LC_ALL
5
6 if which readelf 2>/dev/null >/dev/null; then
7         :
8 else
9         echo "'readelf' not found; skipping test"
10         exit 0
11 fi
12
13 test -z "$srcdir" && srcdir=.
14 test -z "$MAKE" && MAKE=make
15 stat=0
16
17 $MAKE check-has-hidden-symbols.i > /dev/null || exit 1
18 if tail -1 check-has-hidden-symbols.i | grep CAIRO_HAS_HIDDEN_SYMBOLS >/dev/null; then
19         echo "Compiler doesn't support symbol visibility; skipping test"
20         exit 0
21 fi
22
23 for so in .libs/lib*.so; do
24         echo Checking "$so" for local PLT entries
25         readelf -W -r "$so" | grep 'JU\?MP_SLO' | grep 'cairo' >&2 && stat=1
26 done
27
28 exit $stat