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
|
#!/bin/sh
# autopkgtest check: Build and run a program against ITL, to verify that the
# headers and pkg-config file are installed correctly
set -e
WORKDIR=$(mktemp -d)
trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
cd $WORKDIR
cat <<EOF > itltest.c
#include <itl/prayer.h>
int main(int argc, char **argv)
{
Method m;
getMethod(0, &m);
return 0;
}
EOF
gcc -o itltest itltest.c -litl -lm
#gcc -o itltest itltest.c `pkg-config --cflags --libs itl`
echo "build: OK"
[ -x itltest ]
./itltest
echo "run: OK"
|