summaryrefslogtreecommitdiffstats
path: root/debian/tests/pkg-config-test
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 06:14:41 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-27 06:14:41 +0000
commite0c5d5bce70177b20afa2deee4c62e368a8b9c43 (patch)
treede36eff10a26ee736e19b557f531d03847487856 /debian/tests/pkg-config-test
parentAdding upstream version 2.2.4. (diff)
downloadapt-e0c5d5bce70177b20afa2deee4c62e368a8b9c43.tar.xz
apt-e0c5d5bce70177b20afa2deee4c62e368a8b9c43.zip
Adding debian version 2.2.4.debian/2.2.4debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/tests/pkg-config-test')
-rw-r--r--debian/tests/pkg-config-test23
1 files changed, 23 insertions, 0 deletions
diff --git a/debian/tests/pkg-config-test b/debian/tests/pkg-config-test
new file mode 100644
index 0000000..1e4ec14
--- /dev/null
+++ b/debian/tests/pkg-config-test
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+set -e
+
+WORKDIR=$(mktemp -d)
+trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
+cd $WORKDIR
+cat <<EOF > pkgconfigtest.c
+#include <apt-pkg/init.h>
+#include <stdio.h>
+
+int main()
+{
+ printf("Apt Version: %s \n", pkgVersion);
+ return 0;
+}
+EOF
+
+g++ -o pkgconfigtest pkgconfigtest.c `pkg-config --cflags --libs apt-pkg`
+echo "build: OK"
+[ -x pkgconfigtest ]
+./pkgconfigtest
+echo "run: OK"