8000 DOC Simplify Windows build instructions (#31202) · scikit-learn/scikit-learn@4bf49d0 · GitHub
[go: up one dir, main page]

Skip to content

Commit 4bf49d0

Browse files
authored
DOC Simplify Windows build instructions (#31202)
1 parent 603720d commit 4bf49d0

File tree

1 file changed

+3
-34
lines changed

1 file changed

+3
-34
lines changed

doc/developers/advanced_installation.rst

Lines changed: 3 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -168,43 +168,12 @@ screenshot:
168168

169169
.. image:: ../images/visual-studio-build-tools-selection.png
170170

171-
Secondly, find out if you are running 64-bit or 32-bit Python. The building
172-
command depends on the architecture of the Python interpreter. You can check
173-
the architecture by running the following in ``cmd`` or ``powershell``
174-
console:
171+
Build scikit-learn by running the following command in your `sklearn-env` conda environment
172+
or virtualenv:
175173

176174
.. prompt:: bash $
177175

178-
python -c "import struct; print(struct.calcsize('P') * 8)"
179-
180-
For 64-bit Python, configure the build environment by running the following
181-
commands in ``cmd`` or an Anaconda Prompt (if you use Anaconda):
182-
183-
.. sphinx-prompt 1.3.0 (used in doc-min-dependencies CI task) does not support `batch` prompt type,
184-
.. so we work around by using a known prompt type and an explicit prompt text.
185-
..
186-
.. prompt:: bash C:\>
187-
188-
SET DISTUTILS_USE_SDK=1
189-
"C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\Build\vcvarsall.bat" x64
190-
191-
.. note::
192-
The previous command is for the 2022 version of Visual Studio. If you
193-
have a different version, you will need to adjust the year in the path accordingly.
194-
195-
Replace ``x64`` by ``x86`` to build for 32-bit Python.
196-
197-
Please be aware that the path above might be different from user to user. The
198-
aim is to point to the "vcvarsall.bat" file that will set the necessary
199-
environment variables in the current command prompt.
200-
201-
Finally, build scikit-learn with this command prompt:
202-
203-
.. prompt:: bash $
204-
205-
pip install --editable . \
206-
--verbose --no-build-isolation \
207-
--config-settings editable-verbose=true
176+
pip install --editable . --verbose --no-build-isolation --config-settings editable-verbose=true
208177

209178
.. _compiler_macos:
210179

0 commit comments

Comments
 (0)
0