mirror of
https://gitlab.com/buildroot.org/buildroot.git
synced 2026-08-01 21:23:51 -09:00
Bump Xen from 4.19.5 to 4.21.1. Resolved in version bump: - 0002-Arm-platforms-fix-build-with-gcc15.patch Upstream: https://xenbits.xen.org/gitweb/?p=xen.git;a=commitdiff;h=39f95089e2ba15c5438ce904c0cbbd8d79d3e6e7 The git-checkout.sh fix for non-master branch checkout is now included: https://xenbits.xenproject.org/gitweb/?p=xen.git;a=commitdiff;h=01fb23dd71006d87e874f310e9c50f31582f274e Remaining patches refreshed for updated context: - 0001-No-trace-backend.patch (Buildroot specific, cross-compile workaround) - 0002-Update-linker-flags.patch (Buildroot specific, cross-compile workaround) Starting with Xen 4.20, qemu-xen is no longer bundled in the release tarball. Add a new qemu-xen package that provides the qemu-xen source tree with required meson subprojects pre-populated. This avoids any network access during the build. New dependencies: - qemu-xen (provides qemu-xen source for tools build) - host-python-distlib (needed by QEMU's mkvenv) The qemu-xen package: - Fetches qemu-xen via git (without recursive submodules to avoid massive ROM downloads) - Pre-populates required meson subprojects (keycodemapdb, berkeley-softfloat-3, berkeley-testfloat-3) from gitlab archives - Applies packagefiles overlays (meson.build) for subprojects that need them - Removes .wrap files for unused subprojects to prevent any network access attempts during the build - Patches xen_native.h #error to #warning for cross-compile Tested with: support/testing/run-tests \ -d dl -o output_folder \ tests.package.test_xen.TestXenAarch64 support/testing/run-tests \ -d dl -o output_folder \ tests.package.test_xen.TestXenArmv7 Both aarch64 and arm32 runtime tests pass. Quick build defconfig used for iteration: BR2_aarch64=y BR2_TOOLCHAIN_EXTERNAL=y BR2_TOOLCHAIN_EXTERNAL_BOOTLIN=y BR2_TOOLCHAIN_EXTERNAL_BOOTLIN_AARCH64_GLIBC_STABLE=y BR2_PACKAGE_XEN=y BR2_PACKAGE_XEN_HYPERVISOR=y BR2_PACKAGE_XEN_TOOLS=y # BR2_TARGET_ROOTFS_TAR is not set Related prior attempts: https://patchwork.ozlabs.org/project/buildroot/patch/20260211055138.719459-1-matthew.l.weber@gmail.com/ https://patchwork.ozlabs.org/project/buildroot/patch/20251007164756.893264-1-titouan.christophe@mind.be/ Cc: Neal Frager <neal.frager@amd.com> Cc: Julien Olivain <ju.o@free.fr> Cc: Vincent Stehlé <vincent.stehle@arm.com> Cc: Titouan Christophe <titouan.christophe@mind.be> Cc: John Ernberg <john.ernberg@actia.se> Signed-off-by: Matthew Weber <mathew.l.weber3@boeing.com> [Julien: - update qemu-xen package url in Config.in - split XEN_DEPENDENCIES lines - add COPYING license hash in qemu-xen.hash ] Signed-off-by: Julien Olivain <ju.o@free.fr>
94 lines
2.4 KiB
Makefile
94 lines
2.4 KiB
Makefile
################################################################################
|
|
#
|
|
# Xen
|
|
#
|
|
################################################################################
|
|
|
|
XEN_VERSION = 4.21.1
|
|
XEN_SITE = https://downloads.xenproject.org/release/xen/$(XEN_VERSION)
|
|
XEN_SELINUX_MODULES = systemd udev xen
|
|
XEN_LICENSE = GPL-2.0
|
|
XEN_LICENSE_FILES = COPYING LICENSES/GPL-2.0
|
|
XEN_CPE_ID_VENDOR = xen
|
|
XEN_CPE_ID_PREFIX = cpe:2.3:o
|
|
|
|
XEN_DEPENDENCIES = \
|
|
host-acpica \
|
|
host-meson \
|
|
host-pkgconf \
|
|
host-python3 \
|
|
host-python-distlib
|
|
|
|
# Calculate XEN_ARCH
|
|
ifeq ($(ARCH),aarch64)
|
|
XEN_ARCH = arm64
|
|
else ifeq ($(ARCH),arm)
|
|
XEN_ARCH = arm32
|
|
endif
|
|
|
|
XEN_CONF_OPTS = \
|
|
--disable-golang \
|
|
--disable-ocamltools \
|
|
--with-initddir=/etc/init.d \
|
|
--disable-werror
|
|
|
|
# Xen 4.20+ would normally fetch qemu-xen via git at build time; we
|
|
# pre-provide it via the qemu-xen package instead.
|
|
XEN_CONF_ENV = PYTHON=$(HOST_DIR)/bin/python3
|
|
XEN_MAKE_ENV = \
|
|
XEN_TARGET_ARCH=$(XEN_ARCH) \
|
|
CROSS_COMPILE=$(TARGET_CROSS) \
|
|
HOST_EXTRACFLAGS="-Wno-error" \
|
|
XEN_HAS_CHECKPOLICY=n \
|
|
$(TARGET_CONFIGURE_OPTS)
|
|
|
|
ifeq ($(BR2_PACKAGE_XEN_HYPERVISOR),y)
|
|
XEN_MAKE_OPTS += dist-xen
|
|
XEN_INSTALL_IMAGES = YES
|
|
define XEN_INSTALL_IMAGES_CMDS
|
|
cp $(@D)/xen/xen $(BINARIES_DIR)
|
|
endef
|
|
else
|
|
XEN_CONF_OPTS += --disable-xen
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_XEN_TOOLS),y)
|
|
XEN_DEPENDENCIES += \
|
|
dtc \
|
|
libaio \
|
|
libglib2 \
|
|
ncurses \
|
|
openssl \
|
|
pixman \
|
|
qemu-xen \
|
|
slirp \
|
|
util-linux \
|
|
yajl
|
|
ifeq ($(BR2_PACKAGE_ARGP_STANDALONE),y)
|
|
XEN_DEPENDENCIES += argp-standalone
|
|
endif
|
|
XEN_INSTALL_TARGET_OPTS += DESTDIR=$(TARGET_DIR) install-tools
|
|
XEN_MAKE_OPTS += dist-tools
|
|
XEN_CONF_OPTS += --with-extra-qemuu-configure-args="--disable-sdl --disable-opengl"
|
|
|
|
# Place the pre-downloaded qemu-xen source where the Xen build expects it.
|
|
# This prevents Xen from trying to git-clone qemu-xen during the build.
|
|
# Use cp -a (not symlink) so meson can write into subprojects/.
|
|
define XEN_INSTALL_QEMU_XEN_SRC
|
|
rm -rf $(@D)/tools/qemu-xen
|
|
cp -a $(QEMU_XEN_DIR) $(@D)/tools/qemu-xen
|
|
endef
|
|
XEN_POST_EXTRACT_HOOKS += XEN_INSTALL_QEMU_XEN_SRC
|
|
|
|
define XEN_INSTALL_INIT_SYSV
|
|
mv $(TARGET_DIR)/etc/init.d/xencommons $(TARGET_DIR)/etc/init.d/S50xencommons
|
|
mv $(TARGET_DIR)/etc/init.d/xen-watchdog $(TARGET_DIR)/etc/init.d/S50xen-watchdog
|
|
mv $(TARGET_DIR)/etc/init.d/xendomains $(TARGET_DIR)/etc/init.d/S60xendomains
|
|
endef
|
|
else
|
|
XEN_INSTALL_TARGET = NO
|
|
XEN_CONF_OPTS += --disable-tools
|
|
endif
|
|
|
|
$(eval $(autotools-package))
|