Skip to content

Commit 118cb0e

Browse files
committed
dont build custom or quantized ops on msvc cuda
1 parent 98baab7 commit 118cb0e

File tree

1 file changed

+9
-11
lines changed

1 file changed

+9
-11
lines changed

examples/models/voxtral/CMakeLists.txt

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,16 @@ executorch_target_link_options_shared_lib(executorch)
3939
set(link_libraries executorch gflags)
4040
set(_srcs multimodal.cpp)
4141

42-
list(
43-
APPEND
44-
link_libraries
45-
optimized_native_cpu_ops_lib
46-
quantized_ops_lib
47-
custom_ops
48-
cpublas
49-
eigen_blas
50-
)
42+
# Common ops for all builds
43+
list(APPEND link_libraries optimized_native_cpu_ops_lib cpublas eigen_blas)
5144
executorch_target_link_options_shared_lib(optimized_native_cpu_ops_lib)
52-
executorch_target_link_options_shared_lib(quantized_ops_lib)
53-
executorch_target_link_options_shared_lib(custom_ops)
45+
46+
# CPU-only builds need quantized and custom ops
47+
if(NOT EXECUTORCH_BUILD_CUDA AND MSVC)
48+
list(APPEND link_libraries quantized_ops_lib custom_ops)
49+
executorch_target_link_options_shared_lib(quantized_ops_lib)
50+
executorch_target_link_options_shared_lib(custom_ops)
51+
endif()
5452

5553
# XNNPACK
5654
if(TARGET xnnpack_backend)

0 commit comments

Comments
 (0)