xref: /openbmc/qemu/docs/about/build-platforms.rst (revision b91b0fc1)
1f3478392SPeter Maydell.. _Supported-build-platforms:
2f3478392SPeter Maydell
3f3478392SPeter MaydellSupported build platforms
4f3478392SPeter Maydell=========================
5f3478392SPeter Maydell
6f3478392SPeter MaydellQEMU aims to support building and executing on multiple host OS
7f3478392SPeter Maydellplatforms. This appendix outlines which platforms are the major build
8f3478392SPeter Maydelltargets. These platforms are used as the basis for deciding upon the
9f3478392SPeter Maydellminimum required versions of 3rd party software QEMU depends on. The
10f3478392SPeter Maydellsupported platforms are the targets for automated testing performed by
11f3478392SPeter Maydellthe project when patches are submitted for review, and tested before and
12f3478392SPeter Maydellafter merge.
13f3478392SPeter Maydell
14f3478392SPeter MaydellIf a platform is not listed here, it does not imply that QEMU won't
15f3478392SPeter Maydellwork. If an unlisted platform has comparable software versions to a
16f3478392SPeter Maydelllisted platform, there is every expectation that it will work. Bug
17f3478392SPeter Maydellreports are welcome for problems encountered on unlisted platforms
18f3478392SPeter Maydellunless they are clearly older vintage than what is described here.
19f3478392SPeter Maydell
20f3478392SPeter MaydellNote that when considering software versions shipped in distros as
21f3478392SPeter Maydellsupport targets, QEMU considers only the version number, and assumes the
22f3478392SPeter Maydellfeatures in that distro match the upstream release with the same
23f3478392SPeter Maydellversion. In other words, if a distro backports extra features to the
24f3478392SPeter Maydellsoftware in their distro, QEMU upstream code will not add explicit
25f3478392SPeter Maydellsupport for those backports, unless the feature is auto-detectable in a
26f3478392SPeter Maydellmanner that works for the upstream releases too.
27f3478392SPeter Maydell
28f3478392SPeter MaydellThe `Repology`_ site is a useful resource to identify
29f3478392SPeter Maydellcurrently shipped versions of software in various operating systems,
30f3478392SPeter Maydellthough it does not cover all distros listed below.
31f3478392SPeter Maydell
327f800d34SMarc-André LureauSupported host architectures
337f800d34SMarc-André Lureau----------------------------
347f800d34SMarc-André Lureau
357f800d34SMarc-André LureauThose hosts are officially supported, with various accelerators:
367f800d34SMarc-André Lureau
377f800d34SMarc-André Lureau  .. list-table::
387f800d34SMarc-André Lureau   :header-rows: 1
397f800d34SMarc-André Lureau
407f800d34SMarc-André Lureau   * - CPU Architecture
417f800d34SMarc-André Lureau     - Accelerators
427f800d34SMarc-André Lureau   * - Arm
437f800d34SMarc-André Lureau     - kvm (64 bit only), tcg, xen
4454ab3c3fSAlex Bennée   * - MIPS (little endian only)
457f800d34SMarc-André Lureau     - kvm, tcg
467f800d34SMarc-André Lureau   * - PPC
477f800d34SMarc-André Lureau     - kvm, tcg
487f800d34SMarc-André Lureau   * - RISC-V
4907952003SBin Meng     - kvm, tcg
507f800d34SMarc-André Lureau   * - s390x
517f800d34SMarc-André Lureau     - kvm, tcg
527f800d34SMarc-André Lureau   * - SPARC
537f800d34SMarc-André Lureau     - tcg
547f800d34SMarc-André Lureau   * - x86
55*b91b0fc1SPhilippe Mathieu-Daudé     - hvf (64 bit only), kvm, nvmm, tcg, whpx (64 bit only), xen
567f800d34SMarc-André Lureau
57f1f727acSPhilippe Mathieu-DaudéOther host architectures are not supported. It is possible to build QEMU system
58f1f727acSPhilippe Mathieu-Daudéemulation on an unsupported host architecture using the configure
59f1f727acSPhilippe Mathieu-Daudé``--enable-tcg-interpreter`` option to enable the TCI support, but note that
60f1f727acSPhilippe Mathieu-Daudéthis is very slow and is not recommended for normal use. QEMU user emulation
61f1f727acSPhilippe Mathieu-Daudérequires host-specific support for signal handling, therefore TCI won't help
62f1f727acSPhilippe Mathieu-Daudéon unsupported host architectures.
637f800d34SMarc-André Lureau
647f800d34SMarc-André LureauNon-supported architectures may be removed in the future following the
657f800d34SMarc-André Lureau:ref:`deprecation process<Deprecated features>`.
667f800d34SMarc-André Lureau
67f3478392SPeter MaydellLinux OS, macOS, FreeBSD, NetBSD, OpenBSD
68f3478392SPeter Maydell-----------------------------------------
69f3478392SPeter Maydell
7096dcf1aaSThomas HuthThe project aims to support the most recent major version at all times for
7196dcf1aaSThomas Huthup to five years after its initial release. Support
72f3478392SPeter Maydellfor the previous major version will be dropped 2 years after the new major
73f3478392SPeter Maydellversion is released or when the vendor itself drops support, whichever comes
74f3478392SPeter Maydellfirst. In this context, third-party efforts to extend the lifetime of a distro
75fbf8c96bSAndrea Bolognaniare not considered, even when they are endorsed by the vendor (eg. Debian LTS);
76fbf8c96bSAndrea Bolognanithe same is true of repositories that contain packages backported from later
77fbf8c96bSAndrea Bolognanireleases (e.g. Debian backports). Within each major release, only the most
78fbf8c96bSAndrea Bolognanirecent minor release is considered.
79f3478392SPeter Maydell
80f3478392SPeter MaydellFor the purposes of identifying supported software versions available on Linux,
81f3478392SPeter Maydellthe project will look at CentOS, Debian, Fedora, openSUSE, RHEL, SLES and
82f3478392SPeter MaydellUbuntu LTS. Other distros will be assumed to ship similar software versions.
83f3478392SPeter Maydell
84f3478392SPeter MaydellFor FreeBSD and OpenBSD, decisions will be made based on the contents of the
85f3478392SPeter Maydellrespective ports repository, while NetBSD will use the pkgsrc repository.
86f3478392SPeter Maydell
874a89bf18SStefan WeilFor macOS, `Homebrew`_ will be used, although `MacPorts`_ is expected to carry
88f3478392SPeter Maydellsimilar versions.
89f3478392SPeter Maydell
908d0efbcfSPaolo BonziniSome build dependencies may follow less conservative rules:
918d0efbcfSPaolo Bonzini
928d0efbcfSPaolo BonziniPython runtime
938d0efbcfSPaolo Bonzini  Distributions with long-term support often provide multiple versions
948d0efbcfSPaolo Bonzini  of the Python runtime.  While QEMU will initially aim to support the
958d0efbcfSPaolo Bonzini  distribution's default runtime, it may later increase its minimum version
968d0efbcfSPaolo Bonzini  to any newer python that is available as an option from the vendor.
978d0efbcfSPaolo Bonzini  In this case, it will be necessary to use the ``--python`` command line
988d0efbcfSPaolo Bonzini  option of the ``configure`` script to point QEMU to a supported
998d0efbcfSPaolo Bonzini  version of the Python runtime.
1008d0efbcfSPaolo Bonzini
1015591b745SPaolo Bonzini  As of QEMU |version|, the minimum supported version of Python is 3.7.
1028d0efbcfSPaolo Bonzini
1038d0efbcfSPaolo BonziniPython build dependencies
1048d0efbcfSPaolo Bonzini  Some of QEMU's build dependencies are written in Python.  Usually these
1058d0efbcfSPaolo Bonzini  are only packaged by distributions for the default Python runtime.
1068d0efbcfSPaolo Bonzini  If QEMU bumps its minimum Python version and a non-default runtime is
1078d0efbcfSPaolo Bonzini  required, it may be necessary to fetch python modules from the Python
1088d0efbcfSPaolo Bonzini  Package Index (PyPI) via ``pip``, in order to build QEMU.
1098d0efbcfSPaolo Bonzini
1108d0efbcfSPaolo BonziniOptional build dependencies
1118d0efbcfSPaolo Bonzini  Build components whose absence does not affect the ability to build
1128d0efbcfSPaolo Bonzini  QEMU may not be available in distros, or may be too old for QEMU's
1138d0efbcfSPaolo Bonzini  requirements.  Many of these, such as the Avocado testing framework
1148d0efbcfSPaolo Bonzini  or various linters, are written in Python and therefore can also
1158d0efbcfSPaolo Bonzini  be installed using ``pip``.  Cross compilers are another example
1168d0efbcfSPaolo Bonzini  of optional build-time dependency; in this case it is possible to
1178d0efbcfSPaolo Bonzini  download them from repositories such as EPEL, to use container-based
1188d0efbcfSPaolo Bonzini  cross compilation using ``docker`` or ``podman``, or to use pre-built
1198d0efbcfSPaolo Bonzini  binaries distributed with QEMU.
1208d0efbcfSPaolo Bonzini
1218d0efbcfSPaolo Bonzini
122f3478392SPeter MaydellWindows
123f3478392SPeter Maydell-------
124f3478392SPeter Maydell
1250ce9b08cSThomas HuthThe project aims to support the two most recent versions of Windows that are
1260ce9b08cSThomas Huthstill supported by the vendor. The minimum Windows API that is currently
127cf60ccc3SAkihiko Odakitargeted is "Windows 8", so theoretically the QEMU binaries can still be run
1280ce9b08cSThomas Huthon older versions of Windows, too. However, such old versions of Windows are
1290ce9b08cSThomas Huthnot tested anymore, so it is recommended to use one of the latest versions of
1300ce9b08cSThomas HuthWindows instead.
131f3478392SPeter Maydell
1320ce9b08cSThomas HuthThe project supports building QEMU with current versions of the MinGW
133b67de91eSBin Mengtoolchain, either hosted on Linux (Debian/Fedora) or via `MSYS2`_ on Windows.
134b67de91eSBin MengA more recent Windows version is always preferred as it is less likely to have
135b67de91eSBin Mengproblems with building via MSYS2. The building process of QEMU involves some
136b67de91eSBin MengPython scripts that call os.symlink() which needs special attention for the
137b67de91eSBin Mengbuild process to successfully complete. On newer versions of Windows 10,
138b67de91eSBin Mengunprivileged accounts can create symlinks if Developer Mode is enabled.
139b67de91eSBin MengWhen Developer Mode is not available/enabled, the SeCreateSymbolicLinkPrivilege
140b67de91eSBin Mengprivilege is required, or the process must be run as an administrator.
141f3478392SPeter Maydell
1424a89bf18SStefan Weil.. _Homebrew: https://brew.sh/
143f3478392SPeter Maydell.. _MacPorts: https://www.macports.org/
144b67de91eSBin Meng.. _MSYS2: https://www.msys2.org/
145f3478392SPeter Maydell.. _Repology: https://repology.org/
146