Skip to content

DOC: Windows build instructions #59689

Closed
@andrewgsavage

Description

@andrewgsavage

Pandas version checks

  • I have checked that the issue still exists on the latest versions of the docs on main here

Location of the documentation

https://pandas.pydata.org/docs/dev/development/contributing_environment.html#step-1-install-a-c-compiler

Documentation problem

Installing VS Build Tools 2022 with default settings gives me the following error when I build with mason:


(pandas-dev) C:\Users\andre\repos\pandas>python -m pip install -ve . --no-build-isolation --config-settings editable-verbose=true
Using pip 24.2 from C:\Users\andre\mambaforge\envs\pandas-dev\lib\site-packages\pip (python 3.10)
Obtaining file:///C:/Users/andre/repos/pandas
  Running command Checking if build backend supports build_editable
  Checking if build backend supports build_editable ... done
  Running command Preparing editable metadata (pyproject.toml)
  + meson setup C:\Users\andre\repos\pandas C:\Users\andre\repos\pandas\build\cp310 -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --vsenv --native-file=C:\Users\andre\repos\pandas\build\cp310\meson-python-native-file.ini
  The Meson build system
  Version: 1.2.1
  Source dir: C:\Users\andre\repos\pandas
  Build dir: C:\Users\andre\repos\pandas\build\cp310
  Build type: native build
  Project name: pandas
  Project version: 3.0.0.dev0+1427.ge07453e24d

  ..\..\meson.build:2:0: ERROR: Unknown compiler(s): [['cl.exe']]
  The following exception(s) were encountered:
  Running `cl.exe /?` gave "[WinError 2] The system cannot find the file specified"

  A full log can be found at C:\Users\andre\repos\pandas\build\cp310\meson-logs\meson-log.txt
  error: subprocess-exited-with-error

  × Preparing editable metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> See above for output.

  note: This error originates from a subprocess, and is likely not a problem with pip.
  full command: 'C:\Users\andre\mambaforge\envs\pandas-dev\python.exe' 'C:\Users\andre\mambaforge\envs\pandas-dev\lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py' prepare_metadata_for_build_editable 'C:\Users\andre\AppData\Local\Temp\tmp_6e6694l'
  cwd: C:\Users\andre\repos\pandas
  Preparing editable metadata (pyproject.toml) ... error
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

Suggested fix for documentation

Include instructions to select the optional MSVC v142 - VS 2019 C++ x64/x86 build tools on the right of the window:

image

after installing this it compiled.

Metadata

Metadata

Assignees

Labels

BuildLibrary building on various platformsDocsWindowsWindows OS

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions