diff options
Diffstat (limited to 'host')
-rw-r--r-- | host/cmake/Modules/UHDImagesDownloader.cmake | 6 | ||||
-rw-r--r-- | host/utils/CMakeLists.txt | 15 |
2 files changed, 16 insertions, 5 deletions
diff --git a/host/cmake/Modules/UHDImagesDownloader.cmake b/host/cmake/Modules/UHDImagesDownloader.cmake new file mode 100644 index 000000000..63c5ded75 --- /dev/null +++ b/host/cmake/Modules/UHDImagesDownloader.cmake @@ -0,0 +1,6 @@ +#UHD images downloader configuration +FILE(READ ${CURRENT_DIR}/../../images/manifest.txt CMAKE_MANIFEST_CONTENTS) +CONFIGURE_FILE( + ${CURRENT_DIR}/uhd_images_downloader.py.in + ${INSTALL_DIR}/uhd_images_downloader.py +@ONLY) diff --git a/host/utils/CMakeLists.txt b/host/utils/CMakeLists.txt index 6ecfb4ba3..4ca33c2ba 100644 --- a/host/utils/CMakeLists.txt +++ b/host/utils/CMakeLists.txt @@ -121,11 +121,16 @@ IF(ENABLE_X300) ENDIF(ENABLE_X300) #UHD images downloader configuration -FILE(READ ${CMAKE_CURRENT_SOURCE_DIR}/../../images/manifest.txt CMAKE_MANIFEST_CONTENTS) -CONFIGURE_FILE( - ${CMAKE_CURRENT_SOURCE_DIR}/uhd_images_downloader.py.in - ${CMAKE_CURRENT_BINARY_DIR}/uhd_images_downloader.py -@ONLY) +ADD_CUSTOM_TARGET(images_downloader ALL + COMMAND + ${CMAKE_COMMAND} + -DCURRENT_DIR=${CMAKE_CURRENT_SOURCE_DIR} + -DINSTALL_DIR=${CMAKE_CURRENT_BINARY_DIR} + -P ${CMAKE_SOURCE_DIR}/cmake/Modules/UHDImagesDownloader.cmake + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/uhd_images_downloader.py.in + ${CMAKE_CURRENT_SOURCE_DIR}/../../images/manifest.txt +) UHD_INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/uhd_images_downloader.py DESTINATION ${PKG_LIB_DIR}/utils |