Skip to content

Commit 79fd073

Browse files
committed
Fix wheel build
1 parent 6e71eec commit 79fd073

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

setup.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -814,8 +814,8 @@ def run(self): # noqa C901
814814
if cmake_cache.is_enabled("EXECUTORCH_BUILD_PYBIND"):
815815
cmake_build_args += ["--target", "portable_lib"]
816816
cmake_build_args += ["--target", "selective_build"]
817-
# TODO(larryliu0820): Temporarily disable building llm_runner for Windows
818-
if cmake_cache.is_enabled("EXECUTORCH_BUILD_LLM_RUNNER") and not _is_windows():
817+
818+
if cmake_cache.is_enabled("EXECUTORCH_BUILD_EXTENSION_LLM_RUNNER"):
819819
cmake_build_args += ["--target", "_llm_runner"]
820820

821821
if cmake_cache.is_enabled("EXECUTORCH_BUILD_EXTENSION_MODULE"):
@@ -890,7 +890,7 @@ def run(self): # noqa C901
890890
BuiltExtension(
891891
src="extension/llm/runner/_llm_runner.*", # @lint-ignore https://github.com/pytorch/executorch/blob/cb3eba0d7f630bc8cec0a9cc1df8ae2f17af3f7a/scripts/lint_xrefs.sh
892892
modpath="executorch.extension.llm.runner._llm_runner",
893-
dependent_cmake_flags=["EXECUTORCH_BUILD_PYBIND"],
893+
dependent_cmake_flags=["EXECUTORCH_BUILD_EXTENSION_LLM_RUNNER"],
894894
),
895895
BuiltExtension(
896896
src="executorchcoreml.*",

tools/cmake/preset/pybind.cmake

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ set_overridable_option(EXECUTORCH_BUILD_KERNELS_QUANTIZED_AOT ON)
1313
set_overridable_option(EXECUTORCH_ENABLE_LOGGING ON)
1414
set_overridable_option(EXECUTORCH_LOG_LEVEL Info)
1515
set_overridable_option(EXECUTORCH_BUILD_XNNPACK ON)
16-
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM ON)
17-
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM_RUNNER ON)
1816
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TENSOR ON)
1917
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL ON)
2018
set_overridable_option(EXECUTORCH_BUILD_KERNELS_LLM ON)
@@ -24,12 +22,18 @@ set_overridable_option(EXECUTORCH_BUILD_EXTENSION_DATA_LOADER ON)
2422
set_overridable_option(EXECUTORCH_BUILD_KERNELS_OPTIMIZED ON)
2523
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_MODULE ON)
2624

25+
# TODO(larryliu0820): Temporarily disable building llm_runner for Windows
26+
# wheel due to the issue of tokenizer file path length limitation.
2727
if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
2828
set_overridable_option(EXECUTORCH_BUILD_COREML ON)
2929
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TRAINING ON)
30+
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM_RUNNER ON)
31+
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM ON)
3032
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
3133
set_overridable_option(EXECUTORCH_BUILD_COREML ON)
3234
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TRAINING ON)
35+
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM_RUNNER ON)
36+
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_LLM ON)
3337
elseif(CMAKE_SYSTEM_NAME STREQUAL "Windows" OR CMAKE_SYSTEM_NAME STREQUAL
3438
"WIN32"
3539
)

0 commit comments

Comments
 (0)