summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--build/export_generators/hardcoded-cmake/cmake/cython.cmake1
-rw-r--r--cmake/cython.cmake1
2 files changed, 2 insertions, 0 deletions
diff --git a/build/export_generators/hardcoded-cmake/cmake/cython.cmake b/build/export_generators/hardcoded-cmake/cmake/cython.cmake
index d239c2dc58a..c14d8941697 100644
--- a/build/export_generators/hardcoded-cmake/cmake/cython.cmake
+++ b/build/export_generators/hardcoded-cmake/cmake/cython.cmake
@@ -35,6 +35,7 @@ function(target_cython_sources Tgt Scope)
"-I$<JOIN:$<TARGET_GENEX_EVAL:${Tgt},$<TARGET_PROPERTY:${Tgt},CYTHON_INCLUDE_DIRS>>,$<SEMICOLON>-I>"
COMMAND_EXPAND_LISTS
DEPENDS ${OUTPUT_INCLUDES}
+ MAIN_DEPENDENCY ${Input}
)
target_sources(${Tgt} ${Scope} ${CppCythonOutput})
endforeach()
diff --git a/cmake/cython.cmake b/cmake/cython.cmake
index d239c2dc58a..c14d8941697 100644
--- a/cmake/cython.cmake
+++ b/cmake/cython.cmake
@@ -35,6 +35,7 @@ function(target_cython_sources Tgt Scope)
"-I$<JOIN:$<TARGET_GENEX_EVAL:${Tgt},$<TARGET_PROPERTY:${Tgt},CYTHON_INCLUDE_DIRS>>,$<SEMICOLON>-I>"
COMMAND_EXPAND_LISTS
DEPENDS ${OUTPUT_INCLUDES}
+ MAIN_DEPENDENCY ${Input}
)
target_sources(${Tgt} ${Scope} ${CppCythonOutput})
endforeach()