File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,7 +40,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
4040add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
4141
4242# Ensure Cython modules build first so _usmarray.h exists
43- add_dependencies (${python_module_name} _usmarray )
43+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
44+ if (TARGET _usmarray)
45+ add_dependencies (${python_module_name} _usmarray )
46+ endif ()
4447
4548if (_dpnp_sycl_targets)
4649 # make fat binary
Original file line number Diff line number Diff line change @@ -34,7 +34,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
3434add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
3535
3636# Ensure Cython modules build first so _usmarray.h exists
37- add_dependencies (${python_module_name} _usmarray )
37+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
38+ if (TARGET _usmarray)
39+ add_dependencies (${python_module_name} _usmarray )
40+ endif ()
3841
3942if (_dpnp_sycl_targets)
4043 # make fat binary
Original file line number Diff line number Diff line change @@ -37,7 +37,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
3737add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
3838
3939# Ensure Cython modules build first so _usmarray.h exists
40- add_dependencies (${python_module_name} _usmarray )
40+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
41+ if (TARGET _usmarray)
42+ add_dependencies (${python_module_name} _usmarray )
43+ endif ()
4144
4245if (_dpnp_sycl_targets)
4346 # make fat binary
Original file line number Diff line number Diff line change @@ -57,7 +57,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
5757add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
5858
5959# Ensure Cython modules build first so _usmarray.h exists
60- add_dependencies (${python_module_name} _usmarray )
60+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
61+ if (TARGET _usmarray)
62+ add_dependencies (${python_module_name} _usmarray )
63+ endif ()
6164
6265if (_dpnp_sycl_targets)
6366 # make fat binary
Original file line number Diff line number Diff line change @@ -42,7 +42,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
4242add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
4343
4444# Ensure Cython modules build first so _usmarray.h exists
45- add_dependencies (${python_module_name} _usmarray )
45+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
46+ if (TARGET _usmarray)
47+ add_dependencies (${python_module_name} _usmarray )
48+ endif ()
4649
4750if (_dpnp_sycl_targets)
4851 # make fat binary
Original file line number Diff line number Diff line change @@ -68,7 +68,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
6868add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
6969
7070# Ensure Cython modules build first so _usmarray.h exists
71- add_dependencies (${python_module_name} _usmarray )
71+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
72+ if (TARGET _usmarray)
73+ add_dependencies (${python_module_name} _usmarray )
74+ endif ()
7275
7376if (WIN32 )
7477 if (${CMAKE_VERSION} VERSION_LESS "3.27" )
Original file line number Diff line number Diff line change @@ -91,7 +91,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
9191add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
9292
9393# Ensure Cython modules build first so _usmarray.h exists
94- add_dependencies (${python_module_name} _usmarray )
94+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
95+ if (TARGET _usmarray)
96+ add_dependencies (${python_module_name} _usmarray )
97+ endif ()
9598
9699if (WIN32 )
97100 if (${CMAKE_VERSION} VERSION_LESS "3.27" )
Original file line number Diff line number Diff line change @@ -37,7 +37,10 @@ pybind11_add_module(${python_module_name} MODULE ${_module_src})
3737add_sycl_to_target (TARGET ${python_module_name} SOURCES ${_module_src} )
3838
3939# Ensure Cython modules build first so _usmarray.h exists
40- add_dependencies (${python_module_name} _usmarray )
40+ # Only add dependency if tensor module is being built (not in SKIP_TENSOR mode)
41+ if (TARGET _usmarray)
42+ add_dependencies (${python_module_name} _usmarray )
43+ endif ()
4144
4245if (_dpnp_sycl_targets)
4346 # make fat binary
You can’t perform that action at this time.
0 commit comments