extra/qemu to 7.1.0-4

This commit is contained in:
Kevin Mihelich 2022-09-07 23:35:58 +00:00
parent 6ba20348d6
commit f786a7fb96
2 changed files with 180 additions and 199 deletions

View file

@ -18,17 +18,17 @@ pkgname=(
qemu-hw-usb-{host,redirect,smartcard}
qemu-img
qemu-pr-helper
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,loongarch64,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}
qemu-tests
qemu-tools
qemu-ui-{curses,dbus,egl-headless,gtk,opengl,sdl,spice-{app,core}}
qemu-user
qemu-user{,-static}
qemu-vhost-user-gpu
qemu-virtiofsd
qemu-{base,desktop,emulators-full,full}
)
pkgver=7.0.0
pkgrel=12
pkgver=7.1.0
pkgrel=4
pkgdesc="A generic and open source machine emulator and virtualizer"
arch=(x86_64)
url="https://www.qemu.org/"
@ -40,12 +40,12 @@ license=(GPL2 LGPL2.1)
# TODO: package /usr/share/qemu/{efi,pxe}-* for qemu (ipxe)
# TODO: package /usr/share/qemu/slof.bin for qemu-system-ppc (slof)
# TODO: package /usr/share/qemu/sgabios.bin for qemu-system-x86 (sgabios)
# TODO: package static libs of glib2 and pcre for qemu-user-static
makedepends=(
alsa-lib
brltty
bzip2
cairo
capstone
curl
dtc
fuse3
@ -97,7 +97,6 @@ makedepends=(
zlib
zstd
)
# NOTE: currently the debug package for qemu >= 7.0.0 contains an invalid /build dir
options=(debug)
source=(
https://download.qemu.org/qemu-$pkgver.tar.xz{,.sig}
@ -106,33 +105,25 @@ source=(
qemu-sysusers.conf
65-kvm.rules
99-qemu-guest-agent.rules
qemu-7.0.0-virtio-scsi_fix_ctrl_and_event_handler_functions_in_dataplane_mode.patch::https://github.com/qemu/qemu/commit/2f743ef6366c2df4ef51ef3ae318138cdc0125ab.patch
qemu-7.0.0-virtio-scsi_dont_waste_cpu_polling_the_eventvirtqueue.patch::https://github.com/qemu/qemu/commit/38738f7dbbda90fbc161757b7f4be35b52205552.patch
qemu-7.0.0-glibc-2.36.patch
)
sha512sums=('44ecd10c018a3763e1bc87d1d35b98890d0d5636acd69fe9b5cadf5024d5af6a31684d60cbe1c3370e02986434c1fb0ad99224e0e6f6fe7eda169992508157b1'
sha512sums=('c60c5ff8ec99b7552e485768908920658fdd8035ff7a6fa370fb6881957dc8b7e5f18ff1a8f49bd6aa22909ede2a7c084986d8244f12074ccd33ebe40a0c411f'
'SKIP'
'7b412ffa5dcda47b0a4ec9e2c5e5e1d9eaaaf0a087b7ea3ead3e706ba4c9cafb919beadd088a0299b6f7aab753b81a5eafb545b4842ee5f26646d16544dd02a7'
'6e838773d63ae0ffdffe2b891bf611d8f5f3c67a9bc4cbbedf8363c150c2c9971c8e44d92270bc581af40eb0ece02192760bcdd6aee229fff55635f3a4825afa'
'985c2c7a6b5217c87a15b45368089ee91b2f9027b070f9eafa448a18b27ae0d9edd964d52e134b9c1f4aeef4d6aae88afd3f454551ca898affef7f9d28b99b8f'
'bdf05f99407491e27a03aaf845b7cc8acfa2e0e59968236f10ffc905e5e3d5e8569df496fd71c887da2b5b8d1902494520c7da2d3a8258f7fd93a881dd610c99'
'93b905046fcea8a0a89513b9259c222494ab3b91319dde23baebcb40dc17376a56661b159b99785d6e816831974a0f3cbd7b2f7d89e5fc3c258f88f4492f3839'
'e6208f10db9277c217fe4e1ff57cbb9701bd6fce2f75ed01b5ed5ad78dd0d24d65371ef8d4f6e3a33ad0d280eba6614389795f8c8655ad15162411adc5ec642e'
'a80b2b9a84ecdfa352b6c35f5db547e670e4e5efd485cade893c04b4e5265439cc844fefbd27c050e63c16f727115d513b33a4d50400e1a8ee9fb646f0c0c61c'
'aa976c84d8524bb40ada506f80c01384c49f2e48fba889b0e535285aee700937886e935d18ad83b38093ba07f38be50b0fae76a0b29fd487daeac31e3221381e')
b2sums=('ceda6d9f1a585298bd49fed61e8bb35f0064ad8388a9f979c8bd68a38bfe1a47c5bb055e5f74f970c2c440957042b9de4a861524120040c56e4cd8b56c5cfb68'
'93b905046fcea8a0a89513b9259c222494ab3b91319dde23baebcb40dc17376a56661b159b99785d6e816831974a0f3cbd7b2f7d89e5fc3c258f88f4492f3839')
b2sums=('e05f91ce4993c7591a2df08b5fb017f8b8ec2141ab7bfd55d14730ea6b793ac1091de539992058392a5522d4e58beee92a87752707be58e3619b8213ef9f35bf'
'SKIP'
'b1eca364aa60f130ff5e649f5d004d3fcb75356d3421a4542efdfc410d39b40d9434d15e1dd7bbdbd315cb72b5290d3ea5f77f9c41961a5601cd28ef7bbe72e8'
'2102e4a34e11e406e9606c97e026e7b92e887e296a7f77b9cede1b37119d0df33735f3588628167b2b8e32244c196c491bfab623e2caddac9014d445aa2a6d98'
'69177b962d2fda20cafdbc6226fd017b5ca5a0f69f866d055dc1c744b7b2955059f47c693cfb5b4c863ec159569fdabd4327ab4b8a95566a68cd8ce38e339c7a'
'3559fe9c4f744194939770047a0a02d07ff791c845a80726d0bc7b8c4801ed5f11150e7d5adab813844b3dab1cf38c3a5a87fb6efbb8fc9dccdda9fa56409ed8'
'a9a2bdfeeb44eb86cbe88ac7c65f72800bdb2fd5cecb02f3a258cf9470b52832180aab43c89d481f7fd4d067342a9a27dd6c8a94d625b95d6e2b912e47d274e7'
'70aa62f9101b284248d098868031123e290030607c079475e715e2fde267b217c4f1971ba1f666130d8f427334cb5bf6fbabd87f7b7b83ecc3879a09a786aa90'
'f6dc6eec36e52ff230247f949651464ff4fbd8d77a295b16d78e290dd90f31f998c10c8490ec439fef10e6a69679e708d7ebf3ddca344c510c0b19b61db20bba'
'a7626f5ba67d628d74c909d84d9862e56435a1ace373fe5dedf93cd7d6ae56809b36cbcc271d156a6c3d5cac2a3824ffe2cb49e8f56d6bd964a7c416327f857e')
'a9a2bdfeeb44eb86cbe88ac7c65f72800bdb2fd5cecb02f3a258cf9470b52832180aab43c89d481f7fd4d067342a9a27dd6c8a94d625b95d6e2b912e47d274e7')
validpgpkeys=('CEACC9E15534EBABB82D3FA03353C9CEF108B584') # Michael Roth <flukshun@gmail.com>
_qemu_system_deps=(
capstone
dtc
fuse3
gcc-libs
@ -150,15 +141,13 @@ _qemu_system_deps=(
ndctl
pam libpam.so
pixman libpixman-1.so
qemu-common
qemu-common=$pkgver-$pkgrel
snappy
vde2
zlib
zstd libzstd.so
)
# TODO: qemu-user-static
# 'qemu-user-static: for static user mode emulation of QEMU targets'
_qemu_optdepends=(
'qemu-audio-alsa: for ALSA audio driver'
'qemu-audio-dbus: for D-Bus audio driver'
@ -220,6 +209,7 @@ _qemu_optdepends=(
'qemu-ui-spice-app: for spice app UI driver'
'qemu-ui-spice-core: for spice core UI driver'
'qemu-user: for user mode emulation of QEMU targets'
'qemu-user-static: for static user mode emulation of QEMU targets'
'qemu-vhost-user-gpu: for vhost-user-gpu display device'
'qemu-virtiofsd: for virtio-fs shared filesystem daemon'
'samba: for SMB/CIFS server support'
@ -247,18 +237,57 @@ prepare() {
# create build dir
mkdir -vp build
mkdir -vp build-static
# fix issues with virtio-scsi https://lists.gnu.org/archive/html/qemu-devel/2022-04/msg04724.html
patch -Np1 -d $pkgbase-$pkgver -i ../qemu-7.0.0-virtio-scsi_fix_ctrl_and_event_handler_functions_in_dataplane_mode.patch
patch -Np1 -d $pkgbase-$pkgver -i ../qemu-7.0.0-virtio-scsi_dont_waste_cpu_polling_the_eventvirtqueue.patch
patch -Np1 -d $pkgbase-$pkgver -i ../qemu-7.0.0-glibc-2.36.patch
}
build() {
(
cd build-static
../$pkgbase-$pkgver/configure \
--prefix=/usr \
--sysconfdir=/etc \
--libexecdir=/usr/lib/qemu \
--enable-attr \
--enable-linux-user \
--enable-tcg \
--disable-bpf \
--disable-bsd-user \
--disable-capstone \
--disable-docs \
--disable-fdt \
--disable-gcrypt \
--disable-glusterfs \
--disable-gnutls \
--disable-gtk \
--disable-install-blobs \
--disable-kvm \
--disable-libiscsi \
--disable-libnfs \
--disable-libssh \
--disable-linux-io-uring \
--disable-nettle \
--disable-opengl \
--disable-qom-cast-debug \
--disable-sdl \
--disable-system \
--disable-tools \
--disable-tpm \
--disable-vde \
--disable-vhost-crypto \
--disable-vhost-kernel \
--disable-vhost-net \
--disable-vhost-user \
--disable-vnc \
--disable-werror \
--disable-xen \
--disable-zstd \
--static
ninja
)
# Build only minimal debug info to reduce size
CFLAGS+=' -g1'
CXXFLAGS+=' -g1'
(
cd build
../$pkgbase-$pkgver/configure \
@ -272,45 +301,41 @@ build() {
--enable-slirp=system \
--enable-tpm \
--smbd=/usr/bin/smbd \
--tls-priority=@QEMU,SYSTEM \
--with-coroutine=ucontext
ninja
)
# TODO: qemu-user-static
# (
# cd build-static
# ../$pkgbase-$pkgver/configure \
# --enable-attr \
# --enable-linux-user \
# --enable-tcg \
# --disable-install-blobs \
# --static
# ninja
# )
}
package_qemu-common() {
license+=(BSD MIT)
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so hicolor-icon-theme libcap-ng libcap-ng.so)
backup=(
etc/$pkgbase/bridge.conf
etc/sasl2/$pkgbase.conf
)
install=$pkgname.install
options=(!strip)
# install static binaries
meson install -C build-static --destdir "$pkgdir"
install -vdm 755 "$pkgdir/usr/lib/binfmt.d/"
$pkgbase-$pkgver/scripts/qemu-binfmt-conf.sh --systemd ALL --exportdir "$pkgdir/usr/lib/binfmt.d/" --qemu-path "/usr/bin"
# rename static binaries to prevent name conflicts
for _src in "$pkgdir/usr/bin/qemu-"*; do
mv -v "$_src" "$pkgdir/usr/bin/$(basename "$_src")-static"
done
# modify and rename binfmt.d configs to prevent name conflicts
for _conf in "$pkgdir/usr/lib/binfmt.d/"*; do
cat "$_conf" | tr -d '\n' | sed "s/:$/-static:F/" > "${_conf//.conf/-static.conf}"
done
# install default binaries
meson install -C build --destdir "$pkgdir"
install -vdm 755 "$pkgdir/usr/lib/binfmt.d/"
$pkgbase-$pkgver/scripts/qemu-binfmt-conf.sh --systemd ALL --exportdir "$pkgdir/usr/lib/binfmt.d/" --qemu-path "/usr/bin"
# TODO: qemu-user-static
# for _conf in "$pkgdir/usr/lib/binfmt.d/"*; do
# cat "$_conf" | tr -d '\n' | sed "s/:$/-static:F/" > "${_conf//.conf/-static.conf}"
# done
#
# meson install -C build-static --destdir "$pkgdir"
# for _src in "$pkgdir/usr/bin/qemu-"*; do
# mv -v "$_src" "$pkgdir/usr/bin/$(basename "$_src")-static"
# done
install -vDm 644 bridge.conf -t "$pkgdir/etc/$pkgbase/"
install -vDm 644 $pkgbase-$pkgver/$pkgbase.sasl "$pkgdir/etc/sasl2/$pkgbase.conf"
install -vDm 644 $pkgbase-$pkgver/LICENSE *LICENSE* -t "$pkgdir/usr/share/licenses/$pkgbase/"
@ -407,6 +432,7 @@ package_qemu-common() {
_pick qemu-system-hppa usr/share/qemu/hppa-firmware.img
_pick qemu-system-hppa usr/share/man/man1/qemu-system-hppa.1*
_pick qemu-system-loongarch64 usr/bin/qemu-system-loongarch64
_pick qemu-system-m68k usr/bin/qemu-system-m68k
_pick qemu-system-m68k usr/share/man/man1/qemu-system-m68k.1*
@ -483,10 +509,10 @@ package_qemu-common() {
_pick qemu-ui-spice-app usr/lib/qemu/ui-spice-app.so
_pick qemu-ui-spice-core usr/lib/qemu/ui-spice-core.so
# _pick qemu-user-static usr/bin/qemu-*-static
# _pick qemu-user-static usr/lib/binfmt.d/*-static.conf
_pick qemu-user-static usr/bin/qemu-*-static
_pick qemu-user-static usr/lib/binfmt.d/*-static.conf
_pick qemu-user usr/bin/qemu-{aarch64{,_be},alpha,arm{,eb},cris,hexagon,hppa,i386,m68k,microblaze{,el},mips{,64,64el,el,n32,n32el},nios2,or1k,ppc{,64,64le},riscv{32,64},s390x,sh4{,eb},sparc{,32plus,64},x86_64,xtensa{,eb}}
_pick qemu-user usr/bin/qemu-{aarch64{,_be},alpha,arm{,eb},cris,hexagon,hppa,i386,loongarch64,m68k,microblaze{,el},mips{,64,64el,el,n32,n32el},nios2,or1k,ppc{,64,64le},riscv{32,64},s390x,sh4{,eb},sparc{,32plus,64},x86_64,xtensa{,eb}}
_pick qemu-user usr/lib/binfmt.d/*.conf
_pick qemu-vhost-user-gpu usr/lib/qemu/vhost-user-gpu
@ -500,91 +526,91 @@ package_qemu-common() {
package_qemu-audio-alsa() {
pkgdesc="QEMU ALSA audio driver"
depends=(alsa-lib libasound.so glibc qemu-common)
depends=(alsa-lib libasound.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-dbus() {
pkgdesc="QEMU D-Bus audio driver"
depends=(gcc-libs glib2 libgio-2.0.so libgobject-2.0.so libglib-2.0.so glibc qemu-common)
depends=(gcc-libs glib2 libgio-2.0.so libgobject-2.0.so libglib-2.0.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-jack() {
pkgdesc="QEMU JACK audio driver"
depends=(jack libjack.so glibc qemu-common)
depends=(jack libjack.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-oss() {
pkgdesc="QEMU OSS audio driver"
depends=(glibc qemu-common)
depends=(glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-pa() {
pkgdesc="QEMU PulseAudio audio driver"
depends=(glibc libpulse libpulse.so qemu-common)
depends=(glibc libpulse libpulse.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-sdl() {
pkgdesc="QEMU SDL audio driver"
depends=(glibc qemu-common sdl2)
depends=(glibc qemu-common=$pkgver-$pkgrel sdl2)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-audio-spice() {
pkgdesc="QEMU spice audio driver"
depends=(glibc qemu-common qemu-ui-spice-core spice libspice-server.so)
depends=(glibc qemu-common=$pkgver-$pkgrel qemu-ui-spice-core=$pkgver-$pkgrel spice libspice-server.so)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-curl() {
pkgdesc="QEMU curl block driver"
depends=(curl libcurl.so gcc-libs glibc qemu-common)
depends=(curl libcurl.so gcc-libs glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-dmg() {
pkgdesc="QEMU DMG block driver"
depends=(bzip2 libbz2.so glibc qemu-common)
depends=(bzip2 libbz2.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-gluster() {
pkgdesc="QEMU Gluster block driver"
depends=(glibc glusterfs qemu-common)
depends=(glibc glusterfs qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-iscsi() {
pkgdesc="QEMU iSCSI block driver"
depends=(gcc-libs glibc libiscsi qemu-common)
depends=(gcc-libs glibc libiscsi qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-nfs() {
pkgdesc="QEMU NFS block driver"
depends=(gcc-libs glibc libnfs qemu-common)
depends=(gcc-libs glibc libnfs qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-block-ssh() {
pkgdesc="QEMU SSH block driver"
depends=(gcc-libs glibc libssh libssh.so qemu-common)
depends=(gcc-libs glibc libssh libssh.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-chardev-baum() {
pkgdesc="QEMU Baum chardev driver"
depends=(brltty libbrlapi.so glibc qemu-common)
depends=(brltty libbrlapi.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-chardev-spice() {
pkgdesc="QEMU spice chardev driver"
depends=(libspice-server.so glibc qemu-common qemu-ui-spice-core)
depends=(libspice-server.so glibc qemu-common=$pkgver-$pkgrel qemu-ui-spice-core=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
@ -605,55 +631,55 @@ package_qemu-guest-agent() {
install -vDm 644 $pkgbase-$pkgver/contrib/systemd/$pkgname.service -t "$pkgdir/usr/lib/systemd/system/"
install -vDm 644 99-$pkgname.rules -t "$pkgdir/usr/lib/udev/rules.d/"
install -vDm 644 $pkgbase-ga.conf -t "$pkgdir/etc/$pkgbase/"
install -vDm 644 $pkgbase-$pkgver/scripts/$pkgname/fsfreeze-hook -t "$pkgdir/etc/$pkgbase/"
install -vDm 755 $pkgbase-$pkgver/scripts/$pkgname/fsfreeze-hook -t "$pkgdir/etc/$pkgbase/"
install -vdm 755 "$pkgdir/etc/$pkgbase/fsfreeze-hook.d"
}
package_qemu-hw-display-qxl() {
pkgdesc="QEMU QXL display device"
depends=(gcc-libs glibc pixman libpixman-1.so qemu-common qemu-ui-spice-core spice libspice-server.so)
depends=(gcc-libs glibc pixman libpixman-1.so qemu-common=$pkgver-$pkgrel qemu-ui-spice-core=$pkgver-$pkgrel spice libspice-server.so)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-gpu() {
pkgdesc="QEMU virtio-gpu display device"
depends=(glibc pixman libpixman-1.so qemu-common)
depends=(glibc pixman libpixman-1.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-gpu-gl() {
pkgdesc="QEMU virtio-gpu-gl display device"
depends=(glibc qemu-common virglrenderer)
depends=(glibc qemu-common=$pkgver-$pkgrel virglrenderer)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-gpu-pci() {
pkgdesc="QEMU virtio-gpu-pci display device"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-gpu-pci-gl() {
pkgdesc="QEMU virtio-gpu-pci-gl display device"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-vga() {
pkgdesc="QEMU virtio-vga display device"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-display-virtio-vga-gl() {
pkgdesc="QEMU virtio-vga-gl display device"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-s390x-virtio-gpu-ccw() {
pkgdesc="QEMU s390x-virtio-gpu-ccw display device"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
@ -666,14 +692,12 @@ package_qemu-system-aarch64() {
package_qemu-system-alpha() {
pkgdesc="QEMU system emulator for Alpha"
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-system-arm() {
pkgdesc="QEMU system emulator for ARM"
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
@ -692,7 +716,12 @@ package_qemu-system-cris() {
package_qemu-system-hppa() {
pkgdesc="QEMU system emulator for HPPA"
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-system-loongarch64() {
pkgdesc="QEMU system emulator for LoongArch64"
depends=("${_qemu_system_deps[@]}")
mv -v $pkgname/* "$pkgdir"
}
@ -730,14 +759,12 @@ package_qemu-system-ppc() {
pkgdesc="QEMU system emulator for PPC"
# NOTE: will require openbios
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-system-riscv() {
pkgdesc="QEMU system emulator for RISC-V"
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
@ -750,7 +777,6 @@ package_qemu-system-rx() {
package_qemu-system-s390x() {
pkgdesc="QEMU system emulator for S390"
depends=("${_qemu_system_deps[@]}")
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
@ -764,7 +790,6 @@ package_qemu-system-sparc() {
pkgdesc="QEMU system emulator for SPARC"
# NOTE: will require openbios
depends=("${_qemu_system_deps[@]}" systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
@ -777,7 +802,6 @@ package_qemu-system-tricore() {
package_qemu-system-x86() {
pkgdesc="QEMU system emulator for x86"
depends=("${_qemu_system_deps[@]}" edk2-ovmf seabios systemd-libs libudev.so)
options=(!strip)
mv -v $pkgname/* "$pkgdir"
}
@ -789,19 +813,19 @@ package_qemu-system-xtensa() {
package_qemu-hw-usb-host() {
pkgdesc="QEMU USB host device"
depends=(glibc libusb libusb-1.0.so qemu-common)
depends=(glibc libusb libusb-1.0.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-usb-redirect() {
pkgdesc="QEMU usbredir device"
depends=(gcc-libs glibc qemu-common usbredir)
depends=(gcc-libs glibc qemu-common=$pkgver-$pkgrel usbredir)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-hw-usb-smartcard() {
pkgdesc="QEMU USB smartcard device"
depends=(gcc-libs libcacard glib2 libglib-2.0.so glibc qemu-common)
depends=(gcc-libs libcacard glib2 libglib-2.0.so glibc qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
@ -813,20 +837,20 @@ package_qemu-img() {
package_qemu-pr-helper() {
pkgdesc="QEMU persistent reservation utility"
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc gnutls libcap-ng libcap-ng.so liburing liburing.so multipath-tools pam libpam.so qemu-common)
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc gnutls libcap-ng libcap-ng.so liburing liburing.so multipath-tools pam libpam.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
install -vDm 644 $pkgbase-$pkgver/contrib/systemd/$pkgname.{service,socket} -t "$pkgdir/usr/lib/systemd/system/"
}
package_qemu-tests() {
pkgdesc="QEMU tests"
depends=(qemu-common)
depends=(qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-tools() {
pkgdesc="QEMU tools"
depends=(curl libcurl.so gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc libxkbcommon libxkbcommon.so python qemu-common)
depends=(curl libcurl.so gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc libxkbcommon libxkbcommon.so python qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
install -vDm 644 $pkgbase-$pkgver/scripts/dump-guest-memory.py -t "$pkgdir/usr/share/$pkgbase/"
install -vDm 755 $pkgbase-$pkgver/scripts/simpletrace.py -t "$pkgdir/usr/share/$pkgbase/"
@ -837,19 +861,19 @@ package_qemu-tools() {
package_qemu-ui-curses() {
pkgdesc="QEMU curses UI driver"
depends=(gcc-libs glib2 libglib-2.0.so glibc ncurses libncursesw.so qemu-common)
depends=(gcc-libs glib2 libglib-2.0.so glibc ncurses libncursesw.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-ui-dbus() {
pkgdesc="QEMU D-Bus UI driver"
depends=(gcc-libs glib2 libgio-2.0.so libgobject-2.0.so libglib-2.0.so glibc libepoxy pixman libpixman-1.so qemu-common)
depends=(gcc-libs glib2 libgio-2.0.so libgobject-2.0.so libglib-2.0.so glibc libepoxy pixman libpixman-1.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-ui-egl-headless() {
pkgdesc="QEMU EGL headless UI driver"
depends=(glibc libepoxy qemu-common qemu-ui-opengl)
depends=(glibc libepoxy qemu-common=$pkgver-$pkgrel qemu-ui-opengl=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
@ -865,7 +889,7 @@ package_qemu-ui-gtk() {
libepoxy
libx11
pixman libpixman-1.so
qemu-common
qemu-common=$pkgver-$pkgrel
qemu-ui-opengl
vte3 libvte-2.91.so
)
@ -874,69 +898,69 @@ package_qemu-ui-gtk() {
package_qemu-ui-opengl() {
pkgdesc="QEMU OpenGL UI driver"
depends=(glibc libepoxy mesa pixman libpixman-1.so qemu-common)
depends=(glibc libepoxy mesa pixman libpixman-1.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-ui-sdl() {
pkgdesc="QEMU SDL UI driver"
depends=(glib2 libglib-2.0.so glibc libx11 pixman libpixman-1.so qemu-common sdl2_image sdl2)
depends=(glib2 libglib-2.0.so glibc libx11 pixman libpixman-1.so qemu-common=$pkgver-$pkgrel sdl2_image sdl2)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-ui-spice-app() {
pkgdesc="QEMU spice app UI driver"
depends=(glib2 libgio-2.0.so libglib-2.0.so glibc qemu-common qemu-chardev-spice qemu-ui-spice-core)
depends=(glib2 libgio-2.0.so libglib-2.0.so glibc qemu-common=$pkgver-$pkgrel qemu-chardev-spice=$pkgver-$pkgrel qemu-ui-spice-core=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-ui-spice-core() {
pkgdesc="QEMU spice core UI driver"
depends=(gcc-libs glibc pixman libpixman-1.so qemu-common qemu-ui-opengl spice libspice-server.so)
depends=(gcc-libs glibc pixman libpixman-1.so qemu-common=$pkgver-$pkgrel qemu-ui-opengl=$pkgver-$pkgrel spice libspice-server.so)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-user() {
pkgdesc="QEMU user mode emulation"
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc gnutls liburing liburing.so qemu-common zlib)
depends=(capstone gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc gnutls liburing liburing.so qemu-common=$pkgver-$pkgrel zlib)
mv -v $pkgname/* "$pkgdir"
}
# package_qemu-user-static() {
# pkgdesc="QEMU static user mode emulation"
# depends=(glibc)
# mv -v $pkgname/* "$pkgdir"
# }
package_qemu-user-static() {
pkgdesc="QEMU static user mode emulation"
depends=(glibc)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-vhost-user-gpu() {
pkgdesc="QEMU vhost-user-gpu display device"
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc pixman libpixman-1.so mesa qemu-common virglrenderer)
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc pixman libpixman-1.so mesa qemu-common=$pkgver-$pkgrel virglrenderer)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-virtiofsd() {
pkgdesc="QEMU virtio-fs shared filesystem daemon"
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc libcap-ng libcap-ng.so libseccomp libseccomp.so qemu-common)
depends=(gcc-libs glib2 libglib-2.0.so libgmodule-2.0.so glibc libcap-ng libcap-ng.so libseccomp libseccomp.so qemu-common=$pkgver-$pkgrel)
mv -v $pkgname/* "$pkgdir"
}
package_qemu-base() {
pkgdesc="A basic QEMU setup for headless environments"
depends=(
qemu-common
qemu-audio-spice
qemu-block-{curl,dmg,nfs,ssh}
qemu-chardev-spice
qemu-hw-display-{qxl,virtio-gpu{,-{gl,pci,pci-gl}}}
qemu-hw-display-virtio-vga{,-gl}
qemu-hw-s390x-virtio-gpu-ccw
qemu-hw-usb-{host,redirect,smartcard}
qemu-img
qemu-pr-helper
qemu-system-x86
qemu-tools
qemu-ui-{curses,spice-{app,core}}
qemu-virtiofsd
qemu-common=$pkgver-$pkgrel
qemu-audio-spice=$pkgver-$pkgrel
qemu-block-{curl,dmg,nfs,ssh}=$pkgver-$pkgrel
qemu-chardev-spice=$pkgver-$pkgrel
qemu-hw-display-{qxl,virtio-gpu{,-{gl,pci,pci-gl}}}=$pkgver-$pkgrel
qemu-hw-display-virtio-vga{,-gl}=$pkgver-$pkgrel
qemu-hw-s390x-virtio-gpu-ccw=$pkgver-$pkgrel
qemu-hw-usb-{host,redirect,smartcard}=$pkgver-$pkgrel
qemu-img=$pkgver-$pkgrel
qemu-pr-helper=$pkgver-$pkgrel
qemu-system-x86=$pkgver-$pkgrel
qemu-tools=$pkgver-$pkgrel
qemu-ui-{curses,spice-{app,core}}=$pkgver-$pkgrel
qemu-virtiofsd=$pkgver-$pkgrel
)
optdepends=("${_qemu_optdepends[@]}")
# TODO: remove conflicts/provides/replaces for qemu-headless after 2022-10-01
@ -948,21 +972,21 @@ package_qemu-base() {
package_qemu-desktop() {
pkgdesc="A QEMU setup for desktop environments"
depends=(
qemu-common
qemu-audio-{alsa,dbus,jack,oss,pa,sdl,spice}
qemu-block-{curl,dmg,nfs,ssh}
qemu-chardev-spice
qemu-hw-display-{qxl,virtio-gpu{,-{gl,pci,pci-gl}}}
qemu-hw-display-virtio-vga{,-gl}
qemu-hw-s390x-virtio-gpu-ccw
qemu-hw-usb-{host,redirect,smartcard}
qemu-img
qemu-pr-helper
qemu-system-x86
qemu-tools
qemu-ui-{curses,dbus,egl-headless,gtk,opengl,sdl,spice-{app,core}}
qemu-vhost-user-gpu
qemu-virtiofsd
qemu-common=$pkgver-$pkgrel
qemu-audio-{alsa,dbus,jack,oss,pa,sdl,spice}=$pkgver-$pkgrel
qemu-block-{curl,dmg,nfs,ssh}=$pkgver-$pkgrel
qemu-chardev-spice=$pkgver-$pkgrel
qemu-hw-display-{qxl,virtio-gpu{,-{gl,pci,pci-gl}}}=$pkgver-$pkgrel
qemu-hw-display-virtio-vga{,-gl}=$pkgver-$pkgrel
qemu-hw-s390x-virtio-gpu-ccw=$pkgver-$pkgrel
qemu-hw-usb-{host,redirect,smartcard}=$pkgver-$pkgrel
qemu-img=$pkgver-$pkgrel
qemu-pr-helper=$pkgver-$pkgrel
qemu-system-x86=$pkgver-$pkgrel
qemu-tools=$pkgver-$pkgrel
qemu-ui-{curses,dbus,egl-headless,gtk,opengl,sdl,spice-{app,core}}=$pkgver-$pkgrel
qemu-vhost-user-gpu=$pkgver-$pkgrel
qemu-virtiofsd=$pkgver-$pkgrel
)
optdepends=("${_qemu_optdepends[@]}")
conflicts=(qemu)
@ -973,8 +997,8 @@ package_qemu-desktop() {
package_qemu-emulators-full() {
pkgdesc="All QEMU user mode and system emulators"
depends=(
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}
qemu-user
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,loongarch64,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}=$pkgver-$pkgrel
qemu-user=$pkgver-$pkgrel
)
# TODO: remove conflicts/provides/replaces after 2022-10-01
conflicts=(qemu-arch-extra qemu-headless-arch-extra)
@ -985,23 +1009,23 @@ package_qemu-emulators-full() {
package_qemu-full() {
pkgdesc="A full QEMU setup"
depends=(
qemu-common
qemu-audio-{alsa,dbus,jack,oss,pa,sdl,spice}
qemu-block-{curl,dmg,gluster,iscsi,nfs,ssh}
qemu-chardev-{baum,spice}
qemu-docs
qemu-hw-display-{qxl,virtio-{gpu{,-{gl,pci,pci-gl}},vga{,-gl}}}
qemu-hw-s390x-virtio-gpu-ccw
qemu-hw-usb-{host,redirect,smartcard}
qemu-img
qemu-pr-helper
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}
qemu-tests
qemu-tools
qemu-ui-{curses,dbus,egl-headless,gtk,opengl,sdl,spice-{app,core}}
qemu-user
qemu-vhost-user-gpu
qemu-virtiofsd
qemu-common=$pkgver-$pkgrel
qemu-audio-{alsa,dbus,jack,oss,pa,sdl,spice}=$pkgver-$pkgrel
qemu-block-{curl,dmg,gluster,iscsi,nfs,ssh}=$pkgver-$pkgrel
qemu-chardev-{baum,spice}=$pkgver-$pkgrel
qemu-docs=$pkgver-$pkgrel
qemu-hw-display-{qxl,virtio-{gpu{,-{gl,pci,pci-gl}},vga{,-gl}}}=$pkgver-$pkgrel
qemu-hw-s390x-virtio-gpu-ccw=$pkgver-$pkgrel
qemu-hw-usb-{host,redirect,smartcard}=$pkgver-$pkgrel
qemu-img=$pkgver-$pkgrel
qemu-pr-helper=$pkgver-$pkgrel
qemu-system-{aarch64,alpha,arm,avr,cris,hppa,loongarch64,m68k,microblaze,mips,nios2,or1k,ppc,riscv,rx,s390x,sh4,sparc,tricore,x86,xtensa}=$pkgver-$pkgrel
qemu-tests=$pkgver-$pkgrel
qemu-tools=$pkgver-$pkgrel
qemu-ui-{curses,dbus,egl-headless,gtk,opengl,sdl,spice-{app,core}}=$pkgver-$pkgrel
qemu-user=$pkgver-$pkgrel
qemu-vhost-user-gpu=$pkgver-$pkgrel
qemu-virtiofsd=$pkgver-$pkgrel
)
optdepends=("${_qemu_optdepends[@]}")
conflicts=(qemu)

View file

@ -1,43 +0,0 @@
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
index b27a6552aa..52d178afe7 100644
--- a/linux-user/syscall.c
+++ b/linux-user/syscall.c
@@ -95,7 +95,25 @@
#include <linux/soundcard.h>
#include <linux/kd.h>
#include <linux/mtio.h>
+
+#ifdef HAVE_SYS_MOUNT_FSCONFIG
+/*
+ * glibc >= 2.36 linux/mount.h conflicts with sys/mount.h,
+ * which in turn prevents use of linux/fs.h. So we have to
+ * define the constants ourselves for now.
+ */
+#define FS_IOC_GETFLAGS _IOR('f', 1, long)
+#define FS_IOC_SETFLAGS _IOW('f', 2, long)
+#define FS_IOC_GETVERSION _IOR('v', 1, long)
+#define FS_IOC_SETVERSION _IOW('v', 2, long)
+#define FS_IOC_FIEMAP _IOWR('f', 11, struct fiemap)
+#define FS_IOC32_GETFLAGS _IOR('f', 1, int)
+#define FS_IOC32_SETFLAGS _IOW('f', 2, int)
+#define FS_IOC32_GETVERSION _IOR('v', 1, int)
+#define FS_IOC32_SETVERSION _IOW('v', 2, int)
+#else
#include <linux/fs.h>
+#endif
#include <linux/fd.h>
#if defined(CONFIG_FIEMAP)
#include <linux/fiemap.h>
diff --git a/meson.build b/meson.build
index 294e9a8f32..30a380752c 100644
--- a/meson.build
+++ b/meson.build
@@ -1963,6 +1963,8 @@ config_host_data.set('HAVE_OPTRESET',
cc.has_header_symbol('getopt.h', 'optreset'))
config_host_data.set('HAVE_IPPROTO_MPTCP',
cc.has_header_symbol('netinet/in.h', 'IPPROTO_MPTCP'))
+config_host_data.set('HAVE_SYS_MOUNT_FSCONFIG',
+ cc.has_header_symbol('sys/mount.h', 'FSCONFIG_SET_FLAG'))
# has_member
config_host_data.set('HAVE_SIGEV_NOTIFY_THREAD_ID',