be able to run abicheck from any directory
authorDavid Kalnischkies <david@kalnischkies.de>
Sun, 23 Mar 2014 13:09:12 +0000 (14:09 +0100)
committerDavid Kalnischkies <david@kalnischkies.de>
Fri, 11 Apr 2014 06:58:36 +0000 (08:58 +0200)
Git-Dch: Ignore

.gitignore
abicheck/run_abi_test

index 488682e..a00c84a 100644 (file)
@@ -42,3 +42,9 @@
 /vendor/current
 /vendor/*/sources.list
 /vendor/*/makefile.auto
+
+# generated for and by abicheck
+/abicheck/apt_build.xml
+/abicheck/apt_installed.xml
+/abicheck/compat_reports/
+/abicheck/logs/
index 8f2d7d2..18c13df 100755 (executable)
@@ -1,5 +1,8 @@
 #!/bin/sh
 
+# ensure we are in the abibreak subdirectory
+cd "$(readlink -f $(dirname $0))"
+
 if [ ! -d ../build ]; then
        echo "../build missing, did you run make?"
        exit 1
@@ -10,7 +13,7 @@ if [ ! -x "$(which abi-compliance-checker 2>/dev/null )" ]; then
        exit 1
 fi
 
-LIBPATH=$(find /usr/lib/ -type f  -name "libapt-*.so.*" -printf %p\\\\n)
+LIBPATH=$(find /usr/lib/$(dpkg-architecture -qDEB_HOST_MULTIARCH) -type f -regex '.*/libapt-\(pkg\|inst\)\.so\..*' -printf %p\\\\n)
 sed s#@installed_libapt@#$LIBPATH# apt_installed.xml.in > apt_installed.xml
 
 BUILDPATH=$(readlink -f ../build)