66
66
67
67
[MSYS2][msys2] can be used to easily build Rust on Windows:
68
68
69
- msys2: https://msys2.github.io/
69
+ [ msys2] : https://msys2.github.io/
70
70
71
71
1. Grab the latest [MSYS2 installer][msys2] and go through the installer.
72
72
@@ -105,7 +105,7 @@ msys2: https://msys2.github.io/
105
105
106
106
MSVC builds of Rust additionally require an installation of Visual Studio 2013
107
107
(or later) so `rustc` can use its linker. Make sure to check the “C++ tools”
108
- option. In addition, `cmake` needs to be installed to build LLVM.
108
+ option.
109
109
110
110
With these dependencies installed, the build takes two steps:
111
111
@@ -116,13 +116,25 @@ $ make && make install
116
116
117
117
#### MSVC with rustbuild
118
118
119
- For those who don' t want the hassle of MSYS or MinGW, you can invoke rustbuild
120
- directly. All you need are Python 2, CMake, and Git in your PATH (make sure you
121
- do __not__ use the ones from MSYS! ). You' ll also need Visual Studio 2013 or
122
- newer with the C++ tools. Then all you need to do is invoke the appropriate
123
- vcvars bat file and kick off rustbuild.
119
+ The old build system, based on makefiles, is currently being rewritten into a
120
+ Rust-based build system called rustbuild. This can be used to bootstrap the
121
+ compiler on MSVC without needing to install MSYS or MinGW. All you need are
122
+ [Python 2](https://www.python.org/downloads/),
123
+ [CMake](https://cmake.org/download/), and
124
+ [Git](https://git-scm.com/downloads) in your PATH (make sure you do not use the
125
+ ones from MSYS if you have it installed). You' ll also need Visual Studio 2013 or
126
+ newer with the C++ tools. Then all you need to do is to kick off rustbuild.
124
127
125
- ```bat
128
+ ` ` `
129
+ python .\s rc\b ootstrap\b ootstrap.py
130
+ ` ` `
131
+
132
+ Currently rustbuild only works with some known versions of Visual Studio. If you
133
+ have a more recent version installed that a part of rustbuild doesn' t understand
134
+ then you may need to force rustbuild to use an older version. This can be done
135
+ by manually calling the appropriate vcvars file before running the bootstrap.
136
+
137
+ ```
126
138
CALL "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\amd64\vcvars64.bat"
127
139
python .\src\bootstrap\bootstrap.py
128
140
```
0 commit comments