File: build-lib

package info (click to toggle)
hyperscan 5.4.2-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 12,304 kB
  • sloc: cpp: 143,324; ansic: 41,041; python: 621; sh: 32; makefile: 12
file content (21 lines) | stat: -rwxr-xr-x 513 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/sh
# autopkgtest check: Build a program against libhyperscan and check whether a
#                    runnable binary is produced.
# Author: Sascha Steinbiss <satta@debian.org>
set -e

SRC=$(pwd)/examples/simplegrep.c
RES=$(pwd)/debian/tests/simplegrep.result
WORKDIR=$(mktemp -d)

trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
cd $WORKDIR

gcc -o simplegrep $SRC $(pkg-config --cflags --libs libhs)
[ -x simplegrep ]
echo "build: OK"

echo "barbaz" > 1
./simplegrep ba 1 > 2
diff 2 $RES
echo "run: OK"