[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / emulators / qemu

File: [cvs.NetBSD.org] / pkgsrc / emulators / qemu / Makefile (download)

Revision 1.216, Fri Aug 16 15:12:19 2019 UTC (4 years, 8 months ago) by adam
Branch: MAIN
Changes since 1.215: +4 -4 lines

qemu: updated to 4.1.0

4.1.0:

New deprecated options and features

The "-virtfs_synth" option is now deprecated. Please use "-fsdev synth" and "-device virtio-9p-..." instead.
The "-numa node,mem" sub-option is now deprecated. Please use "-numa node,memdev" instead.
Default memory distribution between NUMA nodes is now deprecated. Please specify memory per NUMA node explicitly using "-numa node,memdev"
Fallback to normal RAM allocation if QEMU is not able to allocate from the "-mem-path" provided file/filesystem is now deprecated. Make sure that host has sufficient resources on the filesystem/file pointed be "-mem-path".

Arm

QEMU now supports emulating an FPU for Cortex-M CPUs, and the Cortex-M4 and Cortex-M33 now provide the FPU.
The Cortex-R5F now correctly provides an FPU with registers D0-D15 only, rather than incorrectly providing also D16-D31.
The build config files have been switched to the new Kconfig system, so that a QEMU with individual boards can be built more easily.
The ARMv8.5-RNG extension is supported, for cpu generated random numbers.
The Exynos4210 SoC model now supports the PL330 DMA controllers.
Some bugs in handling of GICv3 ICC_CTLR_EL3 and ICH_VMCR_EL2 register writes have been fixed.
The built-in bootloader now handles loading AArch64 kernel Image files which are larger than 128MB.
The GICv3 now correctly reports GICD_TYPER.SecurityExtn as 0 if GICD_CTLR.DS is 1.
New board model: swift-bmc
New board-model: sbsa-ref (an AArch64 system intended for development of the server firmware and kernel software stack)
The Aspeed SoC/boards now support the RTC device and the xdma device
The i.mx7 PCI controller emulation has been improved so it can boot current Linux krenels
The pl031 RTC device now correctly makes the guest RTC track advances in host RTC time between a VM state save and a later reload.

MIPS

Improved marking referenced memory pages as executable (it is now restricted to necessary cases only).
Fixed logic errors for certain cases of MFTR and MTTR instruction handling.
Fixed some corner cases of MSA FCLASS.<W|D> instruction handling.
Improved 'division by zero' cases in MSA ASE instructions DIV_<U|S>.<B|H|W|D> and MOD_<U|S>.<B|H|W|D> - they are now handled both in QEMU and on the reference hardware the same way.
Fixed emulation of a number of MSA ASE instructions on big endian hosts. Affected instructions are LD.<B|H|W|D>, ST.<B|H|W|D>, COPY_S.<B|H|W|D>, COPY_U.<B|H|W>, INSERT.<B|H|W|D>, ILVEV.<B|H|W|D>, ILVOD.<B|H|W|D>, ILVL.<B|H|W|D>, ILVR.<B|H|W|D>, PCKEV.<B|H|W|D>, and PCKOD.<B|H|W|D>.
Improved emulation performance of numerous MSA instructions, mostly integer and data permuting operations.
Nios2

PowerPC

NVIDIA V100 GPU/NVLink2 passthrough for spapr using VFIO PCI
The TCG implementation of the Power9 DARN instruction now produces random numbers, instead of indicating failure.
pseries machine now supports KVM acceleration (kernel_irqchip=on) of the XIVE interrupt controller
pseries now defaults to XIVE interrupt controller if using pseries-4.1 machine version, POWER9 cpu and a guest OS which supports it
pseries now supports hot-plug of PCI bridges and hot-plug and unplug of devices under PCI bridges
powernv now supports dumping the device tree with the "dumpdtb" machine option
A number of vector (Altivec and VSX) instructions have had their implementations optimized in TCG

RISC-V

Arbitrary bits in SIP can no longer be set.
A new "spike" machine has been defined, with the old machines being deprecated.
sfence.vma can no longer execute from userspace.
Single-stepping over branches and jumps now works.
A handful of illegal instructions (all compressed) are now handled correctly, as opposed to being treated as NOPs.
Support for version 1.11.0 of the privileged specification has been added.
SiFive's PRCI now supports reading and writing all the device registers.
The ISA of the target machine can be controlled from the command line.
QEMU provides a cpu-topology device tree node on targets that support device trees.
Load reservations are broken by both store conditional and scheduling.
The 32-bit syscall ABI has various bug fixes.
The PCI bus-range property is now set correctly.

s390

The bios now supports IPL (boot) from ECKD DASD assigned to the guest via vfio-ccw.
The bios now tolerates the presence of bootmap signature entries written by zipl.
All Vector Instructions introduced with the "Vector Facility" have been implemented for TCG.
The "Vector Facility" is now indicated in the "qemu" cpu model, which has been updated to a stripped-down z13.
More facilities and gen15 machines (official name not yet known) have been added to the cpu model.
This also includes the AP Queue Interruption Facility, which allows to use interrupts for vfio-ap devices, if supported by the host kernel.
vfio-ccw now supports forwarding HALT SUBCHANNEL and CLEAR SUBCHANNEL to the device.

SPARC

sun4m and sun4u fixes when running with -vga none (OpenBIOS)
sunhme fixes when running on a TAP network interface

Tricore

Add FTOIZ/UTOF/QSEED insns
Fix sync of hflags and swapped args of RRPW_INSERT

x86

New Hygon Dhyana CPU model
New Intel SnowRidge CPU model
The host-cache-info CPU option now affects the TOPOEXT CPUID leaf (0x8000001D)
The RDRAND extension is implemented for TCG.
md-clear and mds-no feature flags, for detection and mitigation of MDS vulnerabilities (CVE-2018-12126, CVE-2018-12127, CVE-2018-12130, CVE-2019-11091)
All x86 CPU models are now versioned
CPU die topology can now be configured using the -smp ...,dies=... option

Xtensa

Implement memory protection unit (MPU) option
Implement Exclusive Access option

# $NetBSD: Makefile,v 1.216 2019/08/16 15:12:19 adam Exp $

DISTNAME=	qemu-4.1.0
CATEGORIES=	emulators
MASTER_SITES=	https://download.qemu.org/
EXTRACT_SUFX=	.tar.xz

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	http://www.qemu-project.org/
COMMENT=	CPU emulator using dynamic translation
LICENSE=	gnu-gpl-v2 AND gnu-lgpl-v2.1 AND mit AND modified-bsd

USE_CURSES=		resize_term wide
USE_LANGUAGES+=		c c++
USE_TOOLS+=		bison flex gmake makeinfo perl:build pod2man pkg-config
FAKE_NCURSES=		yes
UNLIMIT_RESOURCES=	datasize
HAS_CONFIGURE=		yes

GMAKE_REQD=		4.1 # needed for docs
TOOL_DEPENDS+=		${PYPKGPREFIX}-sphinx-[0-9]*:../../textproc/py-sphinx

SUBST_CLASSES+=			prefix
SUBST_STAGE.prefix=		pre-configure
SUBST_MESSAGE.prefix=		Setting PREFIX
SUBST_FILES.prefix+=		configure
SUBST_VARS.prefix+=		PREFIX

SUBST_CLASSES+=			sphinx-build
SUBST_STAGE.sphinx-build=	pre-configure
SUBST_MESSAGE.sphinx-build=	Fix hardcoded sphinx-build
SUBST_FILES.sphinx-build+=	Makefile configure
SUBST_FILES.sphinx-build+=	roms/skiboot/doc/Makefile
SUBST_FILES.sphinx-build+=	roms/u-boot/Documentation/Makefile
SUBST_SED.sphinx-build+=	-e 's/sphinx-build/sphinx-build${PYVERSSUFFIX}/g'

.include "options.mk"

.include "../../mk/bsd.prefs.mk"

CONFIGURE_ARGS+=	--prefix=${PREFIX}
CONFIGURE_ARGS+=	--interp-prefix=${PREFIX}/share/qemu
CONFIGURE_ARGS+=	--sysconfdir=${PKG_SYSCONFDIR}
CONFIGURE_ARGS+=	--python=${PYTHONBIN}
CONFIGURE_ARGS+=	--smbd=${PREFIX}/sbin/smbd
CONFIGURE_ARGS+=	--mandir=${PREFIX}/${PKGMANDIR}
CONFIGURE_ARGS+=	--enable-curses
CONFIGURE_ARGS+=	--enable-docs
CONFIGURE_ARGS+=	--enable-jemalloc
CONFIGURE_ARGS+=	--disable-opengl
CONFIGURE_ENV+=		mansuffix=/${PKGMANDIR}

.if defined(PKGSRC_USE_SSP)
# do not add flags to everything
PKGSRC_USE_SSP=		no
CONFIGURE_ARGS+=	--enable-stack-protector
.endif

NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-aarch64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-alpha
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-arm
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-cris
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-hppa
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-i386
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-lm32
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-m68k
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-microblaze
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-microblazeel
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-mips
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-mips64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-mips64el
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-mipsel
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-moxie
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-nios2
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-or1k
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-ppc
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-ppc64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-riscv32
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-riscv64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-s390x
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-sh4
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-sh4eb
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-sparc
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-sparc64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-tricore
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-unicore32
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-x86_64
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-xtensa
NOT_PAX_MPROTECT_SAFE+=	bin/qemu-system-xtensaeb

PKG_SYSCONFSUBDIR=	qemu

REPLACE_PERL+=		scripts/texi2pod.pl

INSTALLATION_DIRS=	${PKGMANDIR}/man1 share/doc/qemu

UE_ARCHS+=		aarch64 aarch64_be
UE_ARCHS+=		alpha arm armeb cris
UE_ARCHS+=		hppa
UE_ARCHS+=		i386
UE_ARCHS+=		m68k microblaze microblazeel
UE_ARCHS+=		mips mips64 mips64el mipsel mipsn32 mipsn32el
UE_ARCHS+=		nios2
UE_ARCHS+=		or1k ppc ppc64 ppc64le ppc64abi32
UE_ARCHS+=		riscv32 riscv64
UE_ARCHS+=		s390x sh4 sh4eb sparc sparc32plus sparc64
UE_ARCHS+=		tilegx
UE_ARCHS+=		x86_64 xtensa xtensaeb

.if ${OPSYS} == "NetBSD"
USER_EMUL=		i386 x86_64 sparc sparc64
PLIST.nbd=		yes
.elif !empty(OPSYS:M*BSD) || ${OPSYS} == "DragonFly"
USER_EMUL=		i386 x86_64 sparc sparc64
PLIST.nbd=		yes
.elif ${OPSYS} == "Darwin"
USER_EMUL=
CONFIGURE_ARGS+=	--disable-bsd-user
PLIST.nbd=		yes
.elif ${OPSYS} == "Linux"
USER_EMUL=		${UE_ARCHS}
PLIST.bridge-helper=	yes
PLIST.nbd=		yes
PLIST.ivshmem=		yes
PLIST.pr-helper=	yes
PLIST.virtfs-proxy-helper=yes
.elif !empty(MACHINE_PLATFORM:MSunOS-5.11-*)
PLIST.nbd=		yes
CONFIGURE_ARGS+=	--disable-coroutine-pool
.endif

PLIST_VARS+=		${UE_ARCHS} bridge-helper ivshmem nbd pr-helper virtfs-proxy-helper
.for pvar in ${USER_EMUL}
PLIST.${pvar}=		yes
.endfor

TEST_TARGET=		check

post-install:
	${INSTALL_DATA} ${FILESDIR}/Makefile.multinode-NetBSD \
		${DESTDIR}${PREFIX}/share/doc/qemu/
	${RM} -f ${DESTDIR}${PREFIX}/share/doc/qemu/interop/.buildinfo

# On Darwin, qemu uses Cocoa and CoreAudio
.if ${OPSYS} != "Darwin"
.include "../../mk/oss.buildlink3.mk"
.endif
.include "../../archivers/lzo/buildlink3.mk"
.include "../../devel/glib2/buildlink3.mk"
.include "../../devel/jemalloc/buildlink3.mk"
.include "../../devel/snappy/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
.include "../../graphics/hicolor-icon-theme/buildlink3.mk"
.include "../../graphics/png/buildlink3.mk"
.include "../../lang/python/extension.mk"
.include "../../security/libgcrypt/buildlink3.mk"
.include "../../www/curl/buildlink3.mk"
.include "../../x11/pixman/buildlink3.mk"
.include "../../mk/curses.buildlink3.mk"
.include "../../mk/jpeg.buildlink3.mk"
.include "../../mk/pthread.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"