Skip to content

Commit 5982f36

Browse files
committed
Clean stub files that were generated recursively
1 parent 3553850 commit 5982f36

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cmake/nanobind-config.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,8 @@ function (nanobind_add_stub name)
430430
${NB_STUBGEN_EXTRA}
431431
)
432432
add_custom_target(${name} ALL DEPENDS ${NB_STUBGEN_OUTPUTS} ${STUB_FAKE_FILE})
433+
file(GLOB STUB_FILES CONFIGURE_DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/*.pyi" )
434+
set_target_properties(${name} PROPERTIES ADDITIONAL_CLEAN_FILES "${STUB_FILES}")
433435
else()
434436
set(NB_STUBGEN_EXTRA "")
435437
if (ARG_COMPONENT)

0 commit comments

Comments
 (0)