From c9a91580e3a985dcfb6804ccce306fbceed5e9f9 Mon Sep 17 00:00:00 2001 From: Romain Forlot Date: Mon, 26 Jun 2017 18:31:08 +0200 Subject: Fix: htdocs and data files not populated. Change-Id: Ib1875f988ca7863c9edf6d181d5fe0652de41ab2 Signed-off-by: Romain Forlot --- cmake/macros.cmake | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/cmake/macros.cmake b/cmake/macros.cmake index 4a95d61..2951864 100644 --- a/cmake/macros.cmake +++ b/cmake/macros.cmake @@ -56,6 +56,7 @@ macro(project_targets_populate) get_target_property(P ${TARGET} PREFIX) get_target_property(BD ${TARGET} BINARY_DIR) + get_target_property(SD ${TARGET} SOURCE_DIR) get_target_property(OUT ${TARGET} OUTPUT_NAME) if(P MATCHES "NOTFOUND$") @@ -87,7 +88,8 @@ macro(project_targets_populate) DEPENDS ${TARGET} COMMAND mkdir -p ${PACKAGE_HTTPDIR} COMMAND touch ${PACKAGE_HTTPDIR} - COMMAND cp -r ${BD}/${P}${OUT}/* ${PACKAGE_HTTPDIR} + COMMAND cp -r ${SD}/* ${PACKAGE_HTTPDIR} + COMMAND rm -f ${PACKAGE_HTTPDIR}/CMakeLists.txt ) add_custom_target(${POPULE_PACKAGE_TARGET} DEPENDS ${PACKAGE_HTTPDIR}-xx) add_dependencies(populate ${POPULE_PACKAGE_TARGET}) @@ -96,7 +98,8 @@ macro(project_targets_populate) DEPENDS ${TARGET} COMMAND mkdir -p ${PACKAGE_DATADIR} COMMAND touch ${PACKAGE_DATADIR} - COMMAND cp -r ${BD}/${P}${OUT} ${PACKAGE_DATADIR} + COMMAND cp -r ${SD}/* ${PACKAGE_DATADIR} + COMMAND rm -f ${PACKAGE_DATADIR}/CMakeLists.txt ) add_custom_target(${POPULE_PACKAGE_TARGET} DEPENDS ${PACKAGE_DATADIR}-xx) add_dependencies(populate ${POPULE_PACKAGE_TARGET}) -- cgit 1.2.3-korg