2018-12-10 16:35:52 +10:00
|
|
|
# See ../CMakeLists.txt for info on staged-plugins* and clean-staged-plugins targets
|
|
|
|
|
2021-03-28 21:49:40 +02:00
|
|
|
set(QGIS_PYTHON_DIR ${Python_SITEARCH}/qgis)
|
2018-12-10 16:35:52 +10:00
|
|
|
|
2020-11-11 11:15:34 +01:00
|
|
|
set(PY_FILES
|
2018-12-10 16:35:52 +10:00
|
|
|
__init__.py
|
|
|
|
algfactory.py
|
|
|
|
)
|
|
|
|
|
2021-05-13 07:32:03 +02:00
|
|
|
file (MAKE_DIRECTORY ${QGIS_PYTHON_OUTPUT_DIRECTORY}/processing)
|
|
|
|
install(FILES ${PY_FILES} DESTINATION "${QGIS_PYTHON_DIR}/processing")
|
2018-12-10 16:35:52 +10:00
|
|
|
|
2021-05-13 07:32:03 +02:00
|
|
|
add_custom_target(pyprocessing ALL)
|
2018-12-10 16:35:52 +10:00
|
|
|
# stage to output to make available when QGIS is run from build directory
|
2020-11-11 11:15:34 +01:00
|
|
|
foreach(pyfile ${PY_FILES})
|
2021-05-13 07:32:03 +02:00
|
|
|
add_custom_command(TARGET pyprocessing
|
2018-12-10 16:35:52 +10:00
|
|
|
POST_BUILD
|
2021-05-13 07:32:03 +02:00
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${pyfile} "${QGIS_PYTHON_OUTPUT_DIRECTORY}/processing"
|
2018-12-10 16:35:52 +10:00
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
2024-12-02 23:32:51 +01:00
|
|
|
# DEPENDS ${pyfile}
|
2018-12-10 16:35:52 +10:00
|
|
|
)
|
2021-05-13 07:32:03 +02:00
|
|
|
PY_COMPILE(pyutils "${QGIS_PYTHON_OUTPUT_DIRECTORY}/processing/${pyfile}")
|
2020-11-11 11:15:34 +01:00
|
|
|
endforeach(pyfile)
|