From: Dylan Baker
Meson is the latest build system in mesa, it is currently able to build for
-*nix systems like Linux and BSD, macOS, Haiku, and will be able to build for
-windows as well.
+*nix systems like Linux and BSD, macOS, Haiku, and Windows.
@@ -121,6 +120,14 @@ The general approach is:
ninja -C builddir/
sudo ninja -C builddir/ install
+
+ On windows you can also use the visual studio backend
Please read the detailed meson instructions
for more information
diff --git a/docs/meson.html b/docs/meson.html
index 0291f90658b..013ed325684 100644
--- a/docs/meson.html
+++ b/docs/meson.html
@@ -31,9 +31,13 @@
Mesa's Meson build system is generally considered stable and ready
for production. The Meson build of Mesa is tested on Linux, macOS, Cygwin and Haiku, FreeBSD,
+ Mesa requires Meson >= 0.46.0 to build.
+
+ The Meson build of Mesa is tested on Linux, macOS, Windows, Cygwin, Haiku, FreeBSD,
DragonflyBSD, NetBSD, and should work on OpenBSD. If Meson is not already installed on your system, you can typically
install it with your package installer. For example: Mesa requires Meson >= 0.46.0 to build.
-
Some older versions of meson do not check that they are too old and will error
out in odd ways.
Build system
-
+ meson builddir --backend=vs
+ cd builddir
+ msbuild mesa.sln /m
+
+
Unix-like OSes
+
@@ -44,8 +48,6 @@ or
sudo dnf install meson # Fedora
-
+You will need to install python3 and meson as a module using pip. This is +because we use python for generating code, and rely on external modules +(mako). You also need pkg-config (a hard dependency of meson), flex, and bison. + +The easiest way to install everything you need is with chocolatey. +
++ choco install python3 winflexbison pkgconfiglite ++
You can even use chocolatey to install mingw and ninja (ninja can be used with MSVC as well)
++ choco install ninja mingw ++
Then install meson using pip
++ py -3 -m pip install meson mako ++ +You may need to add the python3 scripts directory to your path for meson. +
@@ -152,6 +178,29 @@ Meson does not do this. Instead, you will need do this: ninja -C build/ xmlpool-pot xmlpool-update-po xmlpool-gmo +
+On windows you have a couple of choices for compilers. If you installed mingw +with chocolatey and want to use ninja you should be able to open any shell +and follow the instructions above. If you want to you MSVC, clang-cl, or ICL +(the Intel Compiler), read on. +
++Both ICL and MSVC come with shell environments, the easiest way to use meson +with these it to open a shell. For clang-cl you will need to open an MSVC +shell, and then override the compilers, either using a native file, or +with the CC and CXX environment variables. +
+
+All of these compilers are tested and work with ninja, but if you want visual
+studio integration or you just like msbuild, passing
+--backend=vs
to meson will generate a visual studio solution. If
+you want to use ICL or clang-cl with the vsbackend you will need meson 0.52.0
+or greater. Older versions always use the microsoft compiler.
+