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 39 40 41 42 43 44 45 46
|
#!/bin/sh
#
# Try to build and run the example code. Provide input on both stdin
# and as first argument as the programs seem to handle either or both.
# The goal is to verify that it is possible to link with the libvorbis
# library and run the resulting binaries.
set -e
retval=0
#cd $AUTOPKGTEST_TMP
# We don't want plugins from the build directory for the
# installed package.
rm -f pev.conf
if type valgrind ; then
VALGRIND=valgrind
else
VALGRIND=
fi
TESTEXE="/usr/share/win32/gzip.exe"
# Detect problem on s390x
if [ ! -e "$TESTEXE" ] ; then
echo "error: missing gzip.exe. No such file in gzip-win32?"
dpkg -L gzip-win32
exit 1
fi
if $VALGRIND pesec "$TESTEXE" | grep ASLR; then
echo "success: pesec reported ASLR status"
else
echo "error: pesec did not report ASLR status"
retval=1
fi
if $VALGRIND pehash "$TESTEXE" | grep sha256:; then
echo "success: pehash reported ASLR status"
else
echo "error: pehash did not report ASLR status"
retval=1
fi
exit $retval
|