2021-08-10 14:32:15 +02:00
|
|
|
# Description: Fast CPU emulator and virtualizer for all supported platforms
|
2021-08-10 18:10:43 +02:00
|
|
|
# URL: http://www.qemu-project.org/
|
|
|
|
# Maintainer: Juergen Daubert, jue at crux dot nu
|
2023-09-23 16:56:52 +02:00
|
|
|
# Depends on: dtc glib libusb linux-pam xorg-libpixman
|
|
|
|
# Optional: alsa-lib fuse3 gnutls libaio libjpeg-turbo libpng libsdl2 libseccomp libslirp libssh liburing libxkbcommon nettle nfs-utils numactl pipewire pulseaudio python3-sphinx python3-sphinx_rtd_theme sdl2_image snappy xkeyboard-config xkeyboard-config
|
|
|
|
|
2021-08-10 14:32:15 +02:00
|
|
|
name=qemu-all
|
2023-11-22 09:45:32 +01:00
|
|
|
version=8.1.3
|
2021-08-10 14:32:15 +02:00
|
|
|
release=1
|
2023-10-17 18:27:40 +02:00
|
|
|
source=(https://download.qemu.org/qemu-$version.tar.xz)
|
2021-08-10 14:32:15 +02:00
|
|
|
|
|
|
|
build() {
|
2021-08-10 18:10:43 +02:00
|
|
|
cd qemu-$version
|
2023-09-23 16:56:52 +02:00
|
|
|
|
|
|
|
## only needed for qemu-keymap
|
|
|
|
if [[ ! -e /usr/include/xkbcommon/xkbcommon-x11.h ]] && ! prt-get isinst xkeyboard-config; then
|
|
|
|
printf '\e[1;31m%-6s\e[m\n' "You need to install xkeyboard-config, then rebuild libxkbcommon to build qemu-keymap. We are disabling this feature now."
|
|
|
|
PKGMK_QEMU+=' --disable-xkbcommon'
|
|
|
|
fi
|
|
|
|
prt-get isinst python3-sphinx python3-sphinx_rtd_theme || PKGMK_QEMU+=' --disable-docs'
|
2021-08-10 14:32:15 +02:00
|
|
|
|
2023-09-23 16:56:52 +02:00
|
|
|
./configure $PKGMK_QEMU \
|
2021-08-10 18:10:43 +02:00
|
|
|
--prefix=/usr \
|
|
|
|
--cc="${CC:=gcc}" \
|
|
|
|
--host-cc="${CC:=gcc}" \
|
|
|
|
--sysconfdir=/etc \
|
|
|
|
--libexecdir=/usr/lib/qemu \
|
|
|
|
--disable-gtk \
|
|
|
|
--localstatedir=/var \
|
2023-08-28 13:13:58 +02:00
|
|
|
--enable-fdt=system \
|
2021-08-10 18:10:43 +02:00
|
|
|
--python=/usr/bin/python3
|
2021-08-10 14:32:15 +02:00
|
|
|
|
2021-08-10 18:10:43 +02:00
|
|
|
make ${MAKEFLAGS:=}
|
|
|
|
make DESTDIR=$PKG install
|
2021-08-10 14:32:15 +02:00
|
|
|
|
2021-08-10 18:10:43 +02:00
|
|
|
install -d $PKG/etc/udev/rules.d/
|
|
|
|
echo 'KERNEL=="kvm", NAME="kvm", OWNER="root", GROUP="kvm", MODE="0660"' > \
|
|
|
|
$PKG/etc/udev/rules.d/60-kvm.rules
|
2021-08-10 14:32:15 +02:00
|
|
|
|
2023-08-28 13:13:58 +02:00
|
|
|
rm -r $PKG/var
|
2021-08-10 14:32:15 +02:00
|
|
|
}
|