File tree 1 file changed +11
-2
lines changed
1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -27,8 +27,17 @@ set(py_sources
27
27
JupyROOT/magics/jsrootmagic.py
28
28
)
29
29
30
- set (JupyROOTPySrcDir python/JupyROOT)
31
- file (COPY ${JupyROOTPySrcDir} DESTINATION ${localruntimedir} )
30
+ # Create a target that keeps JupyROOT source in the build tree up to date:
31
+ set (JupyROOTPySrcDir ${CMAKE_CURRENT_SOURCE_DIR} /python/JupyROOT/)
32
+ file (GLOB_RECURSE input_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} ${JupyROOTPySrcDir} /**)
33
+ set (output_files ${input_files} )
34
+ list (TRANSFORM output_files REPLACE "python/" ${localruntimedir} /)
35
+
36
+ add_custom_command (OUTPUT ${output_files}
37
+ COMMAND ${CMAKE_COMMAND} -E copy_directory ${JupyROOTPySrcDir} ${localruntimedir} /JupyROOT/
38
+ COMMENT "Copy JupyROOT"
39
+ DEPENDS ${input_files} )
40
+ add_custom_target (JupyROOT ALL DEPENDS ${output_files} )
32
41
33
42
# Compile .py files
34
43
foreach (py_source ${py_sources} )
You can’t perform that action at this time.
0 commit comments