Skip to content

Commit 4df87ae

Browse files
committed
Update AddMLIRPython.cmake
1 parent 859939a commit 4df87ae

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

mlir/cmake/modules/AddMLIRPython.cmake

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,11 @@ function(generate_type_stubs module_name depends_target mlir_depends_target outp
130130
OUTPUT ${NB_STUBGEN_OUTPUT}
131131
COMMAND ${NB_STUBGEN_CMD}
132132
WORKING_DIRECTORY "${CMAKE_CURRENT_FUNCTION_LIST_DIR}"
133-
DEPENDS "${mlir_depends_target}" "${depends_target}" MLIRPythonSources.Core.Python)
133+
DEPENDS
134+
"${mlir_depends_target}.extension._mlir.dso"
135+
"${mlir_depends_target}.sources.MLIRPythonSources.Core.Python"
136+
"${depends_target}"
137+
)
134138
set(_name "MLIRPythonModuleStubs_${_module}")
135139
add_custom_target("${_name}" ALL DEPENDS ${NB_STUBGEN_OUTPUT})
136140
set(NB_STUBGEN_CUSTOM_TARGET "${_name}" PARENT_SCOPE)
@@ -292,7 +296,7 @@ function(add_mlir_python_modules name)
292296
generate_type_stubs(
293297
${_module_name}
294298
${_extension_target}
295-
"${modules_target}.extension._mlir.dso"
299+
${name}
296300
"${CMAKE_CURRENT_SOURCE_DIR}/mlir/_mlir_libs/_mlir"
297301
)
298302
declare_mlir_python_sources(

0 commit comments

Comments
 (0)