Skip to content

Commit b2e30ed

Browse files
committed
move simple options
1 parent bbd11ec commit b2e30ed

File tree

2 files changed

+140
-68
lines changed

2 files changed

+140
-68
lines changed

CMakeLists.txt

Lines changed: 0 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -128,74 +128,6 @@ else()
128128
set(CMAKE_CXX_FLAGS_RELEASE "-O2 ${CMAKE_CXX_FLAGS_RELEASE}")
129129
endif()
130130

131-
option(EXECUTORCH_BUILD_ARM_BAREMETAL
132-
"Build the Arm Baremetal flow for Cortex-M and Ethos-U" OFF
133-
)
134-
135-
option(EXECUTORCH_BUILD_KERNELS_CUSTOM "Build the custom kernels" OFF)
136-
137-
option(EXECUTORCH_BUILD_KERNELS_CUSTOM_AOT "Build the custom ops lib for AOT"
138-
OFF
139-
)
140-
141-
option(EXECUTORCH_BUILD_EXTENSION_DATA_LOADER "Build the Data Loader extension"
142-
OFF
143-
)
144-
145-
option(EXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR "Build the Flat Tensor extension"
146-
OFF
147-
)
148-
149-
option(EXECUTORCH_BUILD_EXTENSION_LLM "Build the LLM extension"
150-
OFF
151-
)
152-
153-
option(EXECUTORCH_BUILD_EXTENSION_MODULE "Build the Module extension" OFF)
154-
155-
option(EXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL "Build the Runner Util extension"
156-
OFF
157-
)
158-
159-
option(EXECUTORCH_BUILD_EXTENSION_TENSOR "Build the Tensor extension" OFF)
160-
161-
option(EXECUTORCH_BUILD_EXTENSION_TRAINING "Build the training extension" OFF)
162-
163-
option(EXECUTORCH_BUILD_MPS "Build the MPS backend" OFF)
164-
165-
option(EXECUTORCH_BUILD_NEURON "Build the backends/mediatek directory" OFF)
166-
167-
option(EXECUTORCH_BUILD_OPENVINO "Build the Openvino backend" OFF)
168-
169-
option(EXECUTORCH_BUILD_PYBIND "Build the Python Bindings" OFF)
170-
171-
option(EXECUTORCH_BUILD_QNN "Build the Qualcomm backend" OFF)
172-
173-
option(EXECUTORCH_BUILD_KERNELS_OPTIMIZED "Build the optimized kernels" OFF)
174-
175-
option(EXECUTORCH_BUILD_KERNELS_QUANTIZED "Build the quantized kernels" OFF)
176-
177-
option(EXECUTORCH_BUILD_DEVTOOLS "Build the ExecuTorch Developer Tools")
178-
179-
option(EXECUTORCH_BUILD_TESTS "Build CMake-based unit tests" OFF)
180-
181-
option(EXECUTORCH_NNLIB_OPT "Build Cadence backend Hifi nnlib kernel" OFF)
182-
183-
option(EXECUTORCH_CADENCE_CPU_RUNNER "Build Cadence backend CPU runner" OFF)
184-
185-
option(EXECUTORCH_BUILD_SIZE_TEST "Build the size test" OFF)
186-
187-
option(EXECUTORCH_BUILD_XNNPACK "Build the XNNPACK backend" OFF)
188-
189-
option(EXECUTORCH_BUILD_VULKAN "Build the Vulkan backend" OFF)
190-
191-
option(BUILD_EXECUTORCH_PORTABLE_OPS "Build portable_ops library" ON)
192-
193-
option(EXECUTORCH_USE_DL "Use libdl library" ON)
194-
195-
option(EXECUTORCH_BUILD_CADENCE "Build the Cadence DSP backend" OFF)
196-
197-
option(EXECUTORCH_BUILD_CORTEX_M "Build the Cortex-M backend" OFF)
198-
199131
#
200132
# pthreadpool: build pthreadpool library. Disable on unsupported platforms
201133
#

tools/cmake/preset/default.cmake

Lines changed: 140 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,146 @@ define_overridable_option(
5959
"Build executorch runtime optimizing for binary size"
6060
BOOL OFF
6161
)
62+
define_overridable_option(
63+
EXECUTORCH_BUILD_ARM_BAREMETAL
64+
"Build the Arm Baremetal flow for Cortex-M and Ethos-U"
65+
BOOL OFF
66+
)
67+
define_overridable_option(
68+
EXECUTORCH_BUILD_KERNELS_CUSTOM
69+
"Build the custom kernels"
70+
BOOL OFF
71+
)
72+
define_overridable_option(
73+
EXECUTORCH_BUILD_KERNELS_CUSTOM_AOT
74+
"Build the custom ops lib for AOT"
75+
BOOL OFF
76+
)
77+
define_overridable_option(
78+
EXECUTORCH_BUILD_EXTENSION_DATA_LOADER
79+
"Build the Data Loader extension"
80+
BOOL OFF
81+
)
82+
define_overridable_option(
83+
EXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR
84+
"Build the Flat Tensor extension"
85+
BOOL OFF
86+
)
87+
define_overridable_option(
88+
EXECUTORCH_BUILD_EXTENSION_LLM
89+
"Build the LLM extension"
90+
BOOL OFF
91+
)
92+
define_overridable_option(
93+
EXECUTORCH_BUILD_EXTENSION_MODULE
94+
"Build the Module extension"
95+
BOOL OFF
96+
)
97+
define_overridable_option(
98+
EXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL
99+
"Build the Runner Util extension"
100+
BOOL OFF
101+
)
102+
define_overridable_option(
103+
EXECUTORCH_BUILD_EXTENSION_TENSOR
104+
"Build the Tensor extension"
105+
BOOL OFF
106+
)
107+
define_overridable_option(
108+
EXECUTORCH_BUILD_EXTENSION_TRAINING
109+
"Build the training extension"
110+
BOOL OFF
111+
)
112+
define_overridable_option(
113+
EXECUTORCH_BUILD_MPS
114+
"Build the MPS backend"
115+
BOOL OFF
116+
)
117+
define_overridable_option(
118+
EXECUTORCH_BUILD_NEURON
119+
"Build the backends/mediatek directory"
120+
BOOL OFF
121+
)
122+
define_overridable_option(
123+
EXECUTORCH_BUILD_OPENVINO
124+
"Build the Openvino backend"
125+
BOOL OFF
126+
)
127+
define_overridable_option(
128+
EXECUTORCH_BUILD_PYBIND
129+
"Build the Python Bindings"
130+
BOOL OFF
131+
)
132+
define_overridable_option(
133+
EXECUTORCH_BUILD_QNN
134+
"Build the Qualcomm backend"
135+
BOOL OFF
136+
)
137+
define_overridable_option(
138+
EXECUTORCH_BUILD_KERNELS_OPTIMIZED
139+
"Build the optimized kernels"
140+
BOOL OFF
141+
)
142+
define_overridable_option(
143+
EXECUTORCH_BUILD_KERNELS_QUANTIZED
144+
"Build the quantized kernels"
145+
BOOL OFF
146+
)
147+
define_overridable_option(
148+
EXECUTORCH_BUILD_DEVTOOLS
149+
"Build the ExecuTorch Developer Tools"
150+
BOOL OFF
151+
)
152+
define_overridable_option(
153+
EXECUTORCH_BUILD_TESTS
154+
"Build CMake-based unit tests"
155+
BOOL OFF
156+
)
157+
define_overridable_option(
158+
EXECUTORCH_NNLIB_OPT
159+
"Build Cadence backend Hifi nnlib kernel"
160+
BOOL OFF
161+
)
162+
define_overridable_option(
163+
EXECUTORCH_CADENCE_CPU_RUNNER
164+
"Build Cadence backend CPU runner"
165+
BOOL OFF
166+
)
167+
define_overridable_option(
168+
EXECUTORCH_BUILD_SIZE_TEST
169+
"Build the size test"
170+
BOOL OFF
171+
)
172+
define_overridable_option(
173+
EXECUTORCH_BUILD_XNNPACK
174+
"Build the XNNPACK backend"
175+
BOOL OFF
176+
)
177+
define_overridable_option(
178+
EXECUTORCH_BUILD_VULKAN
179+
"Build the Vulkan backend"
180+
BOOL OFF
181+
)
182+
define_overridable_option(
183+
BUILD_EXECUTORCH_PORTABLE_OPS
184+
"Build portable_ops library"
185+
BOOL ON
186+
)
187+
define_overridable_option(
188+
EXECUTORCH_USE_DL
189+
"Use libdl library"
190+
BOOL ON
191+
)
192+
define_overridable_option(
193+
EXECUTORCH_BUILD_CADENCE
194+
"Build the Cadence DSP backend"
195+
BOOL OFF
196+
)
197+
define_overridable_option(
198+
EXECUTORCH_BUILD_CORTEX_M
199+
"Build the Cortex-M backend"
200+
BOOL OFF
201+
)
62202

63203
# MARK: - Validations
64204
# At this point all the options should be configured with their final value.

0 commit comments

Comments
 (0)