File: upstream-examples

package info (click to toggle)
camlpdf 2.8.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,236 kB
  • sloc: ml: 20,559; ansic: 9,205; makefile: 100; sh: 18
file content (22 lines) | stat: -rwxr-xr-x 401 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
#!/bin/sh

set -e

if [ -x /usr/bin/ocamlopt ]; then
    TARGET=native-code
else
    TARGET=byte-code
fi

testdir=${AUTOPKGTEST_TMP:-/tmp}

cp -r examples ${testdir}
cd ${testdir}/examples
echo "** Compiling examples."
make $TARGET
echo -n "** Executing pdfhello ... "
./pdfhello
echo "done."
echo -n "** Checking generated PDF ... "
pdftotext -layout hello.pdf - | grep -q 'Hello, World!'
echo "OK."