From 3bc114befabaf348074f23142bd854c156b438ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dag-Erling=20Sm=C3=B8rgrav?= Date: Fri, 23 Aug 2013 17:07:42 +0000 Subject: [PATCH] It is entirely possible that pkg is present but not installed as a package, or that the pkg binary in $PATH is not the one that was installed (e.g. a development version in $HOME/bin/pkg). Therefore, use pkg -vv rather than pkg query to determine the pkg version. git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@733 185d5e19-27fe-0310-9dcf-9bff6b9f3609 --- mkpkgng.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkpkgng.in b/mkpkgng.in index 915b874..6fe5069 100644 --- a/mkpkgng.in +++ b/mkpkgng.in @@ -69,7 +69,7 @@ cd "$srcdir" # # Determine pkgng version and ABI # -pkgver=$(pkg query %v pkg) +pkgver=$(pkg -vv | awk '$1 == "Version:" { print $2 }') [ -n "$pkgver" ] || error "Unable to determine pkgng version." pkgabi=$(pkg -vv | awk '$1 == "ABI:" { print $2 }') [ -n "$pkgabi" ] || error "Unable to determine package ABI."