#!/bin/bash QEMU_VERSION=8.2.0 set -e if ! [[ -f qemu-${QEMU_VERSION}.tar.xz ]] then curl -LJO https://download.qemu.org/qemu-${QEMU_VERSION}.tar.xz fi if ! [[ -d qemu-${QEMU_VERSION} ]] then tar xvJf qemu-${QEMU_VERSION}.tar.xz fi cd qemu-${QEMU_VERSION} rm -rf build mkdir -p build cd build ../configure \ --prefix=/ \ --localstatedir=var \ --enable-kvm \ --enable-gnutls \ --enable-guest-agent \ --enable-iconv \ --enable-kvm \ --enable-libiscsi \ --enable-libpmem \ --enable-libssh \ --enable-libusb \ --enable-libudev \ --enable-linux-aio \ --enable-lzo \ --enable-malloc-trim \ --enable-modules \ --enable-mpath \ --enable-smartcard \ --enable-spice \ --enable-spice-protocol \ --enable-system \ --enable-tcg \ --enable-tools \ --enable-tpm \ --enable-vhost-kernel \ --enable-vhost-net \ --enable-vhost-user \ --enable-vhost-user-blk-server \ --enable-vhost-vdpa \ --enable-vnc \ --enable-vnc-sasl \ --enable-werror \ --enable-xkbcommon \ --enable-attr \ --enable-avx2 \ --enable-cap-ng \ --enable-coroutine-pool \ --enable-curl \ --enable-debug-info \ --enable-docs \ make -j 8 make install DESTDIR=/opt cd /opt tar -cJf /src/${QEMU_VERSION}.tar.xz ./