Skip to content

Commit

Permalink
Add CMake targets for Python files
Browse files Browse the repository at this point in the history
This directs IDEs like Qt Creator to show the Python code as project
files.
  • Loading branch information
daljit46 committed Jun 14, 2024
1 parent 648468f commit fe31fc9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions python/mrtrix3/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@ set_target_properties(MakePythonVersionFile
PROPERTIES ADDITIONAL_CLEAN_FILES ${PYTHON_VERSION_FILE}
)

add_custom_target(PythonLibFiles
SOURCES ${PYTHON_LIB_FILES}
)

install(FILES ${PYTHON_LIB_FILES}
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
DESTINATION ${CMAKE_INSTALL_LIBDIR}/mrtrix3
Expand Down
4 changes: 4 additions & 0 deletions python/mrtrix3/commands/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ add_custom_command(
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
)

add_custom_target(PythonCommands
SOURCES ${PYTHON_ALL_COMMANDS_FILES}
)

install(FILES ${PYTHON_BIN_FILES}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
DESTINATION ${CMAKE_INSTALL_BINDIR}
Expand Down

0 comments on commit fe31fc9

Please sign in to comment.