lean4-htt/doc/make/msys2.md
Andrew Ashworth 3153b72415 fix(doc/make/msys2): incorrect build instructions
-D CMAKE_BUILD_TYPE=Release does nothing since the default build type is Release. Also, it should be enclosed in quotes "-D CMAKE_BUILD_TYPE=Release", otherwise the shell/cmake fails to properly interpret the arguments.
2016-12-15 10:07:01 -08:00

1,015 B

Lean for Windows

A native Lean binary for Windows can be generated using msys2. It is easy to install all dependencies, it produces native 64/32-binaries, and supports a C++11 compiler.

Installing dependencies

The official webpage of msys2 provides one-click installers. We assume that you install msys2 at c:\msys64. Once installed it, you should run the "MSYS2 MinGW 64-bit shell" from the start menu. It has a package management system, pacman, which is used in Arch Linux.

Here are the commands to install all dependencies needed to compile Lean on your machine.

pacman -S mingw-w64-x86_64-gcc mingw-w64-x86_64-mpfr mingw-w64-x86_64-ninja mingw-w64-x86_64-cmake git

Build Lean

In the msys2 shell, execute the following commands.

git clone https://github.com/leanprover/lean
cd lean
mkdir build && cd build
cmake ../src -G Ninja
ninja