diff options
Diffstat (limited to '')
-rwxr-xr-x | debian/tests/build-and-run-examples | 18 | ||||
-rw-r--r-- | debian/tests/control | 6 |
2 files changed, 24 insertions, 0 deletions
diff --git a/debian/tests/build-and-run-examples b/debian/tests/build-and-run-examples new file mode 100755 index 0000000..6145719 --- /dev/null +++ b/debian/tests/build-and-run-examples @@ -0,0 +1,18 @@ +#!/bin/sh + +set -e + +if [ -d "$AUTOPKGTEST_ARTIFACTS" ]; then + cd "$AUTOPKGTEST_ARTIFACTS" +fi + +for x in /usr/share/doc/librnp-dev/examples/*.c; do + bin="$(basename "$x" .c)" + printf 'building %s\n' "$bin" + gcc -g -O2 -Werror -Wall -pedantic -o "$bin" "$x" $(pkg-config --cflags --libs librnp) +done + +for x in generate encrypt decrypt sign verify; do + printf '**** %s ****\n' "$x" + "./$x" +done diff --git a/debian/tests/control b/debian/tests/control new file mode 100644 index 0000000..48f1da5 --- /dev/null +++ b/debian/tests/control @@ -0,0 +1,6 @@ +Tests: build-and-run-examples +Depends: + gcc, + libc6-dev, + librnp-dev, + pkg-config, |