summaryrefslogtreecommitdiff
path: root/usr.sbin/bsdconfig
diff options
context:
space:
mode:
authorDevin Teske <dteske@FreeBSD.org>2016-01-27 00:09:53 +0000
committerDevin Teske <dteske@FreeBSD.org>2016-01-27 00:09:53 +0000
commitc4ba6882948e2f683d587057f6c8cfa2b04e24ef (patch)
tree041625ce694cdfeda9357510f31387409d35a1c9 /usr.sbin/bsdconfig
parent938443fdf6545a53e2caabe083c67a70be5cbcc1 (diff)
downloadsrc-test2-c4ba6882948e2f683d587057f6c8cfa2b04e24ef.tar.gz
src-test2-c4ba6882948e2f683d587057f6c8cfa2b04e24ef.zip
Notes
Diffstat (limited to 'usr.sbin/bsdconfig')
-rw-r--r--usr.sbin/bsdconfig/share/packages/musthavepkg.subr8
1 files changed, 6 insertions, 2 deletions
diff --git a/usr.sbin/bsdconfig/share/packages/musthavepkg.subr b/usr.sbin/bsdconfig/share/packages/musthavepkg.subr
index 929823e4f21e..b336d26d9c2e 100644
--- a/usr.sbin/bsdconfig/share/packages/musthavepkg.subr
+++ b/usr.sbin/bsdconfig/share/packages/musthavepkg.subr
@@ -1,6 +1,6 @@
if [ ! "$_PACKAGES_MUSTHAVEPKG_SUBR" ]; then _PACKAGES_MUSTHAVEPKG_SUBR=1
#
-# Copyright (c) 2014 Devin Teske
+# Copyright (c) 2014-2016 Devin Teske
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
@@ -45,7 +45,11 @@ f_include $BSDCFG_SHARE/mustberoot.subr
f_musthavepkg_init()
{
local funcname=f_musthavepkg_init
- local pkg_abi_awk='$1~/^ABI/{print $NF; exit}'
+ local pkg_abi_awk=' # BEGIN-AWK
+ $1 ~ /^ABI/ && $0 = $NF, sub(/^"/, "") && sub(/".*/, "") {
+ print; found = 1; exit
+ } END { exit ! found }
+ ' # END-AWK
if [ "$PKG_ABI" ]; then # Already set
f_dprintf "PKG_ABI=[%s]" "$PKG_ABI"