pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/sysutils



Module Name:    pkgsrc
Committed By:   bouyer
Date:           Sun Apr 18 12:31:27 UTC 2021

Added Files:
        pkgsrc/sysutils/xenkernel415: DESCR MESSAGE Makefile PLIST distinfo
        pkgsrc/sysutils/xenkernel415/patches: patch-Config.mk
            patch-xen_Makefile patch-xen_Rules.mk patch-xen_arch_x86_Rules.mk
            patch-xen_arch_x86_boot_build32.mk patch-xen_arch_x86_extable.c
            patch-xen_arch_x86_mm_p2m.c
            patch-xen_drivers_passthrough_x86_iommu.c
        pkgsrc/sysutils/xentools415: DESCR MESSAGE MESSAGE.NetBSD Makefile
            PLIST distinfo
        pkgsrc/sysutils/xentools415/patches:
            patch-.._seabios-rel-1.14.0_src_string.c patch-Config.mk
            patch-Makefile patch-docs_man_xl.1.pod.in
            patch-docs_man_xl.cfg.5.pod.in patch-docs_man_xlcpupool.cfg.5.pod
            patch-docs_misc_block-scripts.txt patch-docs_misc_vtd.txt
            patch-tools_Makefile patch-tools_configure
            patch-tools_console_daemon_utils.c patch-tools_examples_Makefile
            patch-tools_firmware_Makefile
            patch-tools_firmware_etherboot_Makefile
            patch-tools_hotplug_NetBSD_Makefile
            patch-tools_hotplug_common_Makefile
            patch-tools_include_xen-sys_NetBSD_evtchn.h
            patch-tools_include_xen-sys_NetBSD_privcmd.h
            patch-tools_libs_ctrl_Makefile patch-tools_libs_libs.mk
            patch-tools_libs_light_libxl.c patch-tools_libs_light_libxl_pci.c
            patch-tools_libs_util_libxlu_pci.c
            patch-tools_libs_xenstore_xenstored_control.c
            patch-tools_libxl_libxl_dom.c patch-tools_libxl_libxl_event.c
            patch-tools_libxl_libxl_internal.h patch-tools_misc_xenhypfs.c
            patch-tools_ocaml_common.make patch-tools_ocaml_xenstored_Makefile
            patch-tools_ocaml_xenstored_utils.ml patch-tools_pygrub_Makefile
            patch-tools_python_Makefile
            patch-tools_qemu-xen-traditional_Makefile
            patch-tools_qemu-xen-traditional_block-raw-posix.c
            patch-tools_qemu-xen-traditional_configure
            patch-tools_qemu-xen-traditional_hw_e1000.c
            patch-tools_qemu-xen-traditional_hw_ide.c
            patch-tools_qemu-xen-traditional_hw_pass-through.c
            patch-tools_qemu-xen-traditional_hw_pass-through.h
            patch-tools_qemu-xen-traditional_hw_piix4acpi.c
            patch-tools_qemu-xen-traditional_hw_pt-graphics.c
            patch-tools_qemu-xen-traditional_hw_pt-msi.c
            patch-tools_qemu-xen-traditional_hw_pt-msi.h
            patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak
            patch-tools_qemu-xen-traditional_net.c
            patch-tools_qemu-xen-traditional_xen-hooks.mak
            patch-tools_qemu-xen_audio_audio.c patch-tools_qemu-xen_configure
            patch-tools_qemu-xen_net_tap-bsd.c patch-tools_qemu-xen_net_tap.c
            patch-tools_xenpaging_xenpaging.c patch-tools_xenstore_xs_lib.c
            patch-tools_xl_Makefile patch-xen_Makefile patch-xen_Rules.mk
            patch-xen_arch_x86_Makefile patch-xen_include_Makefile

Log Message:
Add xenkernel415 and xentools415 version 4.15.0

Xen is a hypervisor which supports running multiple guest operating
systems on a single machine. Guest OSes (also called "domains")
can be either paravirtualised (i.e. make hypercalls in order to
access hardware), run in HVM (Hardware Virtualisation Mode) where
they will be presented with virtual devices, or a combination where
they use hypercalls to access hardware but manage memory themselves.
At boot, the xen kernel is loaded along with the guest kernel for
the first domain (called domain0). domain0 has privileges to access
the physical hardware (PCI and ISA devices), administrate other
domains and provide virtual devices (disks and network) to other
domains.


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 pkgsrc/sysutils/xenkernel415/DESCR \
    pkgsrc/sysutils/xenkernel415/MESSAGE \
    pkgsrc/sysutils/xenkernel415/Makefile pkgsrc/sysutils/xenkernel415/PLIST \
    pkgsrc/sysutils/xenkernel415/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/sysutils/xenkernel415/patches/patch-Config.mk \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_Makefile \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_Rules.mk \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_Rules.mk \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_boot_build32.mk \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_extable.c \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_mm_p2m.c \
    pkgsrc/sysutils/xenkernel415/patches/patch-xen_drivers_passthrough_x86_iommu.c
cvs rdiff -u -r0 -r1.1 pkgsrc/sysutils/xentools415/DESCR \
    pkgsrc/sysutils/xentools415/MESSAGE \
    pkgsrc/sysutils/xentools415/MESSAGE.NetBSD \
    pkgsrc/sysutils/xentools415/Makefile pkgsrc/sysutils/xentools415/PLIST \
    pkgsrc/sysutils/xentools415/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/sysutils/xentools415/patches/patch-.._seabios-rel-1.14.0_src_string.c \
    pkgsrc/sysutils/xentools415/patches/patch-Config.mk \
    pkgsrc/sysutils/xentools415/patches/patch-Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.1.pod.in \
    pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.cfg.5.pod.in \
    pkgsrc/sysutils/xentools415/patches/patch-docs_man_xlcpupool.cfg.5.pod \
    pkgsrc/sysutils/xentools415/patches/patch-docs_misc_block-scripts.txt \
    pkgsrc/sysutils/xentools415/patches/patch-docs_misc_vtd.txt \
    pkgsrc/sysutils/xentools415/patches/patch-tools_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_configure \
    pkgsrc/sysutils/xentools415/patches/patch-tools_console_daemon_utils.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_examples_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_etherboot_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_NetBSD_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_common_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_evtchn.h \
    pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_privcmd.h \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_ctrl_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_libs.mk \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl_pci.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_util_libxlu_pci.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libs_xenstore_xenstored_control.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_dom.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_event.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_internal.h \
    pkgsrc/sysutils/xentools415/patches/patch-tools_misc_xenhypfs.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_common.make \
    pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_utils.ml \
    pkgsrc/sysutils/xentools415/patches/patch-tools_pygrub_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_python_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_block-raw-posix.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_configure \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_e1000.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_ide.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.h \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_piix4acpi.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-graphics.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.h \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_net.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_xen-hooks.mak \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_audio_audio.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_configure \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap-bsd.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_xenpaging_xenpaging.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_xenstore_xs_lib.c \
    pkgsrc/sysutils/xentools415/patches/patch-tools_xl_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-xen_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-xen_Rules.mk \
    pkgsrc/sysutils/xentools415/patches/patch-xen_arch_x86_Makefile \
    pkgsrc/sysutils/xentools415/patches/patch-xen_include_Makefile

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Added files:

Index: pkgsrc/sysutils/xenkernel415/DESCR
diff -u /dev/null pkgsrc/sysutils/xenkernel415/DESCR:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/DESCR  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,16 @@
+Xen is a hypervisor which supports running multiple guest operating
+systems on a single machine. Guest OSes (also called "domains")
+can be either paravirtualised (i.e. make hypercalls in order to
+access hardware), run in HVM (Hardware Virtualisation Mode) where
+they will be presented with virtual devices, or a combination where
+they use hypercalls to access hardware but manage memory themselves.
+At boot, the xen kernel is loaded along with the guest kernel for
+the first domain (called domain0). domain0 has privileges to access
+the physical hardware (PCI and ISA devices), administrate other
+domains and provide virtual devices (disks and network) to other
+domains.
+
+This package contains the 4.15 Xen kernel itself.  PCI passthrough is
+not supported.  PAE is mandatory; on i386 one must use XEN3PAE_DOM[0U].
+
+This is the recommended Xen version in pkgsrc.
Index: pkgsrc/sysutils/xenkernel415/MESSAGE
diff -u /dev/null pkgsrc/sysutils/xenkernel415/MESSAGE:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/MESSAGE        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,11 @@
+===========================================================================
+$NetBSD: MESSAGE,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+The Xen hypervisor is installed under the following locations:
+       ${XENKERNELDIR}/xen.gz          (standard hypervisor)
+       ${XENKERNELDIR}/xen-debug.gz    (debug hypervisor)
+
+Note that unlike upstream Xen, pv-linear-pt defaults to true.
+You can disable it using pv-linear-pt=false on the Xen command line,
+but then you can't boot NetBSD in PV mode.
+===========================================================================
Index: pkgsrc/sysutils/xenkernel415/Makefile
diff -u /dev/null pkgsrc/sysutils/xenkernel415/Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/Makefile       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,82 @@
+# $NetBSD: Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+VERSION=       4.15.0
+PKGREVISION=   0
+DISTNAME=      xen-${VERSION}
+PKGNAME=       xenkernel415-${VERSION}
+CATEGORIES=    sysutils
+MASTER_SITES=  https://downloads.xenproject.org/release/xen/${VERSION}/
+DIST_SUBDIR=   xen415
+
+MAINTAINER=    bouyer%NetBSD.org@localhost
+HOMEPAGE=      https://xenproject.org/
+COMMENT=       Xen 4.15.x Kernel
+
+LICENSE=       gnu-gpl-v2
+
+ONLY_FOR_PLATFORM=     NetBSD-*.*-x86_64
+
+SSP_SUPPORTED= no
+
+NO_CONFIGURE=  yes
+USE_TOOLS+=    gmake bison
+
+PYTHON_FOR_BUILD_ONLY=         YES
+
+MAKE_ENV+=     OCAML_TOOLS=no
+.if defined(PKGREVISION) && !empty(PKGREVISION) && (${PKGREVISION} != "0")
+MAKE_ENV+=     XEN_VENDORVERSION=nb${PKGREVISION}
+.else
+MAKE_ENV+=     XEN_VENDORVERSION=nb0
+.endif
+
+INSTALLATION_DIRS=     xen415-kernel
+XENKERNELDIR=          ${PREFIX}/${INSTALLATION_DIRS}
+
+MESSAGE_SUBST+=                XENKERNELDIR=${XENKERNELDIR}
+
+.include "../../mk/compiler.mk"
+.if !empty(PKGSRC_COMPILER:Mclang)
+EXTRA_CFLAGS+= -Qunused-arguments -no-integrated-as -Wno-error=format \
+               -Wno-error=parentheses-equality -Wno-error=enum-conversion \
+               -Wno-error=unused-function -Wno-error=unused-const-variable \
+               -Wno-error=ignored-attributes -Wno-error=constant-conversion \
+               -Wno-error=address-of-packed-member \
+               -Wno-error=initializer-overrides \
+               -Wno-error=tautological-compare -Wno-error=pragma-pack
+.elif !empty(PKGSRC_COMPILER:Mgcc)
+EXTRA_CFLAGS+=  -falign-functions=16
+.endif
+
+MAKE_ENV+=     EXTRA_CFLAGS=${EXTRA_CFLAGS:Q}
+
+do-build:
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} build-xen
+       ${CP} ${WRKSRC}/xen/xen.gz ${WRKDIR}/xen.gz
+       cd ${WRKSRC} && ${MAKE_PROGRAM} clean
+       echo "CONFIG_DEBUG=y" >> ${WRKSRC}/xen/.config
+       echo "CONFIG_DEBUG_INFO=y" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_DEBUG_LOCK_PROFILE is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_DEBUG_LOCKS is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_DEBUG_TRACE is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_XMEM_POOL_POISON is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_CRASH_DEBUG is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_GDBSX is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_FRAME_POINTER is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_GCOV is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_LOCK_PROFILE is not set" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_PERF_COUNTERS is not set" >> ${WRKSRC}/xen/.config
+       echo "CONFIG_VERBOSE_DEBUG=y" >> ${WRKSRC}/xen/.config
+       echo "CONFIG_SCRUB_DEBUG=y" >> ${WRKSRC}/xen/.config
+       echo "# CONFIG_UBSAN is not set" >> ${WRKSRC}/xen/.config
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} build-xen
+       ${CP} ${WRKSRC}/xen/xen.gz ${WRKDIR}/xen-debug.gz
+
+do-install:
+       ${INSTALL_DATA} ${WRKDIR}/xen.gz \
+           ${DESTDIR}${XENKERNELDIR}/xen.gz
+       ${INSTALL_DATA} ${WRKDIR}/xen-debug.gz \
+           ${DESTDIR}${XENKERNELDIR}/xen-debug.gz
+
+.include "../../lang/python/application.mk"
+.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/sysutils/xenkernel415/PLIST
diff -u /dev/null pkgsrc/sysutils/xenkernel415/PLIST:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/PLIST  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,3 @@
+@comment $NetBSD: PLIST,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+xen415-kernel/xen-debug.gz
+xen415-kernel/xen.gz
Index: pkgsrc/sysutils/xenkernel415/distinfo
diff -u /dev/null pkgsrc/sysutils/xenkernel415/distinfo:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/distinfo       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,14 @@
+$NetBSD: distinfo,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+SHA1 (xen415/xen-4.15.0.tar.gz) = 4ea99cf3063db822dfbaf971bf8e9d50828d485a
+RMD160 (xen415/xen-4.15.0.tar.gz) = e314791e29244da385e482166776641929babad3
+SHA512 (xen415/xen-4.15.0.tar.gz) = 93683b8a97387ca5f003c635a11d163e61c87dbdc9a03081f9155fe87b49f1dfa74ce243fcd5e04dc009353a36e2375b786f1ebde828b5951a094cd64197b4c7
+Size (xen415/xen-4.15.0.tar.gz) = 40785399 bytes
+SHA1 (patch-Config.mk) = 9372a09efd05c9fbdbc06f8121e411fcb7c7ba65
+SHA1 (patch-xen_Makefile) = 465388d80de414ca3bb84faefa0f52d817e423a6
+SHA1 (patch-xen_Rules.mk) = c743dc63f51fc280d529a7d9e08650292c171dac
+SHA1 (patch-xen_arch_x86_Rules.mk) = 54392a7d719a21bc625a96b673056f88b96df97d
+SHA1 (patch-xen_arch_x86_boot_build32.mk) = b82c20de9b86ddaa9d05bbc1ff28f970eb78473c
+SHA1 (patch-xen_arch_x86_extable.c) = e439e6f3fe704d9b2894fc6b9e8f23f321a00f05
+SHA1 (patch-xen_arch_x86_mm_p2m.c) = 6e9b84dc8448eca9677f184e720bbfcb3c6d314e
+SHA1 (patch-xen_drivers_passthrough_x86_iommu.c) = 8b3a36a019490b1d125ea1f74274435382797da1

Index: pkgsrc/sysutils/xenkernel415/patches/patch-Config.mk
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-Config.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-Config.mk        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,14 @@
+$NetBSD: patch-Config.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- Config.mk.orig     2018-04-17 19:21:31.000000000 +0200
++++ Config.mk  2018-04-23 13:29:47.000000000 +0200
+@@ -32,6 +32,9 @@
+ # Tools to run on system hosting the build
+ HOSTCFLAGS  = -Wall -Werror -Wstrict-prototypes -O2 -fomit-frame-pointer
+ HOSTCFLAGS += -fno-strict-aliasing
++HOSTCFLAGS += ${EXTRA_CFLAGS}
++CFLAGS     += ${EXTRA_CFLAGS}
++
+ 
+ DISTDIR     ?= $(XEN_ROOT)/dist
+ DESTDIR     ?= /
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_Makefile
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-xen_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- xen/Makefile.orig  2018-04-17 19:21:31.000000000 +0200
++++ xen/Makefile       2018-04-23 13:29:47.000000000 +0200
+@@ -167,7 +167,7 @@
+           -e 's/@@whoami@@/$(XEN_WHOAMI)/g' \
+           -e 's/@@domain@@/$(XEN_DOMAIN)/g' \
+           -e 's/@@hostname@@/$(XEN_BUILD_HOST)/g' \
+-          -e 's!@@compiler@@!$(shell $(CC) $(CFLAGS) --version 2>&1 | head -1)!g' \
++          -e 's!@@compiler@@!$(shell $(CC) $(EXTRA_CFLAGS) $(CFLAGS) --version 2>&1 | head -1)!g' \
+           -e 's/@@version@@/$(XEN_VERSION)/g' \
+           -e 's/@@subversion@@/$(XEN_SUBVERSION)/g' \
+           -e 's/@@extraversion@@/$(XEN_EXTRAVERSION)/g' \
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_Rules.mk
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_Rules.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_Rules.mk     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-xen_Rules.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- xen/Rules.mk.orig  2018-04-23 14:50:02.000000000 +0200
++++ xen/Rules.mk       2018-04-23 14:50:32.000000000 +0200
+@@ -1,4 +1,7 @@
+ 
++#reset cflags. Why is it needed in pkgsrc ?
++CFLAGS=
++
+ -include $(BASEDIR)/include/config/auto.conf
+ 
+ include $(XEN_ROOT)/Config.mk
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_Rules.mk
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_Rules.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_Rules.mk    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,10 @@
+$NetBSD: patch-xen_arch_x86_Rules.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- xen/arch/x86/Rules.mk.orig 2020-12-08 15:28:32.000000000 +0100
++++ xen/arch/x86/Rules.mk      2020-12-08 17:27:58.740162095 +0100
+@@ -8,3 +8,5 @@
+ endif
+ c_flags += $(object_label_flags) $(CFLAGS-stack-boundary)
+ a_flags += $(object_label_flags) $(CFLAGS-stack-boundary)
++
++c_flags += $(EXTRA_CFLAGS)
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_boot_build32.mk
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_boot_build32.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_boot_build32.mk     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-xen_arch_x86_boot_build32.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+linux's toolchain doesn't generate a .eh_frame section but NetBSD does.
+remove it.
+
+--- xen/arch/x86/boot/build32.mk.orig  2018-04-17 19:21:31.000000000 +0200
++++ xen/arch/x86/boot/build32.mk       2018-04-23 13:29:47.000000000 +0200
+@@ -25,7 +25,7 @@
+                               exit $$(expr $$idx + 1);; \
+                       esac; \
+               done
+-      $(OBJCOPY) -O binary -R .got.plt $< $@
++      $(OBJCOPY) -O binary -R .got.plt -R .eh_frame $< $@
+ 
+ %.lnk: %.o
+       $(LD) $(LDFLAGS_DIRECT) -N -T build32.lds -o $@ $<
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_extable.c
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_extable.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_extable.c   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-xen_arch_x86_extable.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+silent nosy debug output
+
+--- xen/arch/x86/extable.c.orig        2020-12-08 18:32:35.707855990 +0100
++++ xen/arch/x86/extable.c     2020-12-08 18:32:05.786712864 +0100
+@@ -199,7 +199,7 @@
+         __start___pre_ex_table, __stop___pre_ex_table-1, addr);
+     if ( fixup )
+     {
+-        dprintk(XENLOG_INFO, "Pre-exception: %p -> %p\n", _p(addr), _p(fixup));
++        // dprintk(XENLOG_INFO, "Pre-exception: %p -> %p\n", _p(addr), _p(fixup));
+         perfc_incr(exception_fixed);
+     }
+     return fixup;
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_mm_p2m.c
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_mm_p2m.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_arch_x86_mm_p2m.c    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,21 @@
+$NetBSD: patch-xen_arch_x86_mm_p2m.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+silent a noisy warning
+
+--- xen/arch/x86/mm/p2m.c.orig 2020-05-03 21:13:56.173269058 +0200
++++ xen/arch/x86/mm/p2m.c      2020-05-03 21:15:38.477174874 +0200
+@@ -1367,10 +1367,13 @@
+             ret = 0;
+         else
+             ret = -EBUSY;
+-        printk(XENLOG_G_WARNING
++
++      if (gfn_l != mfn_x(mfn)) {
++            printk(XENLOG_G_WARNING
+                "Cannot setup identity map d%d:%lx,"
+                " gfn already mapped to %lx.\n",
+                d->domain_id, gfn_l, mfn_x(mfn));
++      }
+     }
+ 
+     gfn_unlock(p2m, gfn, 0);
Index: pkgsrc/sysutils/xenkernel415/patches/patch-xen_drivers_passthrough_x86_iommu.c
diff -u /dev/null pkgsrc/sysutils/xenkernel415/patches/patch-xen_drivers_passthrough_x86_iommu.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xenkernel415/patches/patch-xen_drivers_passthrough_x86_iommu.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-xen_drivers_passthrough_x86_iommu.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Silent noisy warning
+
+--- xen/drivers/passthrough/x86/iommu.c.orig   2020-12-08 15:28:32.000000000 +0100
++++ xen/drivers/passthrough/x86/iommu.c        2020-12-08 17:32:05.407356434 +0100
+@@ -248,7 +248,7 @@
+             rc = iommu_map(d, _dfn(pfn), _mfn(pfn), 1ul << PAGE_ORDER_4K,
+                            IOMMUF_readable | IOMMUF_writable, &flush_flags);
+ 
+-        if ( rc )
++        if ( rc && (!paging_mode_translate(d) || rc != -16) )
+             printk(XENLOG_WARNING "%pd: identity %smapping of %lx failed: %d\n",
+                    d, !paging_mode_translate(d) ? "IOMMU " : "", pfn, rc);
+ 

Index: pkgsrc/sysutils/xentools415/DESCR
diff -u /dev/null pkgsrc/sysutils/xentools415/DESCR:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/DESCR   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,5 @@
+The Xen virtual machine monitor allows running several virtual machines
+on a single physical machine.  The xentools415 package contains the
+tools to create, destroy and control the virtual machines.
+
+This package contains the tools for Xen 4.15.x
Index: pkgsrc/sysutils/xentools415/MESSAGE
diff -u /dev/null pkgsrc/sysutils/xentools415/MESSAGE:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/MESSAGE Sun Apr 18 12:31:26 2021
@@ -0,0 +1,11 @@
+===========================================================================
+$NetBSD: MESSAGE,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Please note that the xm command has been removed.
+You have to switch to the xl command, which is now functional on NetBSD.
+
+Also note that the rc.d scripts have been updated in this version.
+If you don't use PKG_RCD_SCRIPTS=YES then it is very important for
+you to copy the new rc.d scripts to /etc/rc.d.
+
+===========================================================================
Index: pkgsrc/sysutils/xentools415/MESSAGE.NetBSD
diff -u /dev/null pkgsrc/sysutils/xentools415/MESSAGE.NetBSD:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/MESSAGE.NetBSD  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,25 @@
+===========================================================================
+$NetBSD: MESSAGE.NetBSD,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Please ensure that the Xen-specific devices needed by xend(8) exist:
+
+       cd /dev && sh MAKEDEV xen
+
+There are example configuration files for setting up a guest domain in:
+
+       ${EGDIR}/
+
+Please also refer to the the "NetBSD/xen How-To" for more information on
+creating a Xen setup:
+
+       http://www.NetBSD.org/ports/xen/howto.html
+
+===========================================================================
+WARNING: this version switches from the unmaintained qemu-xen-traditional
+(aka qemu-dm) to qemu-upstream (aka qemu-system-i386, aka qemu-xen).
+To switch back to qemu-xen-traditional add
+device_model_version='qemu-xen-traditional'
+to your HVM domain config file.
+Use of qemu-xen-traditional is deprecated and is not recommened. It may have
+security issues.
+===========================================================================
Index: pkgsrc/sysutils/xentools415/Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/Makefile        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,248 @@
+# $NetBSD: Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+#
+VERSION=       4.15.0
+
+DIST_SUBDIR=           xen415
+DISTNAME=              xen-${VERSION}
+PKGNAME=               xentools415-${VERSION}
+#PKGREVISION=          0
+CATEGORIES=            sysutils
+MASTER_SITES=          https://downloads.xenproject.org/release/xen/${VERSION}/
+
+DISTFILES=             ${DISTNAME}.tar.gz
+
+SEABIOS_VERSION=       1.14.0
+SEABIOS_DIST=          seabios-${SEABIOS_VERSION}.tar.gz
+DISTFILES+=            ${SEABIOS_DIST}
+SITES.${SEABIOS_DIST}= -http://xenbits.xen.org/gitweb/?p=seabios.git;a=snapshot;h=refs/tags/rel-${SEABIOS_VERSION};sf=tgz
+
+IPXE_VERSION=          988d2c13cdf0f0b4140685af35ced70ac5b3283c
+IPXE_DIST=             ipxe-${IPXE_VERSION}.tar.gz
+DISTFILES+=            ${IPXE_DIST}    
+SITES.${IPXE_DIST}=    -https://github.com/ipxe/ipxe/archive/${IPXE_VERSION}.tar.gz
+
+MAINTAINER=            bouyer%NetBSD.org@localhost
+HOMEPAGE=              https://xenproject.org/
+COMMENT=               Userland Tools for Xen 4.15.x
+LICENSE=               gnu-gpl-v2
+
+# XXX add version check: Xen requires dev86 >= 0.16.14
+BUILD_DEPENDS+=        dev86-[0-9]*:../../devel/dev86 # needed to build firmware
+.if !exists(/usr/bin/iasl)
+BUILD_DEPENDS+=        acpica-utils-[0-9]*:../../sysutils/acpica-utils
+.endif
+DEPENDS+=      ${PYPKGPREFIX}-curses>=0:../../devel/py-curses
+
+PKG_SYSCONFSUBDIR=     xen
+
+ONLY_FOR_PLATFORM=     NetBSD-9.99.6[4-9]-x86_64 NetBSD-9.99.[7-9]*-x86_64
+ONLY_FOR_PLATFORM+=    NetBSD-9.[1-9]-x86_64
+ONLY_FOR_PLATFORM+=    NetBSD-9.[1-9]_*-x86_64
+ONLY_FOR_PLATFORM+=    NetBSD-9.0_STABLE-x86_64
+
+SSP_SUPPORTED=         no
+
+CONFLICTS+=            libxen-[0-9]*
+CONFLICTS+=            xenstoretools-[0-9]*
+
+CHECK_PORTABILITY_SKIP=        tools/examples/* \
+                       tools/qemu-xen/scripts/qemu-binfmt-conf.sh
+CHECK_RELRO_SKIP=      libexec/xen/boot/hvmloader
+
+EGDIR=                 ${PREFIX}/share/examples/xen
+MESSAGE_SUBST+=                EGDIR=${EGDIR}
+
+USE_TOOLS+=            pod2man gmake pkg-config makeinfo perl bash cmake gsed bison
+USE_LANGUAGES=         c c++
+
+GNU_CONFIGURE=         YES
+CONFIGURE_ARGS+=       --enable-rpath
+CONFIGURE_ARGS+=       --sysconfdir=${PKG_SYSCONFBASE}
+
+MAKE_ENV+=             PREFIX=${prefix:Q} WRKSRC=${WRKSRC}
+MAKE_ENV+=             APPEND_LIB=${LDFLAGS:Q}
+MAKE_ENV+=             XEN_EXAMPLES_DIR=${EGDIR}
+MAKE_ENV+=             MV=${MV:Q} CP=${CP:Q}
+MAKE_ENV+=             PYTHON=${PYTHONBIN:Q} PYTHON_COMMAND=${PYTHONBIN:Q}
+MAKE_ENV+=             SED=${SED:Q}  
+MAKE_ENV+=             V=YES
+MAKE_ENV+=             BARE_CPP="gcc -E"
+#MAKE_ENV+=            NO_WERROR=1
+
+#BUILDLINK_TRANSFORM+= rm:-Werror
+
+PY_PATCHPLIST=         yes
+REPLACE_PYTHON+=       tools/misc/xencons
+REPLACE_PYTHON+=       tools/misc/xenpvnetboot tools/misc/xensymoops
+REPLACE_PYTHON+=       tools/python/scripts/convert-legacy-stream
+REPLACE_PYTHON+=       tools/python/scripts/verify-stream-v2
+REPLACE_PYTHON+=       tools/xenmon/xenmon.py tools/misc/xencov_split
+
+REPLACE_PERL+=         tools/firmware/rombios/makesym.perl
+REPLACE_PERL+=         tools/qemu-xen-traditional/texi2pod.pl
+REPLACE_PERL+=         tools/examples/xeninfo.pl
+REPLACE_PERL+=         tools/include/xen-external/bsd-sys-queue-h-seddery
+REPLACE_PERL+=         tools/qemu-xen/scripts/texi2pod.pl
+REPLACE_PERL+=         tools/qemu-xen/scripts/get_maintainer.pl
+REPLACE_PERL+=         tools/qemu-xen/scripts/checkpatch.pl
+
+SUBST_CLASSES+=                conf
+SUBST_STAGE.conf=      pre-configure
+SUBST_FILES.conf=      docs/misc/block-scripts.txt
+SUBST_FILES.conf+=     docs/misc/vtd.txt
+SUBST_SED.conf=                -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g"
+
+XEND_SCRIPTS=          block vif-bridge vif-ip qemu-ifup hotplugpath.sh locking.sh
+
+SUBST_CLASSES+=                getopt
+SUBST_STAGE.getopt=    pre-configure
+SUBST_MESSAGE.getopt=  Fixing getopt_long_only
+SUBST_FILES.getopt+=   tools/fuzz/x86_instruction_emulator/afl-harness.c
+SUBST_SED.getopt+=     -e 's,getopt_long_only,getopt_long,'
+
+SUBST_CLASSES+=                rpath-link
+SUBST_STAGE.rpath-link=        pre-configure
+SUBST_MESSAGE.rpath-link= Fixing rpath-link syntax
+SUBST_FILES.rpath-link+= tools/Rules.mk
+SUBST_SED.rpath-link+= -e 's/-rpath-link=/-rpath-link,/g'
+
+OPSYSVARS+=            PROCPATH
+PROCPATH.NetBSD=       /kern
+PROCPATH.*=            /proc
+
+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "NetBSD"
+MESSAGE_SRC=           ${.CURDIR}/MESSAGE ${.CURDIR}/MESSAGE.NetBSD
+.endif
+
+RCD_SCRIPTS=           xen-watchdog xencommons xendomains
+FILES_SUBST+=          RCD_INTERPRETER=${PYTHONBIN:Q}
+FILES_SUBST+=          PROCPATH=${PROCPATH:Q}
+FILES_SUBST+=          PKG_SYSCONFDIR=${PKG_SYSCONFDIR}
+FILES_SUBST+=          PREFIX=${PREFIX}
+
+CONF_FILES+=           ${EGDIR}/xl.conf ${PKG_SYSCONFDIR}/xl.conf
+CONF_FILES+=           ${EGDIR}/oxenstored.conf ${PKG_SYSCONFDIR}/oxenstored.conf
+
+OWN_DIRS=              ${PKG_SYSCONFDIR}/scripts ${VARBASE}/log/xen
+
+.for s in ${XEND_SCRIPTS}
+CONF_FILES_PERMS+=     ${EGDIR}/scripts/${s} ${PKG_SYSCONFDIR}/scripts/${s} \
+                       ${REAL_ROOT_USER} ${REAL_ROOT_GROUP} 0755
+.endfor
+
+pre-build:
+       rm -f ${WRKSRC}/check/check_x11_devel
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xenstore-chmod.1.pod |\
+           pod2man -n xenstore-chmod >${WRKDIR}/xenstore-chmod.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xenstore-ls.1.pod |\
+           pod2man -n xenstore-ls >${WRKDIR}/xenstore-ls.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xenstore.1.pod |\
+           pod2man -n xenstore >${WRKDIR}/xenstore.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xentop.1.pod |\
+           pod2man -n xentop >${WRKDIR}/xentop.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xentrace.8.pod |\
+           pod2man -n xentrace >${WRKDIR}/xentrace.8
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xentrace_format.1.pod |\
+           pod2man -n xenstore_format >${WRKDIR}/xentrace_format.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xl.cfg.5.pod.in |\
+           pod2man -n xl.cfg >${WRKDIR}/xl.cfg.5
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xl.conf.5.pod |\
+           pod2man -n xl.conf >${WRKDIR}/xl.conf.5
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xl.1.pod.in |\
+           pod2man -n xl >${WRKDIR}/xl.1
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xlcpupool.cfg.5.pod |\
+           pod2man -n xlcpupool.cfg >${WRKDIR}/xlcpupool.cfg.5
+       ${SED} -e "s,@XENDCONFDIR@,${PKG_SYSCONFDIR},g" \
+               ${WRKSRC}/docs/man/xl-disk-configuration.5.pod |\
+           pod2man -n xl-disk-configuration >${WRKDIR}/xl-disk-configuration.5
+
+INSTALLATION_DIRS=     ${EGDIR} ${PKGMANDIR}/man1 ${PKGMANDIR}/man5
+INSTALLATION_DIRS+=    ${PKGMANDIR}/man8 share/doc/xen
+
+BUILD_DEFS+=           VARBASE
+
+do-build:
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} build-tools
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} build-docs
+
+do-install:
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} DESTDIR=${DESTDIR} install-tools
+       cd ${WRKSRC} && ${BUILD_MAKE_CMD} DESTDIR=${DESTDIR} install-docs
+
+post-install:
+       ${INSTALL_MAN} ${WRKDIR}/xenstore-chmod.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xenstore-ls.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xenstore.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xentop.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xentrace.8 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8
+       ${INSTALL_MAN} ${WRKDIR}/xentrace_format.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xl.cfg.5 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man5
+       ${INSTALL_MAN} ${WRKDIR}/xl.conf.5 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man5
+       ${INSTALL_MAN} ${WRKDIR}/xl.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
+       ${INSTALL_MAN} ${WRKDIR}/xlcpupool.cfg.5 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man5
+.for f in \
+    gamd-ucode-container.txt       gqemu-backends.txt \
+    gblock-scripts.txt             gqemu-deprivilege.txt \
+    gconsole.txt                   gstubdom.txt \
+    gcrashdb.txt                   gvtd-pi.txt \
+    gdistro_mapping.txt            gvtd.txt \
+    gdump-core-format.txt          gvtpm-platforms.txt \
+    ggrant-tables.txt              gxen-error-handling.txt \
+    gkconfig-language.txt          gxenmon.txt \
+    gkconfig.txt                   gxenpaging.txt \
+    gkexec_and_kdump.txt           gxenstore-ring.txt \
+    glibxl_memory.txt              gxenstore.txt \
+    gprintk-formats.txt            gxsm-flask.txt \
+       ${INSTALL_DATA} ${WRKSRC}/docs/misc/$f ${DESTDIR}${PREFIX}/share/doc/xen
+.endfor
+
+.if (${OPSYS} == "NetBSD" && \
+    (empty(OS_VERSION:M6.99.[3-9]?) && empty(OS_VERSION:M[7-9].*)))
+CPPFLAGS+=     -Dshm_open=open -Dshm_unlink=unlink
+.endif
+
+.include "../../mk/compiler.mk"
+.if !empty(PKGSRC_COMPILER:Mclang)
+EXTRA_HOSTCFLAGS+=     -Wno-error=ignored-attributes
+EXTRA_CFLAGS+= -Wno-error=ignored-attributes -no-integrated-as \
+               -Wno-error=tautological-compare -Wno-error=null-dereference \
+               -Wno-error=empty-body -Wno-error=self-assign \
+               -Wno-error=sometimes-uninitialized \
+               -Wno-error=unused-function -Wno-error=format \
+               -Wno-error=unused-const-variable \
+               -Wno-error=gnu-designator -Wno-error=uninitialized \
+               -Wno-error=parentheses-equality \
+               -Wno-error=enum-conversion \
+               -Wno-error=address-of-packed-member
+BUILDLINK_TRANSFORM+=  rm:-falign-jumps=1 rm:-falign-loops=1 \
+                       rm:-mpreferred-stack-boundary=2
+.endif
+
+MAKE_ENV+=     EXTRA_HOSTCFLAGS=${EXTRA_HOSTCFLAGS:Q} EXTRA_CFLAGS=${EXTRA_CFLAGS:M*:Q} TARGET_CC=${TARGET_CC}
+
+.include "../../lang/python/application.mk"
+.include "../../lang/python/extension.mk"
+#.include "../../devel/SDL/buildlink3.mk"
+.include "../../lang/ocaml/buildlink3.mk"
+.include "../../devel/ocaml-findlib/buildlink3.mk"
+.include "../../sysutils/pciutils/buildlink3.mk"
+.include "../../devel/glib2/buildlink3.mk"
+.include "../../devel/yajl/buildlink3.mk"
+.include "../../devel/argp/buildlink3.mk"
+.include "../../security/libgcrypt/buildlink3.mk"
+.include "../../x11/pixman/buildlink3.mk"
+
+.include "../../mk/curses.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/sysutils/xentools415/PLIST
diff -u /dev/null pkgsrc/sysutils/xentools415/PLIST:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/PLIST   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,825 @@
+@comment $NetBSD: PLIST,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+${PYSITELIB}/grub/ExtLinuxConf.py
+${PYSITELIB}/grub/ExtLinuxConf.pyc
+${PYSITELIB}/grub/GrubConf.py
+${PYSITELIB}/grub/GrubConf.pyc
+${PYSITELIB}/grub/LiloConf.py
+${PYSITELIB}/grub/LiloConf.pyc
+${PYSITELIB}/grub/__init__.py
+${PYSITELIB}/grub/__init__.pyc
+${PYSITELIB}/pygrub-0.6-py${PYVERSSUFFIX}.egg-info
+${PYSITELIB}/xen-3.0-py${PYVERSSUFFIX}.egg-info
+${PYSITELIB}/xen/__init__.py
+${PYSITELIB}/xen/__init__.pyc
+${PYSITELIB}/xen/lowlevel/__init__.py
+${PYSITELIB}/xen/lowlevel/__init__.pyc
+${PYSITELIB}/xen/lowlevel/xc.so
+${PYSITELIB}/xen/lowlevel/xs.so
+${PYSITELIB}/xen/migration/__init__.py
+${PYSITELIB}/xen/migration/__init__.pyc
+${PYSITELIB}/xen/migration/legacy.py
+${PYSITELIB}/xen/migration/legacy.pyc
+${PYSITELIB}/xen/migration/libxc.py
+${PYSITELIB}/xen/migration/libxc.pyc
+${PYSITELIB}/xen/migration/libxl.py
+${PYSITELIB}/xen/migration/libxl.pyc
+${PYSITELIB}/xen/migration/public.py
+${PYSITELIB}/xen/migration/public.pyc
+${PYSITELIB}/xen/migration/tests.py
+${PYSITELIB}/xen/migration/tests.pyc
+${PYSITELIB}/xen/migration/verify.py
+${PYSITELIB}/xen/migration/verify.pyc
+${PYSITELIB}/xen/migration/xl.py
+${PYSITELIB}/xen/migration/xl.pyc
+${PYSITELIB}/xen/util.py
+${PYSITELIB}/xen/util.pyc
+${PYSITELIB}/xenfsimage.so
+bin/pygrub
+bin/qemu-img-xen
+bin/xen-cpuid
+bin/xen-detect
+bin/xenalyze
+bin/xencons
+bin/xencov_split
+bin/xenstore
+bin/xenstore-chmod
+bin/xenstore-control
+bin/xenstore-exists
+bin/xenstore-list
+bin/xenstore-ls
+bin/xenstore-read
+bin/xenstore-rm
+bin/xenstore-watch
+bin/xenstore-write
+bin/xentrace_format
+include/_libxl_list.h
+include/_libxl_types.h
+include/_libxl_types_json.h
+include/libxl.h
+include/libxl_event.h
+include/libxl_json.h
+include/libxl_utils.h
+include/libxl_uuid.h
+include/libxlutil.h
+include/xen/COPYING
+include/xen/arch-arm.h
+include/xen/arch-arm/hvm/save.h
+include/xen/arch-arm/smccc.h
+include/xen/arch-x86/cpufeatureset.h
+include/xen/arch-x86/cpuid.h
+include/xen/arch-x86/hvm/save.h
+include/xen/arch-x86/hvm/start_info.h
+include/xen/arch-x86/pmu.h
+include/xen/arch-x86/xen-mca.h
+include/xen/arch-x86/xen-x86_32.h
+include/xen/arch-x86/xen-x86_64.h
+include/xen/arch-x86/xen.h
+include/xen/arch-x86_32.h
+include/xen/arch-x86_64.h
+include/xen/argo.h
+include/xen/callback.h
+include/xen/device_tree_defs.h
+include/xen/dom0_ops.h
+include/xen/domctl.h
+include/xen/elfnote.h
+include/xen/errno.h
+include/xen/event_channel.h
+include/xen/features.h
+include/xen/foreign/arm32.h
+include/xen/foreign/arm64.h
+include/xen/foreign/x86_32.h
+include/xen/foreign/x86_64.h
+include/xen/grant_table.h
+include/xen/hvm/dm_op.h
+include/xen/hvm/e820.h
+include/xen/hvm/hvm_info_table.h
+include/xen/hvm/hvm_op.h
+include/xen/hvm/hvm_vcpu.h
+include/xen/hvm/hvm_xs_strings.h
+include/xen/hvm/ioreq.h
+include/xen/hvm/params.h
+include/xen/hvm/pvdrivers.h
+include/xen/hvm/save.h
+include/xen/hypfs.h
+include/xen/io/9pfs.h
+include/xen/io/blkif.h
+include/xen/io/cameraif.h
+include/xen/io/console.h
+include/xen/io/displif.h
+include/xen/io/fbif.h
+include/xen/io/fsif.h
+include/xen/io/kbdif.h
+include/xen/io/libxenvchan.h
+include/xen/io/netif.h
+include/xen/io/pciif.h
+include/xen/io/protocols.h
+include/xen/io/pvcalls.h
+include/xen/io/ring.h
+include/xen/io/sndif.h
+include/xen/io/tpmif.h
+include/xen/io/usbif.h
+include/xen/io/vscsiif.h
+include/xen/io/xenbus.h
+include/xen/io/xs_wire.h
+include/xen/kexec.h
+include/xen/memory.h
+include/xen/nmi.h
+include/xen/physdev.h
+include/xen/platform.h
+include/xen/pmu.h
+include/xen/sched.h
+include/xen/sysctl.h
+include/xen/sys/evtchn.h
+include/xen/sys/privcmd.h
+include/xen/tmem.h
+include/xen/trace.h
+include/xen/vcpu.h
+include/xen/version.h
+include/xen/vm_event.h
+include/xen/xen-compat.h
+include/xen/xen.h
+include/xen/xencomm.h
+include/xen/xenoprof.h
+include/xen/xsm/flask_op.h
+include/xencall.h
+include/xenctrl.h
+include/xenctrl_compat.h
+include/xendevicemodel.h
+include/xenevtchn.h
+include/xenforeignmemory.h
+include/xenfsimage.h
+include/xenfsimage_grub.h
+include/xenfsimage_plugin.h
+include/xengnttab.h
+include/xenguest.h
+include/xenhypfs.h
+include/xenstat.h
+include/xenstore-compat/xs.h
+include/xenstore-compat/xs_lib.h
+include/xenstore.h
+include/xenstore_lib.h
+include/xentoolcore.h
+include/xentoolcore_internal.h
+include/xentoollog.h
+include/xs.h
+include/xs_lib.h
+lib/debug${LOCALBASE}/libexec/xen/boot/xen-shim-syms
+lib/libxencall.a
+lib/libxencall.so
+lib/libxencall.so.1
+lib/libxencall.so.1.2
+lib/libxenctrl.a
+lib/libxenctrl.so
+lib/libxenctrl.so.4.15
+lib/libxenctrl.so.4.15.0
+lib/libxendevicemodel.a
+lib/libxendevicemodel.so
+lib/libxendevicemodel.so.1
+lib/libxendevicemodel.so.1.4
+lib/libxenevtchn.a
+lib/libxenevtchn.so
+lib/libxenevtchn.so.1
+lib/libxenevtchn.so.1.2
+lib/libxenforeignmemory.a
+lib/libxenforeignmemory.so
+lib/libxenforeignmemory.so.1
+lib/libxenforeignmemory.so.1.4
+lib/libxenfsimage.so
+lib/libxenfsimage.so.4.15
+lib/libxenfsimage.so.4.15.0
+lib/libxengnttab.a
+lib/libxengnttab.so
+lib/libxengnttab.so.1
+lib/libxengnttab.so.1.2
+lib/libxenguest.a
+lib/libxenguest.so
+lib/libxenguest.so.4.15
+lib/libxenguest.so.4.15.0
+lib/libxenhypfs.a
+lib/libxenhypfs.so
+lib/libxenhypfs.so.1
+lib/libxenhypfs.so.1.0
+lib/libxenlight.a
+lib/libxenlight.so
+lib/libxenlight.so.4.15
+lib/libxenlight.so.4.15.0
+lib/libxenstat.a
+lib/libxenstat.so
+lib/libxenstat.so.4.15
+lib/libxenstat.so.4.15.0
+lib/libxenstore.a
+lib/libxenstore.so
+lib/libxenstore.so.3.0
+lib/libxenstore.so.3.0.3
+lib/libxentoolcore.a
+lib/libxentoolcore.so
+lib/libxentoolcore.so.1
+lib/libxentoolcore.so.1.0
+lib/libxentoollog.a
+lib/libxentoollog.so
+lib/libxentoollog.so.1
+lib/libxentoollog.so.1.0
+lib/libxlutil.a
+lib/libxlutil.so
+lib/libxlutil.so.4.15
+lib/libxlutil.so.4.15.0
+lib/ocaml/site-lib/xenbus/META
+lib/ocaml/site-lib/xenbus/dllxenbus_stubs.so
+lib/ocaml/site-lib/xenbus/libxenbus_stubs.a
+lib/ocaml/site-lib/xenbus/xenbus.a
+lib/ocaml/site-lib/xenbus/xenbus.cma
+lib/ocaml/site-lib/xenbus/xenbus.cmi
+lib/ocaml/site-lib/xenbus/xenbus.cmo
+lib/ocaml/site-lib/xenbus/xenbus.cmx
+lib/ocaml/site-lib/xenbus/xenbus.cmxa
+lib/ocaml/site-lib/xenctrl/META
+lib/ocaml/site-lib/xenctrl/dllxenctrl_stubs.so
+lib/ocaml/site-lib/xenctrl/libxenctrl_stubs.a
+lib/ocaml/site-lib/xenctrl/xenctrl.a
+lib/ocaml/site-lib/xenctrl/xenctrl.cma
+lib/ocaml/site-lib/xenctrl/xenctrl.cmi
+lib/ocaml/site-lib/xenctrl/xenctrl.cmx
+lib/ocaml/site-lib/xenctrl/xenctrl.cmxa
+lib/ocaml/site-lib/xeneventchn/META
+lib/ocaml/site-lib/xeneventchn/dllxeneventchn_stubs.so
+lib/ocaml/site-lib/xeneventchn/libxeneventchn_stubs.a
+lib/ocaml/site-lib/xeneventchn/xeneventchn.a
+lib/ocaml/site-lib/xeneventchn/xeneventchn.cma
+lib/ocaml/site-lib/xeneventchn/xeneventchn.cmi
+lib/ocaml/site-lib/xeneventchn/xeneventchn.cmx
+lib/ocaml/site-lib/xeneventchn/xeneventchn.cmxa
+lib/ocaml/site-lib/xenlight/META
+lib/ocaml/site-lib/xenlight/dllxenlight_stubs.so
+lib/ocaml/site-lib/xenlight/libxenlight_stubs.a
+lib/ocaml/site-lib/xenlight/xenlight.a
+lib/ocaml/site-lib/xenlight/xenlight.cma
+lib/ocaml/site-lib/xenlight/xenlight.cmi
+lib/ocaml/site-lib/xenlight/xenlight.cmx
+lib/ocaml/site-lib/xenlight/xenlight.cmxa
+lib/ocaml/site-lib/xenmmap/META
+lib/ocaml/site-lib/xenmmap/dllxenmmap_stubs.so
+lib/ocaml/site-lib/xenmmap/libxenmmap_stubs.a
+lib/ocaml/site-lib/xenmmap/xenmmap.a
+lib/ocaml/site-lib/xenmmap/xenmmap.cma
+lib/ocaml/site-lib/xenmmap/xenmmap.cmi
+lib/ocaml/site-lib/xenmmap/xenmmap.cmx
+lib/ocaml/site-lib/xenmmap/xenmmap.cmxa
+lib/ocaml/site-lib/xenstore/META
+lib/ocaml/site-lib/xenstore/xenstore.a
+lib/ocaml/site-lib/xenstore/xenstore.cma
+lib/ocaml/site-lib/xenstore/xenstore.cmi
+lib/ocaml/site-lib/xenstore/xenstore.cmo
+lib/ocaml/site-lib/xenstore/xenstore.cmx
+lib/ocaml/site-lib/xenstore/xenstore.cmxa
+lib/ocaml/site-lib/xentoollog/META
+lib/ocaml/site-lib/xentoollog/dllxentoollog_stubs.so
+lib/ocaml/site-lib/xentoollog/libxentoollog_stubs.a
+lib/ocaml/site-lib/xentoollog/xentoollog.a
+lib/ocaml/site-lib/xentoollog/xentoollog.cma
+lib/ocaml/site-lib/xentoollog/xentoollog.cmi
+lib/ocaml/site-lib/xentoollog/xentoollog.cmx
+lib/ocaml/site-lib/xentoollog/xentoollog.cmxa
+lib/pkgconfig/xencall.pc
+lib/pkgconfig/xencontrol.pc
+lib/pkgconfig/xendevicemodel.pc
+lib/pkgconfig/xenevtchn.pc
+lib/pkgconfig/xenforeignmemory.pc
+lib/pkgconfig/xengnttab.pc
+lib/pkgconfig/xenguest.pc
+lib/pkgconfig/xenhypfs.pc
+lib/pkgconfig/xenlight.pc
+lib/pkgconfig/xenstat.pc
+lib/pkgconfig/xenstore.pc
+lib/pkgconfig/xentoolcore.pc
+lib/pkgconfig/xentoollog.pc
+lib/pkgconfig/xlutil.pc
+lib/xenfsimage/ext2fs/fsimage.so
+lib/xenfsimage/fat/fsimage.so
+lib/xenfsimage/iso9660/fsimage.so
+lib/xenfsimage/reiserfs/fsimage.so
+lib/xenfsimage/ufs/fsimage.so
+lib/xenfsimage/xfs/fsimage.so
+lib/xenfsimage/zfs/fsimage.so
+libexec/xen/bin/convert-legacy-stream
+libexec/xen/bin/libxl-save-helper
+libexec/xen/bin/lsevtchn
+libexec/xen/bin/pygrub
+libexec/xen/bin/qemu-dm
+libexec/xen/bin/qemu-edid
+libexec/xen/bin/qemu-img
+libexec/xen/bin/qemu-io
+libexec/xen/bin/qemu-nbd
+libexec/xen/bin/qemu-storage-daemon
+libexec/xen/bin/qemu-system-i386
+libexec/xen/bin/readnotes
+libexec/xen/bin/verify-stream-v2
+libexec/xen/bin/xen-init-dom0
+libexec/xen/bin/xenconsole
+libexec/xen/bin/xenctx
+libexec/xen/bin/xenpaging
+libexec/xen/bin/xenpvnetboot
+libexec/xen/boot/hvmloader
+libexec/xen/boot/ipxe.bin
+libexec/xen/boot/seabios.bin
+libexec/xen/boot/xen-shim
+man/man1/xenhypfs.1
+man/man1/xenstore-chmod.1
+man/man1/xenstore-ls.1
+man/man1/xenstore-read.1
+man/man1/xenstore-write.1
+man/man1/xenstore.1
+man/man1/xentop.1
+man/man1/xentrace_format.1
+man/man1/xl.1
+man/man5/xl-disk-configuration.5
+man/man5/xl-network-configuration.5
+man/man5/xl-pci-configuration.5
+man/man5/xl.cfg.5
+man/man5/xl.conf.5
+man/man5/xlcpupool.cfg.5
+man/man7/xen-pci-device-reservations.7
+man/man7/xen-pv-channel.7
+man/man7/xen-tscmode.7
+man/man7/xen-vtpm.7
+man/man7/xen-vtpmmgr.7
+man/man7/xl-numa-placement.7
+man/man8/xentrace.8
+sbin/flask-get-bool
+sbin/flask-getenforce
+sbin/flask-label-pci
+sbin/flask-loadpolicy
+sbin/flask-set-bool
+sbin/flask-setenforce
+sbin/gdbsx
+sbin/oxenstored
+sbin/xen-access
+sbin/xen-diag
+sbin/xen-hptool
+sbin/xen-hvmcrash
+sbin/xen-hvmctx
+sbin/xen-kdd
+sbin/xen-livepatch
+sbin/xen-lowmemd
+sbin/xen-memshare
+sbin/xen-mfndump
+sbin/xen-ucode
+sbin/xenbaked
+sbin/xenconsoled
+sbin/xencov
+sbin/xenhypfs
+sbin/xenlockprof
+sbin/xenmon
+sbin/xenperf
+sbin/xenpm
+sbin/xenpmd
+sbin/xenstored
+sbin/xentop
+sbin/xentrace
+sbin/xentrace_setmask
+sbin/xentrace_setsize
+sbin/xenwatchdogd
+sbin/xl
+share/doc/xen/html/hypercall/arm/.deps
+share/doc/xen/html/hypercall/arm/include,public,arch-arm,hvm,save.h.html
+share/doc/xen/html/hypercall/arm/include,public,arch-arm,smccc.h.html
+share/doc/xen/html/hypercall/arm/include,public,arch-arm.h.html
+share/doc/xen/html/hypercall/arm/include,public,argo.h.html
+share/doc/xen/html/hypercall/arm/include,public,callback.h.html
+share/doc/xen/html/hypercall/arm/include,public,device_tree_defs.h.html
+share/doc/xen/html/hypercall/arm/include,public,dom0_ops.h.html
+share/doc/xen/html/hypercall/arm/include,public,domctl.h.html
+share/doc/xen/html/hypercall/arm/include,public,elfnote.h.html
+share/doc/xen/html/hypercall/arm/include,public,errno.h.html
+share/doc/xen/html/hypercall/arm/include,public,event_channel.h.html
+share/doc/xen/html/hypercall/arm/include,public,features.h.html
+share/doc/xen/html/hypercall/arm/include,public,grant_table.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,dm_op.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,e820.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,hvm_info_table.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,hvm_op.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,hvm_vcpu.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,hvm_xs_strings.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,ioreq.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,params.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,pvdrivers.h.html
+share/doc/xen/html/hypercall/arm/include,public,hvm,save.h.html
+share/doc/xen/html/hypercall/arm/include,public,hypfs.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,9pfs.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,blkif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,cameraif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,console.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,displif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,fbif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,fsif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,kbdif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,libxenvchan.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,netif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,pciif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,protocols.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,pvcalls.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,ring.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,sndif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,tpmif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,usbif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,vscsiif.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,xenbus.h.html
+share/doc/xen/html/hypercall/arm/include,public,io,xs_wire.h.html
+share/doc/xen/html/hypercall/arm/include,public,kexec.h.html
+share/doc/xen/html/hypercall/arm/include,public,memory.h.html
+share/doc/xen/html/hypercall/arm/include,public,nmi.h.html
+share/doc/xen/html/hypercall/arm/include,public,physdev.h.html
+share/doc/xen/html/hypercall/arm/include,public,platform.h.html
+share/doc/xen/html/hypercall/arm/include,public,pmu.h.html
+share/doc/xen/html/hypercall/arm/include,public,sched.h.html
+share/doc/xen/html/hypercall/arm/include,public,sysctl.h.html
+share/doc/xen/html/hypercall/arm/include,public,tmem.h.html
+share/doc/xen/html/hypercall/arm/include,public,trace.h.html
+share/doc/xen/html/hypercall/arm/include,public,vcpu.h.html
+share/doc/xen/html/hypercall/arm/include,public,version.h.html
+share/doc/xen/html/hypercall/arm/include,public,vm_event.h.html
+share/doc/xen/html/hypercall/arm/include,public,xen-compat.h.html
+share/doc/xen/html/hypercall/arm/include,public,xen.h.html
+share/doc/xen/html/hypercall/arm/include,public,xencomm.h.html
+share/doc/xen/html/hypercall/arm/include,public,xenoprof.h.html
+share/doc/xen/html/hypercall/arm/include,public,xsm,flask_op.h.html
+share/doc/xen/html/hypercall/arm/include,xen,errno.h.html
+share/doc/xen/html/hypercall/arm/index.html
+share/doc/xen/html/hypercall/index.html
+share/doc/xen/html/hypercall/x86_32/.deps
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,cpufeatureset.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,cpuid.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,hvm,save.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,hvm,start_info.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,pmu.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,xen-mca.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,xen-x86_32.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86,xen.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,arch-x86_32.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,argo.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,callback.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,device_tree_defs.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,dom0_ops.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,domctl.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,elfnote.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,errno.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,event_channel.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,features.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,grant_table.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,dm_op.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,e820.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,hvm_info_table.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,hvm_op.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,hvm_vcpu.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,hvm_xs_strings.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,ioreq.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,params.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,pvdrivers.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hvm,save.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,hypfs.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,9pfs.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,blkif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,cameraif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,console.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,displif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,fbif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,fsif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,kbdif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,libxenvchan.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,netif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,pciif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,protocols.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,pvcalls.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,ring.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,sndif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,tpmif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,usbif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,vscsiif.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,xenbus.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,io,xs_wire.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,kexec.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,memory.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,nmi.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,physdev.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,platform.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,pmu.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,sched.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,sysctl.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,tmem.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,trace.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,vcpu.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,version.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,vm_event.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,xen-compat.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,xen.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,xencomm.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,xenoprof.h.html
+share/doc/xen/html/hypercall/x86_32/include,public,xsm,flask_op.h.html
+share/doc/xen/html/hypercall/x86_32/include,xen,errno.h.html
+share/doc/xen/html/hypercall/x86_32/index.html
+share/doc/xen/html/hypercall/x86_64/.deps
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,cpufeatureset.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,cpuid.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,hvm,save.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,hvm,start_info.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,pmu.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,xen-mca.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,xen-x86_64.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86,xen.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,arch-x86_64.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,argo.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,callback.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,device_tree_defs.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,dom0_ops.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,domctl.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,elfnote.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,errno.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,event_channel.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,features.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,grant_table.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,dm_op.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,e820.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,hvm_info_table.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,hvm_op.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,hvm_vcpu.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,hvm_xs_strings.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,ioreq.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,params.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,pvdrivers.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hvm,save.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,hypfs.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,9pfs.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,blkif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,cameraif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,console.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,displif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,fbif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,fsif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,kbdif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,libxenvchan.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,netif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,pciif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,protocols.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,pvcalls.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,ring.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,sndif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,tpmif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,usbif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,vscsiif.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,xenbus.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,io,xs_wire.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,kexec.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,memory.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,nmi.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,physdev.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,platform.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,pmu.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,sched.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,sysctl.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,tmem.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,trace.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,vcpu.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,version.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,vm_event.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,xen-compat.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,xen.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,xencomm.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,xenoprof.h.html
+share/doc/xen/html/hypercall/x86_64/include,public,xsm,flask_op.h.html
+share/doc/xen/html/hypercall/x86_64/include,xen,errno.h.html
+share/doc/xen/html/hypercall/x86_64/index.html
+share/doc/xen/html/index.html
+share/doc/xen/html/man/index.html
+share/doc/xen/html/man/xen-pci-device-reservations.7.html
+share/doc/xen/html/man/xen-pv-channel.7.html
+share/doc/xen/html/man/xen-tscmode.7.html
+share/doc/xen/html/man/xen-vtpm.7.html
+share/doc/xen/html/man/xen-vtpmmgr.7.html
+share/doc/xen/html/man/xenhypfs.1.html
+share/doc/xen/html/man/xenstore-chmod.1.html
+share/doc/xen/html/man/xenstore-ls.1.html
+share/doc/xen/html/man/xenstore-read.1.html
+share/doc/xen/html/man/xenstore-write.1.html
+share/doc/xen/html/man/xenstore.1.html
+share/doc/xen/html/man/xentop.1.html
+share/doc/xen/html/man/xentrace.8.html
+share/doc/xen/html/man/xentrace_format.1.html
+share/doc/xen/html/man/xl-disk-configuration.5.html
+share/doc/xen/html/man/xl-network-configuration.5.html
+share/doc/xen/html/man/xl-numa-placement.7.html
+share/doc/xen/html/man/xl-pci-configuration.5.html
+share/doc/xen/html/man/xl.1.html
+share/doc/xen/html/man/xl.cfg.5.html
+share/doc/xen/html/man/xl.conf.5.html
+share/doc/xen/html/man/xlcpupool.cfg.5.html
+share/doc/xen/html/misc/amd-ucode-container.txt
+share/doc/xen/html/misc/arm/big.LITTLE.txt
+share/doc/xen/html/misc/arm/booting.txt
+share/doc/xen/html/misc/arm/device-tree/acpi.txt
+share/doc/xen/html/misc/arm/device-tree/booting.txt
+share/doc/xen/html/misc/arm/device-tree/guest.txt
+share/doc/xen/html/misc/arm/device-tree/index.html
+share/doc/xen/html/misc/arm/device-tree/passthrough.txt
+share/doc/xen/html/misc/arm/early-printk.txt
+share/doc/xen/html/misc/arm/index.html
+share/doc/xen/html/misc/arm/passthrough.txt
+share/doc/xen/html/misc/arm/silicon-errata.txt
+share/doc/xen/html/misc/block-scripts.txt
+share/doc/xen/html/misc/console.txt
+share/doc/xen/html/misc/crashdb.txt
+share/doc/xen/html/misc/distro_mapping.txt
+share/doc/xen/html/misc/dump-core-format.txt
+share/doc/xen/html/misc/grant-tables.txt
+share/doc/xen/html/misc/index.html
+share/doc/xen/html/misc/kexec_and_kdump.txt
+share/doc/xen/html/misc/libxl_memory.txt
+share/doc/xen/html/misc/printk-formats.txt
+share/doc/xen/html/misc/qemu-backends.txt
+share/doc/xen/html/misc/stubdom.txt
+share/doc/xen/html/misc/vtd-pi.txt
+share/doc/xen/html/misc/vtd.txt
+share/doc/xen/html/misc/vtpm-platforms.txt
+share/doc/xen/html/misc/xen-error-handling.txt
+share/doc/xen/html/misc/xenmon.txt
+share/doc/xen/html/misc/xenpaging.txt
+share/doc/xen/html/misc/xenstore-ring.txt
+share/doc/xen/html/misc/xenstore.txt
+share/doc/xen/html/misc/xsm-flask.txt
+share/examples/xen/README
+share/examples/xen/cpupool
+share/examples/xen/oxenstored.conf
+share/examples/xen/scripts/block
+share/examples/xen/scripts/hotplugpath.sh
+share/examples/xen/scripts/locking.sh
+share/examples/xen/scripts/qemu-ifup
+share/examples/xen/scripts/vif-bridge
+share/examples/xen/scripts/vif-ip
+share/examples/xen/xl.bash
+share/examples/xen/xl.conf
+share/examples/xen/xlexample.hvm
+share/examples/xen/xlexample.pvhlinux
+share/examples/xen/xlexample.pvlinux
+share/qemu-xen/applications/qemu.desktop
+share/qemu-xen/icons/hicolor/128x128/apps/qemu.png
+share/qemu-xen/icons/hicolor/16x16/apps/qemu.png
+share/qemu-xen/icons/hicolor/24x24/apps/qemu.png
+share/qemu-xen/icons/hicolor/256x256/apps/qemu.png
+share/qemu-xen/icons/hicolor/32x32/apps/qemu.bmp
+share/qemu-xen/icons/hicolor/32x32/apps/qemu.png
+share/qemu-xen/icons/hicolor/48x48/apps/qemu.png
+share/qemu-xen/icons/hicolor/512x512/apps/qemu.png
+share/qemu-xen/icons/hicolor/64x64/apps/qemu.png
+share/qemu-xen/icons/hicolor/scalable/apps/qemu.svg
+share/qemu-xen/qemu/QEMU,cgthree.bin
+share/qemu-xen/qemu/QEMU,tcx.bin
+share/qemu-xen/qemu/bamboo.dtb
+share/qemu-xen/qemu/bios-256k.bin
+share/qemu-xen/qemu/bios-microvm.bin
+share/qemu-xen/qemu/bios.bin
+share/qemu-xen/qemu/canyonlands.dtb
+share/qemu-xen/qemu/edk2-aarch64-code.fd
+share/qemu-xen/qemu/edk2-arm-code.fd
+share/qemu-xen/qemu/edk2-arm-vars.fd
+share/qemu-xen/qemu/edk2-i386-code.fd
+share/qemu-xen/qemu/edk2-i386-secure-code.fd
+share/qemu-xen/qemu/edk2-i386-vars.fd
+share/qemu-xen/qemu/edk2-licenses.txt
+share/qemu-xen/qemu/edk2-x86_64-code.fd
+share/qemu-xen/qemu/edk2-x86_64-secure-code.fd
+share/qemu-xen/qemu/efi-e1000.rom
+share/qemu-xen/qemu/efi-e1000e.rom
+share/qemu-xen/qemu/efi-eepro100.rom
+share/qemu-xen/qemu/efi-ne2k_pci.rom
+share/qemu-xen/qemu/efi-pcnet.rom
+share/qemu-xen/qemu/efi-rtl8139.rom
+share/qemu-xen/qemu/efi-virtio.rom
+share/qemu-xen/qemu/efi-vmxnet3.rom
+share/qemu-xen/qemu/firmware/50-edk2-i386-secure.json
+share/qemu-xen/qemu/firmware/50-edk2-x86_64-secure.json
+share/qemu-xen/qemu/firmware/60-edk2-aarch64.json
+share/qemu-xen/qemu/firmware/60-edk2-arm.json
+share/qemu-xen/qemu/firmware/60-edk2-i386.json
+share/qemu-xen/qemu/firmware/60-edk2-x86_64.json
+share/qemu-xen/qemu/hppa-firmware.img
+share/qemu-xen/qemu/keymaps/ar
+share/qemu-xen/qemu/keymaps/bepo
+share/qemu-xen/qemu/keymaps/cz
+share/qemu-xen/qemu/keymaps/da
+share/qemu-xen/qemu/keymaps/de
+share/qemu-xen/qemu/keymaps/de-ch
+share/qemu-xen/qemu/keymaps/en-gb
+share/qemu-xen/qemu/keymaps/en-us
+share/qemu-xen/qemu/keymaps/es
+share/qemu-xen/qemu/keymaps/et
+share/qemu-xen/qemu/keymaps/fi
+share/qemu-xen/qemu/keymaps/fo
+share/qemu-xen/qemu/keymaps/fr
+share/qemu-xen/qemu/keymaps/fr-be
+share/qemu-xen/qemu/keymaps/fr-ca
+share/qemu-xen/qemu/keymaps/fr-ch
+share/qemu-xen/qemu/keymaps/hr
+share/qemu-xen/qemu/keymaps/hu
+share/qemu-xen/qemu/keymaps/is
+share/qemu-xen/qemu/keymaps/it
+share/qemu-xen/qemu/keymaps/ja
+share/qemu-xen/qemu/keymaps/lt
+share/qemu-xen/qemu/keymaps/lv
+share/qemu-xen/qemu/keymaps/mk
+share/qemu-xen/qemu/keymaps/nl
+share/qemu-xen/qemu/keymaps/no
+share/qemu-xen/qemu/keymaps/pl
+share/qemu-xen/qemu/keymaps/pt
+share/qemu-xen/qemu/keymaps/pt-br
+share/qemu-xen/qemu/keymaps/ru
+share/qemu-xen/qemu/keymaps/sl
+share/qemu-xen/qemu/keymaps/sv
+share/qemu-xen/qemu/keymaps/th
+share/qemu-xen/qemu/keymaps/tr
+share/qemu-xen/qemu/kvmvapic.bin
+share/qemu-xen/qemu/linuxboot.bin
+share/qemu-xen/qemu/linuxboot_dma.bin
+share/qemu-xen/qemu/multiboot.bin
+share/qemu-xen/qemu/openbios-ppc
+share/qemu-xen/qemu/openbios-sparc32
+share/qemu-xen/qemu/openbios-sparc64
+share/qemu-xen/qemu/opensbi-riscv32-sifive_u-fw_jump.bin
+share/qemu-xen/qemu/opensbi-riscv32-virt-fw_jump.bin
+share/qemu-xen/qemu/opensbi-riscv64-sifive_u-fw_jump.bin
+share/qemu-xen/qemu/opensbi-riscv64-virt-fw_jump.bin
+share/qemu-xen/qemu/palcode-clipper
+share/qemu-xen/qemu/petalogix-ml605.dtb
+share/qemu-xen/qemu/petalogix-s3adsp1800.dtb
+share/qemu-xen/qemu/pvh.bin
+share/qemu-xen/qemu/pxe-e1000.rom
+share/qemu-xen/qemu/pxe-eepro100.rom
+share/qemu-xen/qemu/pxe-ne2k_pci.rom
+share/qemu-xen/qemu/pxe-pcnet.rom
+share/qemu-xen/qemu/pxe-rtl8139.rom
+share/qemu-xen/qemu/pxe-virtio.rom
+share/qemu-xen/qemu/qemu-nsis.bmp
+share/qemu-xen/qemu/qemu_vga.ndrv
+share/qemu-xen/qemu/s390-ccw.img
+share/qemu-xen/qemu/s390-netboot.img
+share/qemu-xen/qemu/sgabios.bin
+share/qemu-xen/qemu/skiboot.lid
+share/qemu-xen/qemu/slof.bin
+share/qemu-xen/qemu/trace-events-all
+share/qemu-xen/qemu/u-boot-sam460-20100605.bin
+share/qemu-xen/qemu/u-boot.e500
+share/qemu-xen/qemu/vgabios-ati.bin
+share/qemu-xen/qemu/vgabios-bochs-display.bin
+share/qemu-xen/qemu/vgabios-cirrus.bin
+share/qemu-xen/qemu/vgabios-qxl.bin
+share/qemu-xen/qemu/vgabios-ramfb.bin
+share/qemu-xen/qemu/vgabios-stdvga.bin
+share/qemu-xen/qemu/vgabios-virtio.bin
+share/qemu-xen/qemu/vgabios-vmware.bin
+share/qemu-xen/qemu/vgabios.bin
+share/xen/qemu/bamboo.dtb
+share/xen/qemu/bios.bin
+share/xen/qemu/keymaps/ar
+share/xen/qemu/keymaps/common
+share/xen/qemu/keymaps/da
+share/xen/qemu/keymaps/de
+share/xen/qemu/keymaps/de-ch
+share/xen/qemu/keymaps/en-gb
+share/xen/qemu/keymaps/en-us
+share/xen/qemu/keymaps/es
+share/xen/qemu/keymaps/et
+share/xen/qemu/keymaps/fi
+share/xen/qemu/keymaps/fo
+share/xen/qemu/keymaps/fr
+share/xen/qemu/keymaps/fr-be
+share/xen/qemu/keymaps/fr-ca
+share/xen/qemu/keymaps/fr-ch
+share/xen/qemu/keymaps/hr
+share/xen/qemu/keymaps/hu
+share/xen/qemu/keymaps/is
+share/xen/qemu/keymaps/it
+share/xen/qemu/keymaps/ja
+share/xen/qemu/keymaps/lt
+share/xen/qemu/keymaps/lv
+share/xen/qemu/keymaps/mk
+share/xen/qemu/keymaps/modifiers
+share/xen/qemu/keymaps/nl
+share/xen/qemu/keymaps/nl-be
+share/xen/qemu/keymaps/no
+share/xen/qemu/keymaps/pl
+share/xen/qemu/keymaps/pt
+share/xen/qemu/keymaps/pt-br
+share/xen/qemu/keymaps/ru
+share/xen/qemu/keymaps/sl
+share/xen/qemu/keymaps/sv
+share/xen/qemu/keymaps/th
+share/xen/qemu/keymaps/tr
+share/xen/qemu/openbios-ppc
+share/xen/qemu/openbios-sparc32
+share/xen/qemu/openbios-sparc64
+share/xen/qemu/ppc_rom.bin
+share/xen/qemu/pxe-e1000.bin
+share/xen/qemu/pxe-ne2k_pci.bin
+share/xen/qemu/pxe-pcnet.bin
+share/xen/qemu/pxe-rtl8139.bin
+share/xen/qemu/vgabios-cirrus.bin
+share/xen/qemu/vgabios.bin
+share/xen/qemu/video.x
+@pkgdir share/examples/xen/auto
Index: pkgsrc/sysutils/xentools415/distinfo
diff -u /dev/null pkgsrc/sysutils/xentools415/distinfo:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/distinfo        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,72 @@
+$NetBSD: distinfo,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+SHA1 (xen415/ipxe-988d2c13cdf0f0b4140685af35ced70ac5b3283c.tar.gz) = 062f21086b853150eddb8cbae31f3f65b9df5520
+RMD160 (xen415/ipxe-988d2c13cdf0f0b4140685af35ced70ac5b3283c.tar.gz) = accba07024249a41f62731e4ff9f0dd9b45a7345
+SHA512 (xen415/ipxe-988d2c13cdf0f0b4140685af35ced70ac5b3283c.tar.gz) = d888e0e653727ee9895fa866d8895e6d23a568b4e9e8439db4c4d790996700c60b0655e3a3129e599736ec2b4f7b987ce79d625ba208f06665fced8bddf94403
+Size (xen415/ipxe-988d2c13cdf0f0b4140685af35ced70ac5b3283c.tar.gz) = 3937560 bytes
+SHA1 (xen415/seabios-1.14.0.tar.gz) = 254e4de7194932fc55afea9237cfa7822895bfb6
+RMD160 (xen415/seabios-1.14.0.tar.gz) = deb7b18529820fa03fb892c0d338a5293a17e32b
+SHA512 (xen415/seabios-1.14.0.tar.gz) = f282175484c99488f4349ff4d3af9a74d96df3e8dcbe679fcea5b8b559f95f600756939d99d6e61dabace206d3d9ccefdc8fa2bc7709d34d6a0dc085d6c79238
+Size (xen415/seabios-1.14.0.tar.gz) = 628981 bytes
+SHA1 (xen415/xen-4.15.0.tar.gz) = 4ea99cf3063db822dfbaf971bf8e9d50828d485a
+RMD160 (xen415/xen-4.15.0.tar.gz) = e314791e29244da385e482166776641929babad3
+SHA512 (xen415/xen-4.15.0.tar.gz) = 93683b8a97387ca5f003c635a11d163e61c87dbdc9a03081f9155fe87b49f1dfa74ce243fcd5e04dc009353a36e2375b786f1ebde828b5951a094cd64197b4c7
+Size (xen415/xen-4.15.0.tar.gz) = 40785399 bytes
+SHA1 (patch-.._seabios-rel-1.14.0_src_string.c) = 87e2e28fe47c196e74fea073c7e7f7d03990fbe3
+SHA1 (patch-Config.mk) = d108a1743b5b5313d3ea957b02a005b49f5b3bf6
+SHA1 (patch-Makefile) = 6c580cbea532d08a38cf5e54228bd0210a98da21
+SHA1 (patch-docs_man_xl.1.pod.in) = 280a3717b9f15578d90f85392249ef97844b6765
+SHA1 (patch-docs_man_xl.cfg.5.pod.in) = 5970961552f29c4536a884161a208a27a20dccf4
+SHA1 (patch-docs_man_xlcpupool.cfg.5.pod) = ab3a2529cd10458948557fd7ab032e80df8b1d81
+SHA1 (patch-docs_misc_block-scripts.txt) = 29a49edc4d15c4c8db822fd1d6356d07aeb27b86
+SHA1 (patch-docs_misc_vtd.txt) = 26c12a3023315f35a6f59b6715b811c989c67680
+SHA1 (patch-tools_Makefile) = 65dcdf590339717db22fd89fadab3aaa68d9b6a4
+SHA1 (patch-tools_configure) = 93cb52d3d650aa9b04b4eb0a00f8fa51c46b81ce
+SHA1 (patch-tools_console_daemon_utils.c) = ea0f66a3edbf6cb643580d0fae190064c0cbf0e0
+SHA1 (patch-tools_examples_Makefile) = d43095ab76444fd16a6f63b93fc68606452fb893
+SHA1 (patch-tools_firmware_Makefile) = e3394f66acc09f166cf2ba5e66b9dc3fdedbbabf
+SHA1 (patch-tools_firmware_etherboot_Makefile) = 61741d59c72430d53682ea83deed91ee4ff3d220
+SHA1 (patch-tools_hotplug_NetBSD_Makefile) = c032af025b18e888019247c47016dcf649c4f391
+SHA1 (patch-tools_hotplug_common_Makefile) = 590186dfb31713e8d9ee675186f826bcbcba3c15
+SHA1 (patch-tools_include_xen-sys_NetBSD_evtchn.h) = b22184d6bdde315994635e12f96e993e1c47c1f4
+SHA1 (patch-tools_include_xen-sys_NetBSD_privcmd.h) = b47ef90b0e823b270c491b9206ae10b9f230971d
+SHA1 (patch-tools_libs_ctrl_Makefile) = e377e34e6f719b7433888eee94dba2ec264120bf
+SHA1 (patch-tools_libs_libs.mk) = 29b0faa8293d3579d67205505ea251edff1bd688
+SHA1 (patch-tools_libs_light_libxl.c) = 354079709784ea8534929e65c61c3dcf54f2cce9
+SHA1 (patch-tools_libs_light_libxl_pci.c) = 6a88ebe073f7abed25a3763fc039084239a7c29c
+SHA1 (patch-tools_libs_util_libxlu_pci.c) = 60af75fe9356b91c63ecc82bf1be00d17a9e8989
+SHA1 (patch-tools_libs_xenstore_xenstored_control.c) = 3ddd7db4e11573bb749f9317022e778f491e44a0
+SHA1 (patch-tools_libxl_libxl_dom.c) = 4aa62de9adbc1eb659ba22d03e3fed42619e5a21
+SHA1 (patch-tools_libxl_libxl_event.c) = 9446c88d01b419cc7531b6f6d959816410e74024
+SHA1 (patch-tools_libxl_libxl_internal.h) = abcfaec70521b3ada6b4eae743119c24f141ea8f
+SHA1 (patch-tools_misc_xenhypfs.c) = 2e5919e33f8027777a84bfc380071e54c8e7b807
+SHA1 (patch-tools_ocaml_common.make) = 305994b93fe29fb42e4aa57e19a039abef4e76fe
+SHA1 (patch-tools_ocaml_xenstored_Makefile) = b267702cf4090c7b45bba530e60327fced24e3e5
+SHA1 (patch-tools_ocaml_xenstored_utils.ml) = dcb2a0a90cc74b10d71fe01b8ca48c08a7dd4715
+SHA1 (patch-tools_pygrub_Makefile) = 8149759d17e1d22fbf182e18617b8aa7f0e830fc
+SHA1 (patch-tools_python_Makefile) = 92706e044b1933d6699aab5e4fa89e53b83f23dd
+SHA1 (patch-tools_qemu-xen-traditional_Makefile) = 5fbb55bf84f9856043be301d5d06530190fe9a60
+SHA1 (patch-tools_qemu-xen-traditional_block-raw-posix.c) = eb3efea4b0c7fd744f627f1926fca737ba826b99
+SHA1 (patch-tools_qemu-xen-traditional_configure) = 6a42dcac010f90439a347c0f6e886b07185cb19a
+SHA1 (patch-tools_qemu-xen-traditional_hw_e1000.c) = ec86584529cc743ea27768ad1fab523ee9fb6bea
+SHA1 (patch-tools_qemu-xen-traditional_hw_ide.c) = b541546390c6d142bc6079dbd51cfd65b5223e9e
+SHA1 (patch-tools_qemu-xen-traditional_hw_pass-through.c) = 45848fb5038bdd6def218b35dd0a6496a14102f1
+SHA1 (patch-tools_qemu-xen-traditional_hw_pass-through.h) = 6edb7a9a03d99b84801bf595c4d68acbc361bb4b
+SHA1 (patch-tools_qemu-xen-traditional_hw_piix4acpi.c) = 280265db035e239b173efd9d63b629201d2c0cfa
+SHA1 (patch-tools_qemu-xen-traditional_hw_pt-graphics.c) = b9c18042f40ccacb3f24ab0f1e3c6e1a5bf5521a
+SHA1 (patch-tools_qemu-xen-traditional_hw_pt-msi.c) = a953380dbc3e64528c39e26d2c45c0cbd3e4d738
+SHA1 (patch-tools_qemu-xen-traditional_hw_pt-msi.h) = 787447cc24518fe5ae16942d72d3038db612419d
+SHA1 (patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak) = 3fdfbb7c9c2243a4cf5dabc5a6dd13c12f9d5850
+SHA1 (patch-tools_qemu-xen-traditional_net.c) = 0999993172070db5dc8d7c7daaa4999a3edaadb8
+SHA1 (patch-tools_qemu-xen-traditional_xen-hooks.mak) = bc59cb87742036dfa75869572b21b58dd5a2c5ee
+SHA1 (patch-tools_qemu-xen_audio_audio.c) = a1c33d8df7a15515592d5978412d02683847cce5
+SHA1 (patch-tools_qemu-xen_configure) = 38eee924f66c226a09c2408312fc0f67d99d2b81
+SHA1 (patch-tools_qemu-xen_net_tap-bsd.c) = ac1ed72daeb051eae7352542630a9a02c99e485e
+SHA1 (patch-tools_qemu-xen_net_tap.c) = 53d8c1799136c412b775d7d02d72b1abc63f4dd3
+SHA1 (patch-tools_xenpaging_xenpaging.c) = 3ade1afeb17210632ca350cdbb649f30d4697493
+SHA1 (patch-tools_xenstore_xs_lib.c) = e3a8f6e3b149c3ab0f4ec8dcfa455983f94e6c16
+SHA1 (patch-tools_xl_Makefile) = 76f401d3f3dddb4fd48cf386494583db658e56b0
+SHA1 (patch-xen_Makefile) = fe7450f929aca11049c52c4fe53818441f1dc2ee
+SHA1 (patch-xen_Rules.mk) = c743dc63f51fc280d529a7d9e08650292c171dac
+SHA1 (patch-xen_arch_x86_Makefile) = 99db5e673e367f2a6c8c4fe776b3889cfb3372b1
+SHA1 (patch-xen_include_Makefile) = 71987b559a344b098b97e5a7439232ceda198798

Index: pkgsrc/sysutils/xentools415/patches/patch-.._seabios-rel-1.14.0_src_string.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-.._seabios-rel-1.14.0_src_string.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-.._seabios-rel-1.14.0_src_string.c        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,18 @@
+$NetBSD: patch-.._seabios-rel-1.14.0_src_string.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+when the code is compiled -fwhole-program, memcpy() will be ommitted by gcc
+because nothing in the file references it. Later the link fails with
+undefined references to memcpy().
+Force the inclusion with (externally_visible) attribute
+
+--- ../seabios-rel-1.14.0/src/string.c.orig    2021-04-17 22:32:25.409876075 +0200
++++ ../seabios-rel-1.14.0/src/string.c 2021-04-17 22:32:39.873615679 +0200
+@@ -149,7 +149,7 @@
+         memcpy(d_fl, s_fl, len);
+ }
+ 
+-void *
++__attribute__((externally_visible)) void *
+ #undef memcpy
+ memcpy(void *d1, const void *s1, size_t len)
+ #if MODESEGMENT == 0
Index: pkgsrc/sysutils/xentools415/patches/patch-Config.mk
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-Config.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-Config.mk Sun Apr 18 12:31:26 2021
@@ -0,0 +1,34 @@
+$NetBSD: patch-Config.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Make sure to pass pkgsrc CFLAGS.
+Use -R instead if -rpath, to appease our linker (--enable-rpath bug ?)
+
+--- Config.mk.orig     2020-12-08 15:28:31.000000000 +0100
++++ Config.mk  2020-12-14 11:48:10.669586105 +0100
+@@ -33,7 +33,7 @@
+ 
+ # Tools to run on system hosting the build
+ HOSTCFLAGS  = -Wall -Werror -Wstrict-prototypes -O2 -fomit-frame-pointer
+-HOSTCFLAGS += -fno-strict-aliasing
++HOSTCFLAGS += -fno-strict-aliasing ${EXTRA_HOSTCFLAGS}
+ 
+ DISTDIR     ?= $(XEN_ROOT)/dist
+ DESTDIR     ?= /
+@@ -188,6 +188,8 @@
+ 
+ CFLAGS += -Wall -Wstrict-prototypes
+ 
++CFLAGS += ${EXTRA_CFLAGS}
++
+ $(call cc-option-add,HOSTCFLAGS,HOSTCC,-Wdeclaration-after-statement)
+ $(call cc-option-add,CFLAGS,CC,-Wdeclaration-after-statement)
+ $(call cc-option-add,CFLAGS,CC,-Wno-unused-but-set-variable)
+@@ -198,7 +200,7 @@
+ LDFLAGS += $(foreach i, $(PREPEND_LIB), -L$(i))
+ CFLAGS += $(foreach i, $(PREPEND_INCLUDES), -I$(i))
+ ifeq ($(XEN_TOOLS_RPATH),y)
+-LDFLAGS += -Wl,-rpath,$(libdir)
++LDFLAGS += -Wl,-R$(libdir)
+ endif
+ APPEND_LDFLAGS += $(foreach i, $(APPEND_LIB), -L$(i))
+ APPEND_CFLAGS += $(foreach i, $(APPEND_INCLUDES), -I$(i))
Index: pkgsrc/sysutils/xentools415/patches/patch-Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-Makefile  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,30 @@
+$NetBSD: patch-Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- Makefile.orig      2019-12-17 15:23:09.000000000 +0100
++++ Makefile   2020-05-08 20:05:12.875067651 +0200
+@@ -65,9 +65,9 @@
+ .PHONY: build-stubdom
+ build-stubdom: mini-os-dir build-tools-public-headers
+       $(MAKE) -C stubdom build
+-ifeq (x86_64,$(XEN_TARGET_ARCH))
+-      XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub
+-endif
++#ifeq (x86_64,$(XEN_TARGET_ARCH))
++#     XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom pv-grub
++#endif
+ 
+ .PHONY: build-docs
+ build-docs:
+@@ -136,9 +136,9 @@
+ .PHONY: install-stubdom
+ install-stubdom: mini-os-dir install-tools
+       $(MAKE) -C stubdom install
+-ifeq (x86_64,$(XEN_TARGET_ARCH))
+-      XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub
+-endif
++#ifeq (x86_64,$(XEN_TARGET_ARCH))
++#     XEN_TARGET_ARCH=x86_32 $(MAKE) -C stubdom install-grub
++#endif
+ 
+ .PHONY: tools/firmware/seabios-dir-force-update
+ tools/firmware/seabios-dir-force-update:
Index: pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.1.pod.in
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.1.pod.in:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.1.pod.in      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,17 @@
+$NetBSD: patch-docs_man_xl.1.pod.in,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- docs/man/xl.1.pod.in.orig  2021-04-06 19:14:18.000000000 +0200
++++ docs/man/xl.1.pod.in       2021-04-17 13:34:37.085288645 +0200
+@@ -33,10 +33,10 @@
+ 
+ =over 4
+ 
+-=item start the script B</etc/init.d/xencommons> at boot time
++=item start the script B</etc/rc.d/xencommons> at boot time
+ 
+ Most B<xl> operations rely upon B<xenstored> and B<xenconsoled>: make
+-sure you start the script B</etc/init.d/xencommons> at boot time to
++sure you start the script B</etc/rc.d/xencommons> at boot time to
+ initialize all the daemons needed by B<xl>.
+ 
+ =item setup a B<xenbr0> bridge in dom0
Index: pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.cfg.5.pod.in
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.cfg.5.pod.in:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-docs_man_xl.cfg.5.pod.in  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,29 @@
+$NetBSD: patch-docs_man_xl.cfg.5.pod.in,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- docs/man/xl.cfg.5.pod.in.orig      2018-04-17 19:21:31.000000000 +0200
++++ docs/man/xl.cfg.5.pod.in   2018-04-23 16:14:18.000000000 +0200
+@@ -4,13 +4,13 @@
+ 
+ =head1 SYNOPSIS
+ 
+- /etc/xen/xldomain
++ @XENDCONFDIR@/xldomain
+ 
+ =head1 DESCRIPTION
+ 
+ Creating a VM (a domain in Xen terminology, sometimes called a guest)
+ with xl requires the provision of a domain configuration file.  Typically,
+-these live in F</etc/xen/DOMAIN.cfg>, where DOMAIN is the name of the
++these live in F<@XENDCONFDIR@/DOMAIN.cfg>, where DOMAIN is the name of the
+ domain.
+ 
+ =head1 SYNTAX
+@@ -2623,7 +2623,7 @@
+ 
+ =head1 FILES
+ 
+-F</etc/xen/NAME.cfg>
++F<@XENDCONFDIR@/NAME.cfg>
+ F<@XEN_DUMP_DIR@/NAME>
+ 
+ =head1 BUGS
Index: pkgsrc/sysutils/xentools415/patches/patch-docs_man_xlcpupool.cfg.5.pod
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-docs_man_xlcpupool.cfg.5.pod:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-docs_man_xlcpupool.cfg.5.pod      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,28 @@
+$NetBSD: patch-docs_man_xlcpupool.cfg.5.pod,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- docs/man/xlcpupool.cfg.5.pod.orig  2017-03-24 17:41:23.000000000 +0100
++++ docs/man/xlcpupool.cfg.5.pod       2017-03-24 17:41:50.000000000 +0100
+@@ -4,12 +4,12 @@
+ 
+ =head1 SYNOPSIS
+ 
+- /etc/xen/xlcpupool
++ @XENDCONFDIR@/xlcpupool
+ 
+ =head1 DESCRIPTION
+ 
+ To create a Cpupool with xl requires the provision of a cpupool config
+-file.  Typically these live in `/etc/xen/CPUPOOL.cfg` where CPUPOOL is
++file.  Typically these live in `@XENDCONFDIR@/CPUPOOL.cfg` where CPUPOOL is
+ the name of the cpupool.
+ 
+ =head1 SYNTAX
+@@ -117,7 +117,7 @@
+ 
+ =head1 FILES
+ 
+-F</etc/xen/CPUPOOL.cfg>
++F<@XENDCONFDIR@/CPUPOOL.cfg>
+ 
+ =head1 BUGS
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-docs_misc_block-scripts.txt
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-docs_misc_block-scripts.txt:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-docs_misc_block-scripts.txt       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-docs_misc_block-scripts.txt,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- ./docs/misc/block-scripts.txt.orig 2018-04-23 16:23:34.000000000 +0200
++++ ./docs/misc/block-scripts.txt      2018-04-23 16:23:39.000000000 +0200
+@@ -18,7 +18,7 @@
+ 
+ It is highly recommended that custom hotplug scripts as much as
+ possible include and use the common Xen functionality.  If the script
+-is run from the normal block script location (/etc/xen/scripts by
++is run from the normal block script location (@XENDCONFDIR@/scripts by
+ default), then this can be done by adding the following to the top of
+ the script:
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-docs_misc_vtd.txt
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-docs_misc_vtd.txt:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-docs_misc_vtd.txt Sun Apr 18 12:31:26 2021
@@ -0,0 +1,22 @@
+$NetBSD: patch-docs_misc_vtd.txt,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- docs/misc/vtd.txt.orig     2020-05-08 16:46:26.400241453 +0200
++++ docs/misc/vtd.txt  2020-05-08 16:46:50.253734556 +0200
+@@ -39,7 +39,7 @@
+             echo -n 0000:01:00.0 >/sys/bus/pci/drivers/pciback/bind
+ 
+ 12) reboot system (not requires if you use the dynamic hiding method)
+-13) add "pci" line in /etc/xen/hvm.conf for to assigned devices
++13) add "pci" line in @XENDCONFDIR@/hvm.conf for to assigned devices
+         pci = [ '01:00.0', '03:00.0' ]
+ 15) start hvm guest and use "lspci" to see the passthru device and
+     "ifconfig" to see if IP address has been assigned to NIC devices.
+@@ -77,7 +77,7 @@
+         echo "0000:01:00.0" > /sys/bus/pci/devices/0000:01:00.0/driver/unbind
+         echo "0000:01:00.0" > /sys/bus/pci/drivers/pci-stub/bind
+ 
+-12) add "pci" line in /etc/xen/hvm.conf for to assigned devices
++12) add "pci" line in @XENDCONFDIR@/hvm.conf for to assigned devices
+         pci = [ '01:00.0' ]
+ 13) start hvm guest and use "lspci" to see the passthru device and
+     "ifconfig" to see if IP address has been assigned to NIC devices.
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_Makefile    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,21 @@
+$NetBSD: patch-tools_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/Makefile.orig        2020-12-08 15:50:17.000000000 +0100
++++ tools/Makefile     2020-12-09 15:44:35.415904040 +0100
+@@ -34,7 +34,7 @@
+ SUBDIRS-$(CONFIG_X86) += xenpaging
+ SUBDIRS-$(CONFIG_X86) += debugger/gdbsx
+ SUBDIRS-$(CONFIG_X86) += debugger/kdd
+-SUBDIRS-$(CONFIG_TESTS) += tests
++#XXX SUBDIRS-$(CONFIG_TESTS) += tests
+ 
+ SUBDIRS-y += python
+ SUBDIRS-y += pygrub
+@@ -247,6 +247,7 @@
+               --bindir=$(LIBEXEC_BIN) \
+               --datadir=$(SHAREDIR)/qemu-xen \
+               --localstatedir=$(localstatedir) \
++              --disable-opengl \
+               --docdir=$(LIBEXEC)/share/doc \
+               --mandir=$(LIBEXEC)/share/man \
+               --libexecdir=$(LIBEXEC)/libexec \
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_configure
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_configure:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_configure   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,30 @@
+$NetBSD: patch-tools_configure,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/configure.orig       2020-12-08 15:54:42.000000000 +0100
++++ tools/configure    2020-12-09 15:47:21.690205178 +0100
+@@ -2444,7 +2444,7 @@
+ 
+ 
+ 
+-ac_config_files="$ac_config_files ../config/Tools.mk hotplug/FreeBSD/rc.d/xencommons hotplug/FreeBSD/rc.d/xendriverdomain hotplug/Linux/init.d/sysconfig.xencommons 
hotplug/Linux/init.d/sysconfig.xendomains hotplug/Linux/init.d/xen-watchdog hotplug/Linux/init.d/xencommons hotplug/Linux/init.d/xendomains hotplug/Linux/init.d/xendriverdomain 
hotplug/Linux/launch-xenstore hotplug/Linux/vif-setup hotplug/Linux/xen-hotplug-common.sh hotplug/Linux/xendomains hotplug/NetBSD/rc.d/xencommons hotplug/NetBSD/rc.d/xendriverdomain 
ocaml/xenstored/oxenstored.conf"
++ac_config_files="$ac_config_files ../config/Tools.mk ../config/Paths.mk hotplug/FreeBSD/rc.d/xencommons hotplug/FreeBSD/rc.d/xendriverdomain hotplug/Linux/init.d/sysconfig.xencommons 
hotplug/Linux/init.d/sysconfig.xendomains hotplug/Linux/init.d/xen-watchdog hotplug/Linux/init.d/xencommons hotplug/Linux/init.d/xendomains hotplug/Linux/init.d/xendriverdomain 
hotplug/Linux/launch-xenstore hotplug/Linux/vif-setup hotplug/Linux/xen-hotplug-common.sh hotplug/Linux/xendomains hotplug/NetBSD/rc.d/xencommons hotplug/NetBSD/rc.d/xendriverdomain 
ocaml/xenstored/oxenstored.conf"
+ 
+ ac_config_headers="$ac_config_headers config.h"
+ 
+@@ -3894,7 +3894,7 @@
+ 
+ if test "x$sysconfdir" = 'x${prefix}/etc' ; then
+     case "$host_os" in
+-         *freebsd*)
++         *freebsd*|*netbsd*)
+          sysconfdir=$prefix/etc
+          ;;
+          *solaris*)
+@@ -10713,6 +10713,7 @@
+ do
+   case $ac_config_target in
+     "../config/Tools.mk") CONFIG_FILES="$CONFIG_FILES ../config/Tools.mk" ;;
++    "../config/Paths.mk") CONFIG_FILES="$CONFIG_FILES ../config/Paths.mk" ;;
+     "hotplug/FreeBSD/rc.d/xencommons") CONFIG_FILES="$CONFIG_FILES hotplug/FreeBSD/rc.d/xencommons" ;;
+     "hotplug/FreeBSD/rc.d/xendriverdomain") CONFIG_FILES="$CONFIG_FILES hotplug/FreeBSD/rc.d/xendriverdomain" ;;
+     "hotplug/Linux/init.d/sysconfig.xencommons") CONFIG_FILES="$CONFIG_FILES hotplug/Linux/init.d/sysconfig.xencommons" ;;
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_console_daemon_utils.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_console_daemon_utils.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_console_daemon_utils.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,22 @@
+$NetBSD: patch-tools_console_daemon_utils.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/console/daemon/utils.c.orig  2020-12-08 15:28:31.000000000 +0100
++++ tools/console/daemon/utils.c       2020-12-09 16:22:49.947276738 +0100
+@@ -107,13 +107,15 @@
+       xs = xs_open(0);
+       if (xs == NULL) {
+               dolog(LOG_ERR,
+-                    "Failed to contact xenstore (%m).  Is it running?");
++                    "Failed to contact xenstore (%s).  Is it running?",
++                        strerror(errno));
+               goto out;
+       }
+ 
+       xc = xc_interface_open(0,0,0);
+       if (!xc) {
+-              dolog(LOG_ERR, "Failed to contact hypervisor (%m)");
++              dolog(LOG_ERR, "Failed to contact hypervisor (%s)",
++                  strerror(errno));
+               goto out;
+       }
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_examples_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_examples_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_examples_Makefile   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-tools_examples_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/examples/Makefile.orig       2021-01-10 21:34:35.490019719 +0100
++++ tools/examples/Makefile    2021-01-10 21:35:00.852608954 +0100
+@@ -1,6 +1,7 @@
+ XEN_ROOT = $(CURDIR)/../..
+ include $(XEN_ROOT)/tools/Rules.mk
+ 
++XEN_CONFIG_DIR=${XEN_EXAMPLES_DIR}
+ # Xen configuration dir and configs to go there.
+ XEN_READMES = README
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_Makefile   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_firmware_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/firmware/Makefile.orig       2020-05-14 14:19:32.000000000 +0200
++++ tools/firmware/Makefile    2020-08-26 19:39:04.950176746 +0200
+@@ -24,7 +24,7 @@
+       cp ovmf-makefile ovmf-dir/Makefile;
+ 
+ seabios-dir:
+-      GIT=$(GIT) $(XEN_ROOT)/scripts/git-checkout.sh $(SEABIOS_UPSTREAM_URL) $(SEABIOS_UPSTREAM_REVISION) seabios-dir
++      ln -sf ../../../seabios-rel-1.14.0 ${WRKSRC}/tools/firmware/seabios-dir
+       cp seabios-config seabios-dir/.config;
+       $(MAKE) -C seabios-dir olddefconfig CC=$(SEABIOSCC) LD=$(SEABIOSLD)
+       rm -f seabios-dir/.version
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_etherboot_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_etherboot_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_firmware_etherboot_Makefile Sun Apr 18 12:31:26 2021
@@ -0,0 +1,26 @@
+$NetBSD: patch-tools_firmware_etherboot_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/firmware/etherboot/Makefile.orig     2019-12-17 15:23:09.000000000 +0100
++++ tools/firmware/etherboot/Makefile  2020-05-08 16:59:46.337172477 +0200
+@@ -32,18 +32,10 @@
+ %.rom: $D/src/arch/i386/Makefile
+       $(MAKE) -C $D/src bin/$(*F).rom
+ 
+-$T:
+-      set -e; if ! $(FETCHER) _$T $(IPXE_TARBALL_URL); then \
+-              $(GIT) clone $(IPXE_GIT_URL) $D.git; \
+-              (cd $D.git && $(GIT) archive --format=tar --prefix=$D/ \
+-              $(IPXE_GIT_TAG) | gzip -n >../_$T); \
+-              rm -rf $D.git; \
+-      fi
+-      mv _$T $T
++$D:
++      ln -sf $(WRKSRC)/../ipxe-${IPXE_GIT_TAG} $D
+ 
+-$D/src/arch/i386/Makefile: $T Config
+-      rm -rf $D
+-      gzip -dc $T | tar xf -
++$D/src/arch/i386/Makefile: $D Config
+       for i in $$(cat patches/series) ; do                 \
+           patch -d $D -p1 --quiet <patches/$$i || exit 1 ; \
+       done
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_NetBSD_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_NetBSD_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_NetBSD_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,46 @@
+$NetBSD: patch-tools_hotplug_NetBSD_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/hotplug/NetBSD/Makefile.orig 2021-02-03 15:23:25.000000000 +0100
++++ tools/hotplug/NetBSD/Makefile      2021-02-03 15:28:32.949717159 +0100
+@@ -10,7 +10,7 @@
+ XEN_SCRIPTS += qemu-ifup
+ 
+ XEN_SCRIPT_DATA =
+-XEN_RCD_PROG = rc.d/xencommons rc.d/xendomains rc.d/xen-watchdog rc.d/xendriverdomain
++#XEN_RCD_PROG = rc.d/xencommons rc.d/xendomains rc.d/xen-watchdog rc.d/xendriverdomain
+ 
+ .PHONY: all
+ all:
+@@ -26,10 +26,11 @@
+ 
+ .PHONY: install-scripts
+ install-scripts:
+-      $(INSTALL_DIR) $(DESTDIR)$(XEN_SCRIPT_DIR)
++      $(INSTALL_DIR) $(DESTDIR)$(XEN_EXAMPLES_DIR)
++      $(INSTALL_DIR) $(DESTDIR)$(XEN_EXAMPLES_DIR)/scripts
+       set -e; for i in $(XEN_SCRIPTS); \
+          do \
+-         $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
++         $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_EXAMPLES_DIR)/scripts; \
+       done
+       set -e; for i in $(XEN_SCRIPT_DATA); \
+          do \
+@@ -43,12 +44,12 @@
+ 
+ .PHONY: install-rcd
+ install-rcd:
+-      $(INSTALL_DIR) $(DESTDIR)$(INITD_DIR)
+-      set -e; for i in $(XEN_RCD_PROG); \
+-         do \
+-         $(INSTALL_PROG) $$i $(DESTDIR)$(INITD_DIR); \
+-      done
+-      $(INSTALL_DATA) ../common/hotplugpath.sh $(DESTDIR)$(INITD_DIR)/xen-hotplugpath.sh
++#     $(INSTALL_DIR) $(DESTDIR)$(INITD_DIR)
++#     set -e; for i in $(XEN_RCD_PROG); \
++#        do \
++#        $(INSTALL_PROG) $$i $(DESTDIR)$(INITD_DIR); \
++#     done
++#     $(INSTALL_DATA) ../common/hotplugpath.sh $(DESTDIR)$(INITD_DIR)/xen-hotplugpath.sh
+ 
+ .PHONY: uninstall-rcd
+ uninstall-rcd:
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_common_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_common_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_hotplug_common_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,24 @@
+$NetBSD: patch-tools_hotplug_common_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/hotplug/common/Makefile.orig 2018-04-17 19:21:31.000000000 +0200
++++ tools/hotplug/common/Makefile      2018-04-23 16:03:55.000000000 +0200
+@@ -26,15 +26,15 @@
+ 
+ .PHONY: install-scripts
+ install-scripts: build
+-      [ -d $(DESTDIR)$(XEN_SCRIPT_DIR) ] || \
+-              $(INSTALL_DIR) $(DESTDIR)$(XEN_SCRIPT_DIR)
++      [ -d $(DESTDIR)${XEN_EXAMPLES_DIR}/scripts ] || \
++              $(INSTALL_DIR) $(DESTDIR)${XEN_EXAMPLES_DIR}/scripts
+       set -e; for i in $(XEN_SCRIPTS); \
+          do \
+-         $(INSTALL_PROG) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
++         $(INSTALL_PROG) $$i $(DESTDIR)${XEN_EXAMPLES_DIR}/scripts; \
+       done
+       set -e; for i in $(XEN_SCRIPT_DATA); \
+          do \
+-         $(INSTALL_DATA) $$i $(DESTDIR)$(XEN_SCRIPT_DIR); \
++         $(INSTALL_DATA) $$i $(DESTDIR)${XEN_EXAMPLES_DIR}/scripts; \
+       done
+ 
+ .PHONY: uninstall-scripts
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_evtchn.h
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_evtchn.h:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_evtchn.h     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,96 @@
+$NetBSD: patch-tools_include_xen-sys_NetBSD_evtchn.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Use system-provided headers instead of local, outdated definitions
+
+--- tools/include/xen-sys/NetBSD/evtchn.h.orig 2021-04-17 13:48:20.754547947 +0200
++++ tools/include/xen-sys/NetBSD/evtchn.h      2021-04-17 13:51:39.136816295 +0200
+@@ -1,86 +1,3 @@
+-/* $NetBSD: patch-tools_include_xen-sys_NetBSD_evtchn.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $ */
+-/******************************************************************************
+- * evtchn.h
+- * 
+- * Interface to /dev/xen/evtchn.
+- * 
+- * Copyright (c) 2003-2005, K A Fraser
+- * 
+- * This file may be distributed separately from the Linux kernel, or
+- * incorporated into other software packages, subject to the following license:
+- * 
+- * Permission is hereby granted, free of charge, to any person obtaining a copy
+- * of this source file (the "Software"), to deal in the Software without
+- * restriction, including without limitation the rights to use, copy, modify,
+- * merge, publish, distribute, sublicense, and/or sell copies of the Software,
+- * and to permit persons to whom the Software is furnished to do so, subject to
+- * the following conditions:
+- * 
+- * The above copyright notice and this permission notice shall be included in
+- * all copies or substantial portions of the Software.
+- * 
+- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+- * IN THE SOFTWARE.
+- */
+-
+-#ifndef __NetBSD_EVTCHN_H__
+-#define __NetBSD_EVTCHN_H__
+-
+-/*
+- * Bind a fresh port to VIRQ @virq.
+- */
+-#define IOCTL_EVTCHN_BIND_VIRQ                                \
+-      _IOWR('E', 4, struct ioctl_evtchn_bind_virq)
+-struct ioctl_evtchn_bind_virq {
+-      unsigned int virq;
+-      unsigned int port;
+-};
+-
+-/*
+- * Bind a fresh port to remote <@remote_domain, @remote_port>.
+- */
+-#define IOCTL_EVTCHN_BIND_INTERDOMAIN                 \
+-      _IOWR('E', 5, struct ioctl_evtchn_bind_interdomain)
+-struct ioctl_evtchn_bind_interdomain {
+-      unsigned int remote_domain, remote_port;
+-      unsigned int port;
+-};
+-
+-/*
+- * Allocate a fresh port for binding to @remote_domain.
+- */
+-#define IOCTL_EVTCHN_BIND_UNBOUND_PORT                        \
+-      _IOWR('E', 6, struct ioctl_evtchn_bind_unbound_port)
+-struct ioctl_evtchn_bind_unbound_port {
+-      unsigned int remote_domain;
+-      unsigned int port;
+-};
+-
+-/*
+- * Unbind previously allocated @port.
+- */
+-#define IOCTL_EVTCHN_UNBIND                           \
+-      _IOW('E', 7, struct ioctl_evtchn_unbind)
+-struct ioctl_evtchn_unbind {
+-      unsigned int port;
+-};
+-
+-/*
+- * Send event to previously allocated @port.
+- */
+-#define IOCTL_EVTCHN_NOTIFY                           \
+-      _IOW('E', 8, struct ioctl_evtchn_notify)
+-struct ioctl_evtchn_notify {
+-      unsigned int port;
+-};
+-
+-/* Clear and reinitialise the event buffer. Clear error condition. */
+-#define IOCTL_EVTCHN_RESET                            \
+-      _IO('E', 9)
+-
+-#endif /* __NetBSD_EVTCHN_H__ */
++/* use the system-provided headers */
++#include <xen/xenio.h>
++#include <xen/xenio3.h>
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_privcmd.h
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_privcmd.h:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_include_xen-sys_NetBSD_privcmd.h    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,116 @@
+$NetBSD: patch-tools_include_xen-sys_NetBSD_privcmd.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Use system-provided headers instead of local, outdated definitions
+
+--- tools/include/xen-sys/NetBSD/privcmd.h.orig        2021-04-17 13:48:20.759557127 +0200
++++ tools/include/xen-sys/NetBSD/privcmd.h     2021-04-17 13:53:28.776879861 +0200
+@@ -1,106 +1,3 @@
+-/*    NetBSD: xenio.h,v 1.3 2005/05/24 12:07:12 yamt Exp $    */
+-
+-/******************************************************************************
+- * privcmd.h
+- * 
+- * Copyright (c) 2003-2004, K A Fraser
+- * 
+- * This file may be distributed separately from the Linux kernel, or
+- * incorporated into other software packages, subject to the following license:
+- * 
+- * Permission is hereby granted, free of charge, to any person obtaining a copy
+- * of this source file (the "Software"), to deal in the Software without
+- * restriction, including without limitation the rights to use, copy, modify,
+- * merge, publish, distribute, sublicense, and/or sell copies of the Software,
+- * and to permit persons to whom the Software is furnished to do so, subject to
+- * the following conditions:
+- * 
+- * The above copyright notice and this permission notice shall be included in
+- * all copies or substantial portions of the Software.
+- * 
+- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+- * IN THE SOFTWARE.
+- */
+-
+-#ifndef __NetBSD_PRIVCMD_H__
+-#define __NetBSD_PRIVCMD_H__
+-
+-/* Interface to /dev/xen/privcmd */
+-
+-typedef struct privcmd_hypercall
+-{
+-    unsigned long op;
+-    unsigned long arg[5];
+-    long retval;
+-} privcmd_hypercall_t;
+-
+-typedef struct privcmd_mmap_entry {
+-    unsigned long va;
+-    unsigned long mfn;
+-    unsigned long npages;
+-} privcmd_mmap_entry_t; 
+-
+-typedef struct privcmd_mmap {
+-    int num;
+-    domid_t dom; /* target domain */
+-    privcmd_mmap_entry_t *entry;
+-} privcmd_mmap_t; 
+-
+-typedef struct privcmd_mmapbatch {
+-    int num;     /* number of pages to populate */
+-    domid_t dom; /* target domain */
+-    unsigned long addr;  /* virtual address */
+-    unsigned long *arr; /* array of mfns - top nibble set on err */
+-} privcmd_mmapbatch_t; 
+-
+-typedef struct privcmd_blkmsg
+-{
+-    unsigned long op;
+-    void         *buf;
+-    int           buf_size;
+-} privcmd_blkmsg_t;
+-
+-/*
+- * @cmd: IOCTL_PRIVCMD_HYPERCALL
+- * @arg: &privcmd_hypercall_t
+- * Return: Value returned from execution of the specified hypercall.
+- */
+-#define IOCTL_PRIVCMD_HYPERCALL         \
+-    _IOWR('P', 0, privcmd_hypercall_t)
+-
+-#if defined(_KERNEL)
+-/* compat */
+-#define IOCTL_PRIVCMD_INITDOMAIN_EVTCHN_OLD \
+-    _IO('P', 1)
+-#endif /* defined(_KERNEL) */
+-    
+-#define IOCTL_PRIVCMD_MMAP             \
+-    _IOW('P', 2, privcmd_mmap_t)
+-#define IOCTL_PRIVCMD_MMAPBATCH        \
+-    _IOW('P', 3, privcmd_mmapbatch_t)
+-#define IOCTL_PRIVCMD_GET_MACH2PHYS_START_MFN \
+-    _IOR('P', 4, unsigned long)
+-
+-/*
+- * @cmd: IOCTL_PRIVCMD_INITDOMAIN_EVTCHN
+- * @arg: n/a
+- * Return: Port associated with domain-controller end of control event channel
+- *         for the initial domain.
+- */
+-#define IOCTL_PRIVCMD_INITDOMAIN_EVTCHN \
+-    _IOR('P', 5, int)
+-
+-/* Interface to /dev/xenevt */
+-/* EVTCHN_RESET: Clear and reinit the event buffer. Clear error condition. */
+-#define EVTCHN_RESET  _IO('E', 1)
+-/* EVTCHN_BIND: Bind to the specified event-channel port. */
+-#define EVTCHN_BIND   _IOW('E', 2, unsigned long)
+-/* EVTCHN_UNBIND: Unbind from the specified event-channel port. */
+-#define EVTCHN_UNBIND _IOW('E', 3, unsigned long)
+-
+-#endif /* __NetBSD_PRIVCMD_H__ */
++/* use the system-provided headers */
++#include <xen/xenio.h>
++#include <xen/xenio3.h>
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_ctrl_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_ctrl_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_ctrl_Makefile  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_libs_ctrl_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+PKG_CONFIG is an environnement variable, rename to PKG_CONFIG_PC
+
+--- tools/libs/ctrl/Makefile.orig      2020-12-09 18:39:19.902854035 +0100
++++ tools/libs/ctrl/Makefile   2020-12-09 18:39:37.171930411 +0100
+@@ -50,7 +50,7 @@
+ CFLAGS-$(CONFIG_Linux) += -D_GNU_SOURCE
+ 
+ LIBHEADER := xenctrl.h xenctrl_compat.h
+-PKG_CONFIG := xencontrol.pc
++PKG_CONFIG_PC := xencontrol.pc
+ PKG_CONFIG_NAME := Xencontrol
+ 
+ NO_HEADERS_CHK := y
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_libs.mk
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_libs.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_libs.mk        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,58 @@
+$NetBSD: patch-tools_libs_libs.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+PKG_CONFIG is defined in environnement, rename to PKG_CONFIG_PC
+
+--- tools/libs/libs.mk.orig    2021-04-06 19:14:18.000000000 +0200
++++ tools/libs/libs.mk 2021-04-17 13:40:31.365641659 +0200
+@@ -1,7 +1,7 @@
+ # Common Makefile for building a lib.
+ #
+ # Variables taken as input:
+-#   PKG_CONFIG: name of pkg-config file (xen$(LIBNAME).pc if empty)
++#   PKG_CONFIG_PC: name of pkg-config file (xen$(LIBNAME).pc if empty)
+ #   MAJOR:   major version of lib (Xen version if empty)
+ #   MINOR:   minor version of lib (0 if empty)
+ 
+@@ -29,7 +29,7 @@
+ comma:= ,
+ empty:=
+ space:= $(empty) $(empty)
+-PKG_CONFIG ?= $(LIB_FILE_NAME).pc
++PKG_CONFIG_PC ?= $(LIB_FILE_NAME).pc
+ PKG_CONFIG_NAME ?= Xen$(LIBNAME)
+ PKG_CONFIG_DESC ?= The $(PKG_CONFIG_NAME) library for Xen hypervisor
+ PKG_CONFIG_VERSION := $(MAJOR).$(MINOR)
+@@ -38,13 +38,13 @@
+ PKG_CONFIG_REQPRIV := $(subst $(space),$(comma),$(strip $(foreach lib,$(patsubst ctrl,control,$(USELIBS_$(LIBNAME))),xen$(lib))))
+ 
+ ifneq ($(CONFIG_LIBXC_MINIOS),y)
+-PKG_CONFIG_INST := $(PKG_CONFIG)
++PKG_CONFIG_INST := $(PKG_CONFIG_PC)
+ $(PKG_CONFIG_INST): PKG_CONFIG_PREFIX = $(prefix)
+ $(PKG_CONFIG_INST): PKG_CONFIG_INCDIR = $(includedir)
+ $(PKG_CONFIG_INST): PKG_CONFIG_LIBDIR = $(libdir)
+ endif
+ 
+-PKG_CONFIG_LOCAL := $(PKG_CONFIG_DIR)/$(PKG_CONFIG)
++PKG_CONFIG_LOCAL := $(PKG_CONFIG_DIR)/$(PKG_CONFIG_PC)
+ 
+ LIBHEADER ?= $(LIB_FILE_NAME).h
+ LIBHEADERS = $(foreach h, $(LIBHEADER), $(XEN_INCLUDE)/$(h))
+@@ -112,7 +112,7 @@
+       $(SYMLINK_SHLIB) lib$(LIB_FILE_NAME).so.$(MAJOR).$(MINOR) $(DESTDIR)$(libdir)/lib$(LIB_FILE_NAME).so.$(MAJOR)
+       $(SYMLINK_SHLIB) lib$(LIB_FILE_NAME).so.$(MAJOR) $(DESTDIR)$(libdir)/lib$(LIB_FILE_NAME).so
+       for i in $(LIBHEADERS); do $(INSTALL_DATA) $$i $(DESTDIR)$(includedir); done
+-      $(INSTALL_DATA) $(PKG_CONFIG) $(DESTDIR)$(PKG_INSTALLDIR)
++      $(INSTALL_DATA) $(PKG_CONFIG_PC) $(DESTDIR)$(PKG_INSTALLDIR)
+ 
+ .PHONY: uninstall
+ uninstall:
+@@ -132,7 +132,7 @@
+       rm -rf *.rpm $(LIB) *~ $(DEPS_RM) $(LIB_OBJS) $(PIC_OBJS)
+       rm -f lib$(LIB_FILE_NAME).so.$(MAJOR).$(MINOR) lib$(LIB_FILE_NAME).so.$(MAJOR)
+       rm -f headers.chk headers.lst
+-      rm -f $(PKG_CONFIG)
++      rm -f $(PKG_CONFIG_PC)
+       rm -f _paths.h
+ 
+ .PHONY: distclean
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl.c  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,24 @@
+$NetBSD: patch-tools_libs_light_libxl.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+error: array subscript has type 'char' [-Werror=char-subscripts]
+
+--- tools/libs/light/libxl.c.orig      2021-04-17 22:11:04.304715386 +0200
++++ tools/libs/light/libxl.c   2021-04-17 22:12:29.062613549 +0200
+@@ -673,7 +673,7 @@
+         goto out;
+     }
+ 
+-    while (isblank(*params))
++    while (isblank((unsigned char)*params))
+         params++;
+ 
+     for (par = params; *par; par = end) {
+@@ -703,7 +703,7 @@
+             goto out;
+         }
+ 
+-        while (isblank(*end))
++        while (isblank((unsigned char)*end))
+             end++;
+     }
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl_pci.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl_pci.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_light_libxl_pci.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_libs_light_libxl_pci.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+error: array subscript has type 'char' [-Werror=char-subscripts]
+
+--- tools/libs/light/libxl_pci.c.orig  2021-04-17 22:15:01.075399964 +0200
++++ tools/libs/light/libxl_pci.c       2021-04-17 22:15:30.482517194 +0200
+@@ -777,7 +777,7 @@
+         }
+ 
+         for (i = 0; i < n; i++) {
+-            if (!isgraph(name[i])) {
++            if (!isgraph((unsigned char)name[i])) {
+                 LOG(ERROR, "Names may only include printable characters");
+                 return ERROR_FAIL;
+             }
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_util_libxlu_pci.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_util_libxlu_pci.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_util_libxlu_pci.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_libs_util_libxlu_pci.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+error: array subscript has type 'char' [-Werror=char-subscripts]
+
+--- ./tools/libs/util/libxlu_pci.c.orig        2021-04-17 22:17:52.998629860 +0200
++++ ./tools/libs/util/libxlu_pci.c     2021-04-17 22:18:06.194127140 +0200
+@@ -19,7 +19,7 @@
+     int n;
+ 
+     /* Count occurrences of ':' to detrmine presence/absence of the 'domain' */
+-    while (isxdigit(*ptr) || *ptr == ':') {
++    while (isxdigit((unsigned char)*ptr) || *ptr == ':') {
+         if (*ptr == ':')
+             colons++;
+         ptr++;
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libs_xenstore_xenstored_control.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libs_xenstore_xenstored_control.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libs_xenstore_xenstored_control.c   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_libs_xenstore_xenstored_control.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+error: array subscript has type 'char' [-Werror=char-subscripts]
+
+--- tools/xenstore/xenstored_control.c.orig    2021-04-17 22:20:28.658953461 +0200
++++ tools/xenstore/xenstored_control.c 2021-04-17 22:20:41.265121523 +0200
+@@ -601,7 +601,7 @@
+       if (lu_status->cmdline) {
+               argc = 4;   /* At least one arg + progname + "-U" + NULL. */
+               for (i = 0; lu_status->cmdline[i]; i++)
+-                      if (isspace(lu_status->cmdline[i]))
++                      if (isspace((unsigned char)lu_status->cmdline[i]))
+                               argc++;
+               argv = talloc_array(ctx, char *, argc);
+               if (!argv)
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_dom.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_dom.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_dom.c   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_libxl_libxl_dom.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/libs/light/libxl_dom.c.orig  2020-12-08 15:28:31.000000000 +0100
++++ tools/libs/light/libxl_dom.c       2020-12-09 15:59:56.104509990 +0100
+@@ -1228,7 +1228,7 @@
+         goto out;
+     }
+     uuid_string = GCSPRINTF(LIBXL_UUID_FMT, LIBXL_UUID_BYTES(info.uuid));
+-    path = GCSPRINTF(XEN_LIB_DIR "/userdata-%s.%u.%s.%s",
++    path = GCSPRINTF(XEN_RUN_DIR "/userdata-%s.%u.%s.%s",
+                      wh, domid, uuid_string, userdata_userid);
+ 
+  out:
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_event.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_event.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_event.c Sun Apr 18 12:31:26 2021
@@ -0,0 +1,24 @@
+$NetBSD: patch-tools_libxl_libxl_event.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+The SIGCHLD handler just writes to a pipe where the reader is the
+same process. The idea is that this will cause poll(2) in the main
+thread to exit with the reaper pipe readable, and do child cleanup here.
+
+Unfortunably, is the child also has a write pipe back to the
+parent (as e.g. with pygrub), the loop in afterpoll_internal() may see the
+POLLHUP event on this pipe before the POLLIN even on the reaper pipe, and
+this will be considered as an error (from e.g. pygrub).
+
+work around by filtering POLLHUP events here
+
+--- tools/libs/light/libxl_event.c.orig        2020-12-08 15:28:31.000000000 +0100
++++ tools/libs/light/libxl_event.c     2020-12-09 16:00:48.840221028 +0100
+@@ -1443,7 +1443,7 @@
+ 
+             revents = afterpoll_check_fd(poller,fds,nfds,
+                                          efd->fd,efd->events);
+-            if (revents)
++            if (revents & ~POLLHUP)
+                 goto found_fd_event;
+         }
+         /* no ordinary fd events, then */
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_internal.h
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_internal.h:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_libxl_libxl_internal.h      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,23 @@
+$NetBSD: patch-tools_libxl_libxl_internal.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+bump some timeouts to more reasonable values. 40s is not enough
+if there is lots of them (e.g lots of network interfaces) and they
+need to be serialized.
+
+--- tools/libs/light/libxl_internal.h.orig     2020-12-08 15:28:31.000000000 +0100
++++ tools/libs/light/libxl_internal.h  2020-12-09 16:01:49.819103324 +0100
+@@ -93,11 +93,11 @@
+ #include "_libxl_types_internal_json.h"
+ 
+ #define LIBXL_INIT_TIMEOUT 10
+-#define LIBXL_DESTROY_TIMEOUT 10
+-#define LIBXL_HOTPLUG_TIMEOUT 40
++#define LIBXL_DESTROY_TIMEOUT 180
++#define LIBXL_HOTPLUG_TIMEOUT 180
+ /* QEMU may be slow to load and start due to a bug in Linux where the I/O
+  * subsystem sometime produce high latency under load. */
+-#define LIBXL_DEVICE_MODEL_START_TIMEOUT 60
++#define LIBXL_DEVICE_MODEL_START_TIMEOUT 180
+ #define LIBXL_DEVICE_MODEL_SAVE_FILE XEN_LIB_DIR "/qemu-save" /* .$domid */
+ #define LIBXL_DEVICE_MODEL_RESTORE_FILE XEN_LIB_DIR "/qemu-resume" /* .$domid */
+ #define LIBXL_QMP_CMD_TIMEOUT 10
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_misc_xenhypfs.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_misc_xenhypfs.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_misc_xenhypfs.c     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_misc_xenhypfs.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+error: array subscript has type 'char' [-Werror=char-subscripts]
+
+--- tools/misc/xenhypfs.c.orig 2021-04-17 22:22:30.893118826 +0200
++++ tools/misc/xenhypfs.c      2021-04-17 22:23:04.525580088 +0200
+@@ -22,7 +22,7 @@
+     char *c;
+ 
+     for (c = string; *c; c++) {
+-        if (isgraph(*c) || isspace(*c))
++        if (isgraph((unsigned char)*c) || isspace((unsigned char)*c))
+             printf("%c", *c);
+         else
+             printf("\\x%02x", *c);
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_common.make
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_common.make:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_common.make   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,23 @@
+$NetBSD: patch-tools_ocaml_common.make,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Handle ocaml-findlib 1.7.3 already appending destdir
+
+--- tools/ocaml/common.make.orig       2020-12-08 15:28:31.000000000 +0100
++++ tools/ocaml/common.make    2021-01-09 19:27:02.447285099 +0100
+@@ -3,7 +3,7 @@
+ CC ?= gcc
+ OCAMLOPT ?= ocamlopt
+ OCAMLC ?= ocamlc
+-OCAMLMKLIB ?= ocamlmklib
++OCAMLMKLIB ?= ocamlmklib -elfmode
+ OCAMLDEP ?= ocamldep
+ OCAMLLEX ?= ocamllex
+ OCAMLYACC ?= ocamlyacc
+@@ -17,6 +17,6 @@
+ 
+ VERSION := 4.1
+ 
+-OCAMLDESTDIR ?= $(DESTDIR)$(shell $(OCAMLFIND) printconf destdir)
++OCAMLDESTDIR ?= $(shell $(OCAMLFIND) printconf destdir)
+ 
+ o= >$@.new && mv -f $@.new $@
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_Makefile    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-tools_ocaml_xenstored_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/ocaml/xenstored/Makefile.orig        2016-02-09 14:44:19.000000000 +0000
++++ tools/ocaml/xenstored/Makefile
+@@ -1,6 +1,7 @@
+ XEN_ROOT = $(CURDIR)/../../..
+ OCAML_TOPLEVEL = $(CURDIR)/..
+ include $(OCAML_TOPLEVEL)/common.make
++XEN_CONFIG_DIR=${XEN_EXAMPLES_DIR}
+ 
+ # Include configure output (config.h)
+ CFLAGS += -include $(XEN_ROOT)/tools/config.h
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_utils.ml
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_utils.ml:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_ocaml_xenstored_utils.ml    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_ocaml_xenstored_utils.ml,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/ocaml/xenstored/utils.ml.orig        2021-01-10 18:02:05.000000000 +0100
++++ tools/ocaml/xenstored/utils.ml     2021-01-10 20:20:53.433611357 +0100
+@@ -86,7 +86,7 @@
+       let buf = Bytes.make 20 '\000' in
+       let sz = Unix.read fd buf 0 20 in
+       Unix.close fd;
+-      int_of_string (Bytes.sub_string buf 0 sz)
++      int_of_string (String.trim (Bytes.sub_string buf 0 sz))
+ 
+ (* @path may be guest data and needs its length validating.  @connection_path
+  * is generated locally in xenstored and always of the form "/local/domain/$N/" *)
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_pygrub_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_pygrub_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_pygrub_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_pygrub_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/pygrub/Makefile.orig 2020-12-14 15:48:30.300876169 +0100
++++ tools/pygrub/Makefile      2020-12-14 15:48:47.821580386 +0100
+@@ -3,7 +3,7 @@
+ include $(XEN_ROOT)/tools/Rules.mk
+ 
+ PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS)
+-PY_LDFLAGS = $(SHLIB_LDFLAGS) $(APPEND_LDFLAGS)
++PY_LDFLAGS = $(SHLIB_LDFLAGS) $(LDFLAGS) $(APPEND_LDFLAGS)
+ INSTALL_LOG = build/installed_files.txt
+ 
+ .PHONY: all
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_python_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_python_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_python_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_python_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/python/Makefile.orig 2020-12-14 15:32:06.314547060 +0100
++++ tools/python/Makefile      2020-12-14 15:33:29.005101260 +0100
+@@ -5,7 +5,7 @@
+ all: build
+ 
+ PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS)
+-PY_LDFLAGS = $(SHLIB_LDFLAGS) $(APPEND_LDFLAGS)
++PY_LDFLAGS = $(SHLIB_LDFLAGS) $(LDFLAGS) $(APPEND_LDFLAGS)
+ INSTALL_LOG = build/installed_files.txt
+ 
+ setup.py = CC="$(CC)" CFLAGS="$(PY_CFLAGS)" LDSHARED="$(CC)" LDFLAGS="$(PY_LDFLAGS)" \
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_Makefile       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,84 @@
+$NetBSD: patch-tools_qemu-xen-traditional_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/Makefile.orig   2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/Makefile        2015-01-19 14:16:12.000000000 +0100
+@@ -1,7 +1,7 @@
+ # Makefile for QEMU.
+ 
+-include config-host.mak
+-include $(SRC_PATH)/rules.mak
++-include config-host.mak
++-include $(SRC_PATH)/rules.mak
+ 
+ .PHONY: all clean cscope distclean dvi html info install install-doc \
+       recurse-all speed tar tarbin test
+@@ -231,30 +231,30 @@
+ endif
+ 
+ install-doc: $(DOCS)
+-      mkdir -p "$(DESTDIR)$(docdir)"
+-      $(INSTALL) -m 644 qemu-doc.html  qemu-tech.html "$(DESTDIR)$(docdir)"
++      $(INSTALL_DIR) "$(DESTDIR)$(docdir)"
++      $(INSTALL_DATA) qemu-doc.html  qemu-tech.html "$(DESTDIR)$(docdir)"
+ ifndef CONFIG_WIN32
+-      mkdir -p "$(DESTDIR)$(mandir)/man1"
+-      $(INSTALL) -m 644 qemu.1 qemu-img.1 "$(DESTDIR)$(mandir)/man1"
+-      mkdir -p "$(DESTDIR)$(mandir)/man8"
+-      $(INSTALL) -m 644 qemu-nbd.8 "$(DESTDIR)$(mandir)/man8"
++      $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1"
++      $(INSTALL_DATA) qemu.1 qemu-img.1 "$(DESTDIR)$(mandir)/man1"
++      $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man8"
++      $(INSTALL_DATA) qemu-nbd.8 "$(DESTDIR)$(mandir)/man8"
+ endif
+ 
+ install: all $(if $(BUILD_DOCS),install-doc)
+-      mkdir -p "$(DESTDIR)$(bindir)"
++      $(INSTALL_DIR) "$(DESTDIR)$(bindir)"
+ ifneq ($(TOOLS),)
+       $(INSTALL_PROG) $(STRIP_OPT) $(TOOLS) "$(DESTDIR)$(bindir)"
+ endif
+ ifneq ($(BLOBS),)
+-      mkdir -p "$(DESTDIR)$(datadir)"
++      $(INSTALL_DIR) "$(DESTDIR)$(datadir)"
+       set -e; for x in $(BLOBS); do \
+-              $(INSTALL) -m 644 $(SRC_PATH)/pc-bios/$$x "$(DESTDIR)$(datadir)"; \
++              $(INSTALL_DATA) $(SRC_PATH)/pc-bios/$$x "$(DESTDIR)$(datadir)"; \
+       done
+ endif
+ ifndef CONFIG_WIN32
+-      mkdir -p "$(DESTDIR)$(datadir)/keymaps"
++      $(INSTALL_DIR) "$(DESTDIR)$(datadir)/keymaps"
+       set -e; for x in $(KEYMAPS); do \
+-              $(INSTALL) -m 644 $(SRC_PATH)/keymaps/$$x "$(DESTDIR)$(datadir)/keymaps"; \
++              $(INSTALL_DATA) $(SRC_PATH)/keymaps/$$x "$(DESTDIR)$(datadir)/keymaps"; \
+       done
+ endif
+       for d in $(TARGET_DIRS); do \
+@@ -275,7 +275,7 @@
+ 
+ # documentation
+ %.html: %.texi
+-      texi2html -monolithic -number $<
++      texi2html -monolithic -number-sections $<
+ 
+ %.info: %.texi
+       makeinfo $< -o $@
+@@ -284,15 +284,15 @@
+       texi2dvi $<
+ 
+ qemu.1: qemu-doc.texi
+-      $(SRC_PATH)/texi2pod.pl $< qemu.pod
++      perl $(SRC_PATH)/texi2pod.pl $< qemu.pod
+       pod2man --section=1 --center=" " --release=" " qemu.pod > $@
+ 
+ qemu-img.1: qemu-img.texi
+-      $(SRC_PATH)/texi2pod.pl $< qemu-img.pod
++      perl $(SRC_PATH)/texi2pod.pl $< qemu-img.pod
+       pod2man --section=1 --center=" " --release=" " qemu-img.pod > $@
+ 
+ qemu-nbd.8: qemu-nbd.texi
+-      $(SRC_PATH)/texi2pod.pl $< qemu-nbd.pod
++      perl $(SRC_PATH)/texi2pod.pl $< qemu-nbd.pod
+       pod2man --section=8 --center=" " --release=" " qemu-nbd.pod > $@
+ 
+ info: qemu-doc.info qemu-tech.info
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_block-raw-posix.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_block-raw-posix.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_block-raw-posix.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,62 @@
+$NetBSD: patch-tools_qemu-xen-traditional_block-raw-posix.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+- if given a block device, use the character device instead.
+
+--- tools/qemu-xen-traditional/block-raw-posix.c.orig  2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/block-raw-posix.c       2015-01-19 13:16:38.000000000 +0100
+@@ -65,6 +65,7 @@
+ #include <sys/disklabel.h>
+ #include <sys/dkio.h>
+ #include <sys/disk.h>
++#include <sys/param.h>
+ #endif
+ 
+ #ifdef __OpenBSD__
+@@ -72,6 +73,13 @@
+ #include <sys/disklabel.h>
+ #include <sys/dkio.h>
+ #endif
++#if defined(__NetBSD__)
++#include <sys/ioctl.h>
++#include <sys/disklabel.h>
++#include <sys/dkio.h>
++#define SLIST_ENTRY(x) int /*XXXX !*/
++#include <sys/disk.h>
++#endif
+ 
+ //#define DEBUG_FLOPPY
+ 
+@@ -1008,6 +1016,33 @@
+ {
+     BDRVRawState *s = bs->opaque;
+     int fd, open_flags, ret;
++#ifdef __NetBSD__
++    struct stat sb;
++    static char namebuf[MAXPATHLEN];
++    const char *dp;
++
++    if (lstat(filename, &sb) < 0) {
++      fprintf(stderr, "%s: stat failed: %s\n", filename, strerror(errno));
++      return -errno;
++    }
++    if (S_ISLNK(sb.st_mode)) {
++      fprintf(stderr, "%s: symolink links not supported by qemu-dm\n",
++          filename);
++      return -EINVAL;
++    }
++    if (S_ISBLK(sb.st_mode)) {
++      dp = strrchr(filename, '/');
++      if (dp == NULL) {
++              snprintf(namebuf, MAXPATHLEN, "r%s", filename);
++      } else {
++              snprintf(namebuf, MAXPATHLEN, "%.*s/r%s",
++                  (int)(dp - filename), filename, dp + 1);
++      }
++      fprintf(stderr, "%s is a block device", filename);
++      filename = namebuf;
++      fprintf(stderr, ", using %s\n", filename);
++    }
++#endif
+ 
+     posix_aio_init();
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_configure
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_configure:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_configure      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,41 @@
+$NetBSD: patch-tools_qemu-xen-traditional_configure,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/configure.orig  2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/configure       2015-01-20 22:58:07.000000000 +0100
+@@ -1089,7 +1089,7 @@
+ # Check if tools are available to build documentation.
+ if [ -x "`which texi2html 2>/dev/null`" ] && \
+    [ -x "`which pod2man 2>/dev/null`" ]; then
+-  build_docs="yes"
++#  build_docs="yes"
+ fi
+ 
+ ##########################################
+@@ -1124,7 +1124,7 @@
+   if test -z "$prefix" ; then
+       prefix="/usr/local"
+   fi
+-  mansuffix="/share/man"
++  mansuffix="/man"
+   datasuffix="/share/qemu"
+   docsuffix="/share/doc/qemu"
+   binsuffix="/bin"
+@@ -1216,6 +1216,8 @@
+ echo "MAKE=$make" >> $config_mak
+ echo "INSTALL=$install" >> $config_mak
+ echo "INSTALL_PROG=$install -m 0755" >> $config_mak
++echo "INSTALL_DATA=$install -m0644" >> $config_mak
++echo "INSTALL_DIR=$install -d -m0755 -p" >> $config_mak
+ echo "CC=$cc" >> $config_mak
+ echo "HOST_CC=$host_cc" >> $config_mak
+ echo "AR=$ar" >> $config_mak
+@@ -1493,7 +1495,9 @@
+ # XXX: suppress that
+ if [ "$bsd" = "yes" ] ; then
+   echo "#define O_LARGEFILE 0" >> $config_h
++  echo "#ifndef MAP_ANONYMOUS" >> $config_h
+   echo "#define MAP_ANONYMOUS MAP_ANON" >> $config_h
++  echo "#endif" >> $config_h
+   echo "#define _BSD 1" >> $config_h
+ fi
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_e1000.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_e1000.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_e1000.c     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,34 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_e1000.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+From sysutils/xentools33/patches/patch-ak.
+
+qemu-0.13.x will include this fix:
+http://git.qemu.org/qemu.git/commit/?id=9651ac55e5de0e1534d898316cc851af6ffc4334
+
+--- tools/qemu-xen-traditional/hw/e1000.c.orig 2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/e1000.c      2015-01-19 13:16:38.000000000 +0100
+@@ -265,16 +265,20 @@
+ 
+     s->eecd_state.old_eecd = val & (E1000_EECD_SK | E1000_EECD_CS |
+             E1000_EECD_DI|E1000_EECD_FWE_MASK|E1000_EECD_REQ);
++    if (!(E1000_EECD_CS & val))                        // CS inactive; nothing to do
++       return;
++    if (E1000_EECD_CS & (val ^ oldval)) {      // CS rise edge; reset state
++       s->eecd_state.val_in = 0;
++       s->eecd_state.bitnum_in = 0;
++       s->eecd_state.bitnum_out = 0;
++       s->eecd_state.reading = 0;
++    }
+     if (!(E1000_EECD_SK & (val ^ oldval)))    // no clock edge
+         return;
+     if (!(E1000_EECD_SK & val)) {             // falling edge
+         s->eecd_state.bitnum_out++;
+         return;
+     }
+-    if (!(val & E1000_EECD_CS)) {             // rising, no CS (EEPROM reset)
+-        memset(&s->eecd_state, 0, sizeof s->eecd_state);
+-        return;
+-    }
+     s->eecd_state.val_in <<= 1;
+     if (val & E1000_EECD_DI)
+         s->eecd_state.val_in |= 1;
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_ide.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_ide.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_ide.c       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,37 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_ide.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/ide.c.orig   2014-01-09 13:44:42.000000000 +0100
++++ tools/qemu-xen-traditional/hw/ide.c        2015-06-11 16:15:49.000000000 +0200
+@@ -757,10 +757,15 @@
+     put_le16(p + 58, oldsize >> 16);
+     if (s->mult_sectors)
+         put_le16(p + 59, 0x100 | s->mult_sectors);
+-    put_le16(p + 60, s->nb_sectors);
+-    put_le16(p + 61, s->nb_sectors >> 16);
++    if (s->nb_sectors > 0x10000000)
++      oldsize = 0x10000000; /* report only 128GB */
++    else
++      oldsize =  s->nb_sectors;
++    put_le16(p + 60, oldsize);
++    put_le16(p + 61, oldsize >> 16);
+     put_le16(p + 62, 0x07); /* single word dma0-2 supported */
+     put_le16(p + 63, 0x07); /* mdma0-2 supported */
++    put_le16(p + 64, 0x03); /* pio3-4 supported */
+     put_le16(p + 65, 120);
+     put_le16(p + 66, 120);
+     put_le16(p + 67, 120);
+@@ -812,13 +817,12 @@
+     put_le16(p + 53, 7); /* words 64-70, 54-58, 88 valid */
+     put_le16(p + 62, 7);  /* single word dma0-2 supported */
+     put_le16(p + 63, 7);  /* mdma0-2 supported */
+-    put_le16(p + 64, 0x3f); /* PIO modes supported */
+ #else
+     put_le16(p + 49, 1 << 9); /* LBA supported, no DMA */
+     put_le16(p + 53, 3); /* words 64-70, 54-58 valid */
+     put_le16(p + 63, 0x103); /* DMA modes XXX: may be incorrect */
+-    put_le16(p + 64, 1); /* PIO modes */
+ #endif
++    put_le16(p + 64, 3); /* pio3-4 supported */
+     put_le16(p + 65, 0xb4); /* minimum DMA multiword tx cycle time */
+     put_le16(p + 66, 0xb4); /* recommended DMA multiword tx cycle time */
+     put_le16(p + 67, 0x12c); /* minimum PIO cycle time without flow control */
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_pass-through.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/pass-through.c.orig  2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/pass-through.c       2015-01-19 13:16:38.000000000 +0100
+@@ -84,8 +84,6 @@
+  */
+ 
+ #include "pass-through.h"
+-#include "pci/header.h"
+-#include "pci/pci.h"
+ #include "pt-msi.h"
+ #include "qemu-xen.h"
+ #include "iomulti.h"
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.h
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.h:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pass-through.h      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,18 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_pass-through.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/pass-through.h.orig  2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/pass-through.h       2015-01-19 13:16:38.000000000 +0100
+@@ -20,8 +20,13 @@
+ 
+ #include "hw.h"
+ #include "pci.h"
++#ifdef __NetBSD__
++#include "pciutils/header.h"
++#include "pciutils/pci.h"
++#else
+ #include "pci/header.h"
+ #include "pci/pci.h"
++#endif
+ #include "exec-all.h"
+ #include "sys-queue.h"
+ #include "qemu-timer.h"
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_piix4acpi.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_piix4acpi.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_piix4acpi.c Sun Apr 18 12:31:26 2021
@@ -0,0 +1,17 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_piix4acpi.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/piix4acpi.c.orig     2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/piix4acpi.c  2015-01-19 13:16:38.000000000 +0100
+@@ -41,8 +41,12 @@
+ #define PIIX4ACPI_LOG(level, fmt, ...) do { if (level <= PIIX4ACPI_LOGLEVEL) qemu_log(fmt, ## __VA_ARGS__); } while (0)
+ 
+ #ifdef CONFIG_PASSTHROUGH
++#ifdef __NetBSD__
++#include <pciutils/header.h>
++#else
+ #include <pci/header.h>
+ #endif
++#endif
+ 
+ /* PM1a_CNT bits, as defined in the ACPI specification. */
+ #define SCI_EN            (1 <<  0)
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-graphics.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-graphics.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-graphics.c       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_pt-graphics.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/pt-graphics.c.orig   2015-01-19 16:14:46.000000000 +0100
++++ tools/qemu-xen-traditional/hw/pt-graphics.c        2015-01-19 16:14:51.000000000 +0100
+@@ -4,8 +4,6 @@
+ 
+ #include "pass-through.h"
+ #include "pci.h"
+-#include "pci/header.h"
+-#include "pci/pci.h"
+ 
+ #include <unistd.h>
+ #include <sys/ioctl.h>
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.c    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_pt-msi.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/pt-msi.c.orig        2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/pt-msi.c     2015-01-19 13:16:38.000000000 +0100
+@@ -22,6 +22,10 @@
+ #include "pt-msi.h"
+ #include <sys/mman.h>
+ 
++#ifdef __NetBSD__
++#define MAP_LOCKED MAP_WIRED
++#endif
++
+ void msi_set_enable(struct pt_dev *dev, int en)
+ {
+     uint16_t val = 0;
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.h
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.h:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_hw_pt-msi.h    Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-tools_qemu-xen-traditional_hw_pt-msi.h,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/hw/pt-msi.h.orig        2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/hw/pt-msi.h     2015-01-19 13:16:38.000000000 +0100
+@@ -1,7 +1,6 @@
+ #ifndef _PT_MSI_H
+ #define _PT_MSI_H
+ 
+-#include "pci/pci.h"
+ #include "pass-through.h"
+ 
+ #define  PCI_CAP_ID_MSI     0x05    /* Message Signalled Interrupts */
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak        Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-tools_qemu-xen-traditional_i386-dm_hookstarget.mak,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen-traditional/i386-dm/hookstarget.mak.orig    2014-10-06 17:50:24.000000000 +0200
++++ tools/qemu-xen-traditional/i386-dm/hookstarget.mak 2015-01-19 13:16:38.000000000 +0100
+@@ -2,5 +2,5 @@
+ 
+ install-hook:
+       $(INSTALL_DIR) "$(DESTDIR)/$(bindir)"
+-      $(INSTALL_DIR) "$(DESTDIR)/$(configdir)"
+-      $(INSTALL_PROG) $(QEMU_ROOT)/i386-dm/qemu-ifup-$(IOEMU_OS) "$(DESTDIR)/$(configdir)/qemu-ifup"
++      $(INSTALL_DIR) "$(DESTDIR)/$(XEN_EXAMPLES_DIR)/scripts"
++      $(INSTALL_PROG) $(QEMU_ROOT)/i386-dm/qemu-ifup-$(IOEMU_OS) "$(DESTDIR)/$(XEN_EXAMPLES_DIR)/scripts/qemu-ifup"
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_net.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_net.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_net.c  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,46 @@
+$NetBSD: patch-tools_qemu-xen-traditional_net.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+--- tools/qemu-xen-traditional/net.c.orig      2016-11-29 17:36:38.000000000 +0100
++++ tools/qemu-xen-traditional/net.c   2017-03-29 18:16:54.000000000 +0200
+@@ -990,6 +990,7 @@
+ #define DEFAULT_NETWORK_DOWN_SCRIPT ""
+ #endif
+ 
++#if !defined(CONFIG_STUBDOM)
+ static int launch_script(const char *setup_script, const char *ifname,
+                          const char *script_arg, int fd)
+ {
+@@ -1028,6 +1029,7 @@
+         }
+     return 0;
+ }
++#endif
+ 
+ static int net_tap_init(VLANState *vlan, const char *model,
+                         const char *name, const char *ifname1,
+@@ -1048,12 +1050,14 @@
+ 
+     if (!setup_script || !strcmp(setup_script, "no"))
+         setup_script = "";
++#if !defined(CONFIG_STUBDOM)
+     if (setup_script[0] != '\0') {
+       if (launch_script(setup_script, ifname, script_arg, fd)) {
+           close(fd);
+           return -1;
+       }
+     }
++#endif
+     s = net_tap_fd_init(vlan, model, name, fd);
+     if (!s)
+         return -1;
+@@ -1965,9 +1969,11 @@
+             if (vc->fd_read == tap_receive) {
+                 TAPState *s = vc->opaque;
+ 
++#ifndef CONFIG_STUBDOM
+                 if (s->down_script[0])
+                     launch_script(s->down_script, s->down_script_arg,
+                                 s->script_arg, s->fd);
++#endif
+             }
+ #if defined(CONFIG_VDE)
+             if (vc->fd_read == vde_from_qemu) {
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_xen-hooks.mak
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_xen-hooks.mak:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen-traditional_xen-hooks.mak  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,34 @@
+$NetBSD: patch-tools_qemu-xen-traditional_xen-hooks.mak,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+enable PCI passthrough when pciutils is present
+
+--- tools/qemu-xen-traditional/xen-hooks.mak.orig      2020-12-08 16:54:20.000000000 +0100
++++ tools/qemu-xen-traditional/xen-hooks.mak   2020-12-09 16:07:04.817171636 +0100
+@@ -61,17 +61,25 @@
+ ifdef CONFIG_STUBDOM
+ CONFIG_PASSTHROUGH=1
+ else
+-  ifeq (,$(wildcard /usr/include/pci))
++  ifeq ($(CONFIG_NetBSD), y)
++CONFIG_PASSTHROUGH=1
++  else
++    ifeq (,$(wildcard /usr/include/pci))
+ $(warning === pciutils-dev package not found - missing /usr/include/pci)
+ $(warning === PCI passthrough capability has been disabled)
+-  else
++    else
+ CONFIG_PASSTHROUGH=1
++    endif
+   endif
+ endif
+ 
+ ifdef CONFIG_PASSTHROUGH
+ OBJS+= pass-through.o pt-msi.o pt-graphics.o
++ifeq ($(CONFIG_NetBSD), y)
++LIBS += -Wl,-R${PREFIX}/lib -L${PREFIX}/lib -lpciutils -lpci
++else
+ LIBS += -lpci
++endif
+ CFLAGS += -DCONFIG_PASSTHROUGH 
+ $(info === PCI passthrough capability has been enabled ===)
+ endif
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_audio_audio.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_audio_audio.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_audio_audio.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-tools_qemu-xen_audio_audio.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen/audio/audio.c.orig  2020-12-08 16:58:46.000000000 +0100
++++ tools/qemu-xen/audio/audio.c       2020-12-09 16:09:37.068801135 +0100
+@@ -890,6 +890,7 @@
+     if (audio_get_pdo_in(hw->s->dev)->mixing_engine) {
+         return audio_pcm_sw_read(sw, buf, size);
+     } else {
++#undef read
+         return hw->pcm_ops->read(hw, buf, size);
+     }
+ }
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_configure
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_configure:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_configure  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,14 @@
+$NetBSD: patch-tools_qemu-xen_configure,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+-lrt is needed for shm_open()
+
+--- tools/qemu-xen/configure.orig      2019-09-27 12:21:35.000000000 +0200
++++ tools/qemu-xen/configure   2020-05-08 20:09:00.341400664 +0200
+@@ -841,6 +841,7 @@
+   audio_drv_list="oss try-sdl"
+   audio_possible_drivers="oss sdl"
+   oss_lib="-lossaudio"
++  LIBS="-lrt $LIBS"
+   HOST_VARIANT_DIR="netbsd"
+   supported_os="yes"
+ ;;
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap-bsd.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap-bsd.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap-bsd.c      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,44 @@
+$NetBSD: patch-tools_qemu-xen_net_tap-bsd.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/qemu-xen/net/tap-bsd.c.orig  2020-05-18 10:41:00.816005830 +0200
++++ tools/qemu-xen/net/tap-bsd.c       2020-05-18 15:02:30.497691415 +0200
+@@ -40,7 +40,7 @@
+ #include <sys/param.h>
+ #endif
+ 
+-#ifndef __FreeBSD__
++#if !defined(__FreeBSD__) && !defined(__NetBSD__)
+ int tap_open(char *ifname, int ifname_size, int *vnet_hdr,
+              int vnet_hdr_required, int mq_required, Error **errp)
+ {
+@@ -112,7 +112,7 @@
+     return fd;
+ }
+ 
+-#else /* __FreeBSD__ */
++#else /* __FreeBSD__ || __NetBSD__ */
+ 
+ #define PATH_NET_TAP "/dev/tap"
+ 
+@@ -137,6 +137,7 @@
+     }
+ 
+     if (ifname[0] != '\0') {
++#ifdef SIOCSIFNAME
+         /* User requested the interface to have a specific name */
+         s = socket(AF_LOCAL, SOCK_DGRAM, 0);
+         if (s < 0) {
+@@ -153,10 +154,12 @@
+             close(fd);
+             return -1;
+         }
++#else
++        pstrcpy(ifname, ifname_size, ifr.ifr_name);
++#endif
+     } else {
+         pstrcpy(ifname, ifname_size, ifr.ifr_name);
+     }
+-
+     return fd;
+ }
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_qemu-xen_net_tap.c  Sun Apr 18 12:31:26 2021
@@ -0,0 +1,70 @@
+$NetBSD: patch-tools_qemu-xen_net_tap.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+From Roman Shaposhnik via xen-devel: pass bridge name to ifup script
+
+--- tools/qemu-xen/net/tap.c.orig
++++ tools/qemu-xen/net/tap.c
+@@ -62,7 +62,7 @@
+     Notifier exit;
+ } TAPState;
+ 
+-static void launch_script(const char *setup_script, const char *ifname,
++static void launch_script(const char *setup_script, const char *ifname, const char *bridge,
+                           int fd, Error **errp);
+ 
+ static void tap_send(void *opaque);
+@@ -300,7 +300,7 @@
+     Error *err = NULL;
+ 
+     if (s->down_script[0]) {
+-        launch_script(s->down_script, s->down_script_arg, s->fd, &err);
++        launch_script(s->down_script, s->down_script_arg, "bn1", s->fd, &err);
+         if (err) {
+             error_report_err(err);
+         }
+@@ -397,7 +397,7 @@
+     return s;
+ }
+ 
+-static void launch_script(const char *setup_script, const char *ifname,
++static void launch_script(const char *setup_script, const char *ifname, const char *bridge,
+                           int fd, Error **errp)
+ {
+     int pid, status;
+@@ -422,6 +422,7 @@
+         parg = args;
+         *parg++ = (char *)setup_script;
+         *parg++ = (char *)ifname;
++      *parg++ = (char *)bridge;
+         *parg = NULL;
+         execv(setup_script, args);
+         _exit(1);
+@@ -607,7 +608,7 @@
+ 
+ static int net_tap_init(const NetdevTapOptions *tap, int *vnet_hdr,
+                         const char *setup_script, char *ifname,
+-                        size_t ifname_sz, int mq_required, Error **errp)
++                        size_t ifname_sz, const char *bridge, int mq_required, Error **errp)
+ {
+     Error *err = NULL;
+     int fd, vnet_hdr_required;
+@@ -629,7 +630,7 @@
+     if (setup_script &&
+         setup_script[0] != '\0' &&
+         strcmp(setup_script, "no") != 0) {
+-        launch_script(setup_script, ifname, fd, &err);
++        launch_script(setup_script, ifname, bridge, fd, &err);
+         if (err) {
+             error_propagate(errp, err);
+             close(fd);
+@@ -918,7 +919,9 @@
+ 
+         for (i = 0; i < queues; i++) {
+             fd = net_tap_init(tap, &vnet_hdr, i >= 1 ? "no" : script,
+-                              ifname, sizeof ifname, queues > 1, errp);
++                              ifname, sizeof ifname, 
++                            tap->has_br ? tap->br : "bn1",
++                            queues > 1, errp);
+             if (fd == -1) {
+                 return -1;
+             }
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_xenpaging_xenpaging.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_xenpaging_xenpaging.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_xenpaging_xenpaging.c       Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-tools_xenpaging_xenpaging.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Fix "error: 'buffer' may be used uninitialized"
+
+--- tools/xenpaging/xenpaging.c.orig   2021-04-17 14:43:41.053494277 +0200
++++ tools/xenpaging/xenpaging.c        2021-04-17 14:44:17.167271008 +0200
+@@ -180,7 +180,7 @@
+ 
+ static void *init_page(void)
+ {
+-    void *buffer;
++    void *buffer = NULL; /* XXX gcc */
+ 
+     /* Allocated page memory */
+     errno = posix_memalign(&buffer, XC_PAGE_SIZE, XC_PAGE_SIZE);
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_xenstore_xs_lib.c
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_xenstore_xs_lib.c:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_xenstore_xs_lib.c   Sun Apr 18 12:31:26 2021
@@ -0,0 +1,13 @@
+$NetBSD: patch-tools_xenstore_xs_lib.c,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/xenstore/xs_lib.c.orig
++++ tools/xenstore/xs_lib.c
+@@ -52,7 +52,7 @@ static const char *xs_daemon_path(void)
+ const char *xs_daemon_tdb(void)
+ {
+       static char buf[PATH_MAX];
+-      snprintf(buf, sizeof(buf), "%s/tdb", xs_daemon_rootdir());
++      snprintf(buf, sizeof(buf), "%s/tdb", xs_daemon_rundir());
+       return buf;
+ }
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-tools_xl_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-tools_xl_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-tools_xl_Makefile Sun Apr 18 12:31:26 2021
@@ -0,0 +1,16 @@
+$NetBSD: patch-tools_xl_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- tools/xl/Makefile.orig     2021-01-26 12:35:19.000000000 +0100
++++ tools/xl/Makefile  2021-01-26 19:21:03.038848363 +0100
+@@ -43,9 +43,9 @@
+ .PHONY: install
+ install: all
+       $(INSTALL_DIR) $(DESTDIR)$(sbindir)
+-      $(INSTALL_DIR) $(DESTDIR)$(BASH_COMPLETION_DIR)
++      $(INSTALL_DIR) $(DESTDIR)$(XEN_EXAMPLES_DIR)
+       $(INSTALL_PROG) xl $(DESTDIR)$(sbindir)
+-      $(INSTALL_DATA) bash-completion $(DESTDIR)$(BASH_COMPLETION_DIR)/xl
++      $(INSTALL_DATA) bash-completion $(DESTDIR)$(XEN_EXAMPLES_DIR)/xl.bash
+ 
+ .PHONY: uninstall
+ uninstall:
Index: pkgsrc/sysutils/xentools415/patches/patch-xen_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-xen_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-xen_Makefile      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,16 @@
+$NetBSD: patch-xen_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+Use a more strict pattern; on NetBSD it includes some extra compiler
+outputs.
+
+--- xen/Makefile.orig  2020-12-10 16:06:07.432987067 +0100
++++ xen/Makefile       2020-12-10 16:06:10.485550293 +0100
+@@ -411,7 +411,7 @@
+         echo "#ifndef __ASM_OFFSETS_H__"; \
+         echo "#define __ASM_OFFSETS_H__"; \
+         echo ""; \
+-        sed -rne "/^[^#].*==>/{s:.*==>(.*)<==.*:\1:; s: [\$$#]: :; p;}"; \
++        sed -rne "/^[^#]ascii.*==>/{s:.*==>(.*)<==.*:\1:; s: [\$$#]: :; p;}"; \
+         echo ""; \
+         echo "#endif") <$< >$@
+ 
Index: pkgsrc/sysutils/xentools415/patches/patch-xen_Rules.mk
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-xen_Rules.mk:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-xen_Rules.mk      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,12 @@
+$NetBSD: patch-xen_Rules.mk,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+--- xen/Rules.mk.orig  2018-04-23 14:50:02.000000000 +0200
++++ xen/Rules.mk       2018-04-23 14:50:32.000000000 +0200
+@@ -1,4 +1,7 @@
+ 
++#reset cflags. Why is it needed in pkgsrc ?
++CFLAGS=
++
+ -include $(BASEDIR)/include/config/auto.conf
+ 
+ include $(XEN_ROOT)/Config.mk
Index: pkgsrc/sysutils/xentools415/patches/patch-xen_arch_x86_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-xen_arch_x86_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-xen_arch_x86_Makefile     Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-xen_arch_x86_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+also filter out flags added by pkgsrc
+
+--- xen/arch/x86/Makefile.orig 2020-12-11 18:09:56.686501836 +0100
++++ xen/arch/x86/Makefile      2020-12-11 18:10:47.737620837 +0100
+@@ -252,7 +252,7 @@
+ 
+ efi.lds: AFLAGS-y += -DEFI
+ xen.lds efi.lds: xen.lds.S
+-      $(CPP) -P $(filter-out -Wa$(comma)%,$(a_flags)) -MQ $@ -o $@ $<
++      $(CPP) -P $(filter-out -Wa$(comma)% -g3,$(a_flags)) -MQ $@ -o $@ $<
+ 
+ boot/mkelf32: boot/mkelf32.c
+       $(HOSTCC) $(HOSTCFLAGS) -o $@ $<
Index: pkgsrc/sysutils/xentools415/patches/patch-xen_include_Makefile
diff -u /dev/null pkgsrc/sysutils/xentools415/patches/patch-xen_include_Makefile:1.1
--- /dev/null   Sun Apr 18 12:31:27 2021
+++ pkgsrc/sysutils/xentools415/patches/patch-xen_include_Makefile      Sun Apr 18 12:31:26 2021
@@ -0,0 +1,15 @@
+$NetBSD: patch-xen_include_Makefile,v 1.1 2021/04/18 12:31:26 bouyer Exp $
+
+also filter out flags added by pkgsrc
+
+--- xen/include/Makefile.orig  2020-12-10 17:08:48.270718042 +0100
++++ xen/include/Makefile       2020-12-10 17:11:56.553825047 +0100
+@@ -57,7 +57,7 @@
+       mv -f $@.new $@
+ 
+ compat/%.i: compat/%.c Makefile
+-      $(CPP) $(filter-out -Wa$(comma)% -include %/include/xen/config.h,$(XEN_CFLAGS)) $(cppflags-y) -o $@ $<
++      $(filter-out -Wa$(comma)% -g3 -include %/include/xen/config.h,$(CPP) $(XEN_CFLAGS)) $(cppflags-y) -o $@ $<
+ 
+ compat/%.c: public/%.h xlat.lst Makefile $(BASEDIR)/tools/compat-build-source.py
+       mkdir -p $(@D)



Home | Main Index | Thread Index | Old Index