Import of pkgsrc-2015Q2
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
===========================================================================
|
||||
$NetBSD: MESSAGE,v 1.1.1.1 2011/10/03 16:57:03 sborrill Exp $
|
||||
$NetBSD: MESSAGE,v 1.2 2015/04/20 08:05:30 sborrill Exp $
|
||||
|
||||
These tools are only useful when NetBSD is running as a paravirtualised
|
||||
guest within XenServer.
|
||||
@@ -7,4 +7,7 @@ guest within XenServer.
|
||||
Your domU kernel must provide /kern/xen/xenbus. Support was added to NetBSD
|
||||
HEAD and netbsd-5 source trees on 23rd September 2011.
|
||||
|
||||
Please update your xenguest rc.d script after upgrading to v6.5.0 of this
|
||||
package (or later).
|
||||
|
||||
===========================================================================
|
||||
|
||||
@@ -1,16 +1,16 @@
|
||||
# $NetBSD: Makefile,v 1.9 2013/04/06 21:07:35 rodent Exp $
|
||||
# $NetBSD: Makefile,v 1.10 2015/04/20 08:05:30 sborrill Exp $
|
||||
#
|
||||
|
||||
# Values from XenServer 6.5.0 = 6, 5, 0, 90977
|
||||
# Values from XenServer 6.0.2 = 6, 0, 2, 52898
|
||||
# Values from XenServer 6.0 = 6, 0, 0, 50560
|
||||
# Values from XenServer 5.6 SP2 = 5, 6, 100, 39153
|
||||
XENMAJOR= 6
|
||||
XENMINOR= 0
|
||||
XENTEENY= 2
|
||||
XENBUILD= 52898
|
||||
XENMINOR= 5
|
||||
XENTEENY= 0
|
||||
XENBUILD= 90977
|
||||
|
||||
VERSION= ${XENMAJOR}.${XENMINOR}.${XENTEENY}
|
||||
PKGREVISION= 3
|
||||
DISTNAME= xe-guest-utilities_5.6.0-595
|
||||
CATEGORIES= sysutils
|
||||
PKGNAME= xe-guest-utilities-${VERSION}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
$NetBSD: distinfo,v 1.2 2012/03/15 14:06:08 sborrill Exp $
|
||||
$NetBSD: distinfo,v 1.3 2015/04/20 08:05:30 sborrill Exp $
|
||||
|
||||
SHA1 (xe-guest-utilities_5.6.0-595.tar.gz) = 7373f2cc37ba3761ee92051513e09787371eb77e
|
||||
RMD160 (xe-guest-utilities_5.6.0-595.tar.gz) = f526fd9ae1b47f22860915aba825ddd440b445b8
|
||||
Size (xe-guest-utilities_5.6.0-595.tar.gz) = 454235 bytes
|
||||
SHA1 (patch-xe-daemon) = 3107fa2e018d66a2ca37b1c2a748c65aa1be3e2f
|
||||
SHA1 (patch-xe-update-guest-attrs) = 64c2ce41b4db1cf7c3a3f0deb1a1d61e7365cbea
|
||||
SHA1 (patch-xe-update-guest-attrs) = 97da7db38dbb42b2a4f8584ece32b7cbb15ea34b
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!@RCD_SCRIPTS_SHELL@
|
||||
#
|
||||
# $NetBSD: xenguest.sh,v 1.4 2012/06/05 12:58:53 sborrill Exp $
|
||||
# $NetBSD: xenguest.sh,v 1.5 2015/04/20 08:05:30 sborrill Exp $
|
||||
#
|
||||
# PROVIDE: xenguest
|
||||
# REQUIRE: DAEMON
|
||||
@@ -36,26 +36,24 @@ xenguest_precmd()
|
||||
echo "${name}: Do not run on dom0, this is for domU use only."
|
||||
exit 1
|
||||
fi
|
||||
if [ ! -f $XE_LINUX_DISTRIBUTION_CACHE ]; then
|
||||
os_distro="$(uname -s)"
|
||||
os_uname="$(uname -r)"
|
||||
os_name="$(uname -s) $(uname -r)"
|
||||
if [ -n "$xenguest_osappend" ]; then
|
||||
os_name="${os_name} ${xenguest_osappend}"
|
||||
fi
|
||||
os_majorver="${os_uname%%.*}"
|
||||
os_minorver="${os_uname#*.}"
|
||||
os_minorver="${os_minorver%%.*}"
|
||||
os_distro="$(uname -s)"
|
||||
os_uname="$(uname -r)"
|
||||
os_name="$(uname -s) $(uname -r)"
|
||||
if [ -n "$xenguest_osappend" ]; then
|
||||
os_name="${os_name} ${xenguest_osappend}"
|
||||
fi
|
||||
os_majorver="${os_uname%%.*}"
|
||||
os_minorver="${os_uname#*.}"
|
||||
os_minorver="${os_minorver%%.*}"
|
||||
|
||||
mkdir -p @VARBASE@/cache
|
||||
cat << EOF > $XE_LINUX_DISTRIBUTION_CACHE
|
||||
mkdir -p @VARBASE@/cache
|
||||
cat << EOF > $XE_LINUX_DISTRIBUTION_CACHE
|
||||
os_distro="$os_distro"
|
||||
os_uname="$os_uname"
|
||||
os_name="$os_name"
|
||||
os_majorver="$os_majorver"
|
||||
os_minorver="$os_minorver"
|
||||
EOF
|
||||
fi
|
||||
}
|
||||
|
||||
xenguest_start()
|
||||
|
||||
@@ -1,65 +1,19 @@
|
||||
$NetBSD: patch-xe-update-guest-attrs,v 1.2 2012/03/15 14:06:08 sborrill Exp $
|
||||
$NetBSD: patch-xe-update-guest-attrs,v 1.3 2015/04/20 08:05:30 sborrill Exp $
|
||||
|
||||
--- xe-update-guest-attrs.orig 2011-09-23 15:39:33.000000000 +0100
|
||||
+++ xe-update-guest-attrs 2011-09-23 15:44:30.000000000 +0100
|
||||
@@ -35,11 +35,11 @@
|
||||
export LANG
|
||||
|
||||
|
||||
-XE_LINUX_DISTRIBUTION_CACHE=/var/cache/xe-linux-distribution
|
||||
+XE_LINUX_DISTRIBUTION_CACHE=@VARBASE@/cache/xe-linux-distribution
|
||||
Patch for pkgsrc and NetBSD ifconfig
|
||||
|
||||
--- xe-update-guest-attrs.orig 2010-12-20 15:34:07.000000000 +0000
|
||||
+++ xe-update-guest-attrs 2015-04-18 20:24:10.000000000 +0100
|
||||
@@ -39,7 +39,7 @@
|
||||
|
||||
IPADDR_RE="\([[:digit:]]\{1,3\}\.\)\{3\}[[:digit:]]\{1,3\}"
|
||||
|
||||
-export PATH=/usr/sbin:/usr/bin:/sbin:/bin
|
||||
+export PATH=/usr/sbin:/usr/bin:/sbin:/bin:@PREFIX@/sbin:@PREFIX@/bin
|
||||
+export PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/pkg/sbin:/usr/pkg/bin
|
||||
XENSTORE=${XENSTORE:-xenstore}
|
||||
|
||||
XENSTORE_UPDATED=0
|
||||
@@ -56,7 +56,7 @@
|
||||
|
||||
xenstore_write_cached() {
|
||||
key="$1" newval="$2"
|
||||
- cache=/var/cache/xenstore/$key
|
||||
+ cache=@VARBASE@/cache/xenstore/$key
|
||||
if [ -f $cache ] ; then
|
||||
# cache exists
|
||||
oldval=$(cat "$cache")
|
||||
@@ -84,13 +84,13 @@
|
||||
|
||||
# If we detect a domain change then delete our cache and force a refresh
|
||||
domid=$(xenstore-read "domid")
|
||||
-cache=/var/cache/xenstore/unique-domain-id
|
||||
+cache=@VARBASE@/cache/xenstore/unique-domain-id
|
||||
newval=$(xenstore-read "/local/domain/${domid}/unique-domain-id")
|
||||
if [ -e $cache ]; then
|
||||
oldval=$(cat "$cache")
|
||||
if [ "$oldval" != "$newval" ]; then
|
||||
# domain changed
|
||||
- rm -rf /var/cache/xenstore
|
||||
+ rm -rf @VARBASE@/cache/xenstore
|
||||
fi
|
||||
fi
|
||||
mkdir -p $(dirname "$cache")
|
||||
@@ -98,7 +98,7 @@
|
||||
|
||||
xenstore_rm_cached() {
|
||||
key="$1"
|
||||
- cache=/var/cache/xenstore/$key
|
||||
+ cache=@VARBASE@/cache/xenstore/$key
|
||||
if [ ! -e $cache ] ; then
|
||||
return 1
|
||||
fi
|
||||
@@ -112,7 +112,7 @@
|
||||
}
|
||||
|
||||
xenstore_list_interfaces_cached() {
|
||||
- topdir=/var/cache/xenstore/attr
|
||||
+ topdir=@VARBASE@/cache/xenstore/attr
|
||||
if [ -d $topdir ] ; then
|
||||
cd $topdir
|
||||
for dir in * ; do
|
||||
@@ -133,49 +133,45 @@
|
||||
@@ -133,49 +133,50 @@
|
||||
|
||||
|
||||
|
||||
@@ -111,6 +65,7 @@ $NetBSD: patch-xe-update-guest-attrs,v 1.2 2012/03/15 14:06:08 sborrill Exp $
|
||||
+# enabled=0
|
||||
+# address: 0e:7e:86:20:7b:82
|
||||
+# inet 192.168.1.109 netmask 0xffffff00 broadcast 192.168.1.255
|
||||
+# inet alias 10.20.30.40 netmask 0xffffff00 broadcast 10.20.30.255
|
||||
+# inet6 fe80::c7e:86ff:fe20:7b82%xennet0 prefixlen 64 scopeid 0x1
|
||||
+#lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 33184
|
||||
+# inet 127.0.0.1 netmask 0xff000000
|
||||
@@ -130,25 +85,29 @@ $NetBSD: patch-xe-update-guest-attrs,v 1.2 2012/03/15 14:06:08 sborrill Exp $
|
||||
+ sub(":.*", "", current)
|
||||
+ sub("xennet", "eth", current)
|
||||
+ iflist = iflist " " current
|
||||
+ ifs[current] = ""
|
||||
+ } else {
|
||||
+ current =""
|
||||
+ }
|
||||
+ }
|
||||
+ if ($1 == "inet" && current != "") {
|
||||
+ ifs[current] = $2
|
||||
+ current = ""
|
||||
+ if (($1 == "inet" || $1 == "inet6") && current != "") {
|
||||
+ if ($2 == "alias") ip = $3
|
||||
+ else ip = $2
|
||||
+ if ($1 == "inet6") sub("%.*", "", ip)
|
||||
+ if (ifs[current] != "") ifs[current] = ifs[current] ", " ip
|
||||
+ else ifs[current] = ip
|
||||
+ }
|
||||
+ }
|
||||
+ END {
|
||||
+ sub("^ ", "", iflist)
|
||||
+ printf "ifs=%c%s%c\n", 39, iflist, 39
|
||||
+ for (i in ifs)
|
||||
+ printf "inet_%s=%s\n", i, ifs[i]
|
||||
+ printf "inet_%s=%c%s%c\n", i, 39, ifs[i], 39
|
||||
+ }')
|
||||
|
||||
# network
|
||||
for if in $ifs ; do
|
||||
@@ -206,16 +202,18 @@
|
||||
@@ -206,16 +207,18 @@
|
||||
fi
|
||||
|
||||
# whether I support ballooning or not
|
||||
|
||||
Reference in New Issue
Block a user