Skip to content

Support build on native Windows #4661

Open
@python3kgae

Description

@python3kgae

🚀 The feature, motivation and pitch

Currently, executorch supports Windows via WSL.
It would be beneficial to enable native Windows builds as well, as this would assist users who do not have WSL installed.

Alternatives

Executorch already supports Windows via WSL.

Additional context

No response

RFC (Optional)

The plan is to create a PowerShell version of install_requirements.sh.

Here is a list of things that need to be updated for building on native Windows:

  • Resolve build issues in file_data_loader.cpp, which includes <unistd.h>, and invoke ::close on -1.
  • Get the Windows version of buck2 for Windows build in build/resolve_buck.py.
  • Check the path based on the build configuration for Windows in setup.py. For example, third-party/flatbuffers/flatc should be third-party/flatbuffers/Debug/flatc.exe for Debug builds.
  • Avoid generating 'def flat.exe()' which is illegal python in build/pip_data_bin_init.py.in.
  • Add the Windows version of kernel_link_options in build/Utils.cmake.
  • Add links of pthreadpool and cpuinfo for custom_ops_aot_lib in extension/llm/custom_ops/CMakeLists.txt.
  • Define ssize_t for Windows in runtime/core/portable_type/tensor_impl.h and runtime/core/exec_aten/util/tensor_util.h.
  • [Build] choose_qparams_tensor_out get wrong return type cause build fail on native Windows #4659

Metadata

Metadata

Assignees

Labels

module: build/installIssues related to the cmake and buck2 builds, and to installing ExecuTorchtriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

Type

No type

Projects

Status

To triage

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions