1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-18 19:49:40 +00:00

Merge 2 useful diffs from the dev tree:

- compatibility with verbose boot
- proper treatment for undefined vm_dir

PR:		222496
Approved by:	maintainer-timeout (since 20170921)
This commit is contained in:
Dmitry Morozovsky 2017-12-23 09:58:55 +00:00
parent e9893af029
commit 2da3ffc69e
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=457036
3 changed files with 34 additions and 0 deletions

View File

@ -2,6 +2,7 @@
PORTNAME= vm-bhyve
PORTVERSION= 1.1.8
PORTREVISION= 1
DISTVERSIONPREFIX=v
CATEGORIES= sysutils

View File

@ -0,0 +1,22 @@
--- lib/vm-util.orig
+++ lib/vm-util
@@ -55,7 +55,7 @@
# @modifies VM_NO_UG
#
util::check_bhyve_support(){
- local _mesg _result
+ local _mesg _mesg1 _mesg2 _result
# basic checks
[ `id -u` -ne 0 ] && util::err "virtual machines can only be managed by root"
@@ -73,7 +73,9 @@
fi
# check ept for intel
- _mesg=$(grep -E '^[ ]+VT-x' /var/run/dmesg.boot | tail -n 1)
+ _mesg1=$(grep -E '^[ ]+VT-x' /var/run/dmesg.boot | tail -n 1)
+ _mesg2=$(grep -E '^[ ]+Secondary Processor Controls' /var/run/dmesg.boot | tail -n 1)
+ _mesg="${_mesg1}${_mesg2}"
if [ -n "${_mesg}" ]; then

View File

@ -0,0 +1,11 @@
--- lib/vm-zfs.orig
+++ lib/vm-zfs
@@ -45,7 +45,7 @@
# check for zfs storage location
# user should specify "zfs:pool/dataset" if they want ZFS support
- if [ ${vm_dir%%:*} = "zfs" ]; then
+ if [ "${vm_dir%%:*}" = "zfs" ]; then
# check zfs running
kldstat -qm zfs >/dev/null 2>&1