Tracking issue for this possibility.
Upstream QEMU builds mingw64 qemu using a fedora cross-compiler container in their GitLab CI.
This would be a.. rather advanced set of build instructions though.
Extra requirements:
Possible steps (WIP, based on their GitLab yamls):
# FIXME: Do we need recursive? This downloads 2.4 G of .. stuff.
# FIXME: Pick a tag, not main!
$ git clone --recursive https://gitlab.com/qemu-project/qemu.git
$ cd qemu
# Build fedora 33 cross compiler container:
$ ./tests/docker/docker.py --engine docker build -t "qemu/fedora-win64-cross" -f "tests/docker/dockerfiles/fedora-win64-cross.docker"
# FIXME: Docker gurus save me ....
$ docker run -it --rm -v $PWD:$PWD qemu/fedora-win64-cross
[root@c2a9212b7d19 /]# cd /home/andrew/qemu
[root@c2a9212b7d19 qemu]# mkdir build
[root@c2a9212b7d19 qemu]# cd build
# Install extra deps that QEMU CI doesn't for some reason
[root@c2a9212b7d19 qemu]# dnf install -y mingw64-gnutls mingw64-SDL2 mingw32-nsis
[root@c2a9212b7d19 build]# ../configure \
--cross-prefix=x86_64-w64-mingw32- \
--disable-capstone \
--enable-gtk \
--disable-docs \
--enable-werror \
--enable-tools \
--enable-trace-backends=simple \
--enable-gnutls \
--enable-nettle \
--enable-curl \
--enable-vnc \
--enable-bzip2 \
--enable-guest-agent \
--enable-sdl \
--target-list=x86_64-softmmu,i386-softmmu
[root@c2a9212b7d19 build]# TODO Figure out where to get WinHvPlatform.h from...
[root@c2a9212b7d19 build]# make -j4 all
[root@c2a9212b7d19 build]# make -j4 installer
Sad things:
Seems the really interesting virtio options are not supported
../meson.build:1184:6: ERROR: Problem encountered: virtio-9p (virtfs) requires Linux
# No sys/socket.h so no virtio-net
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too