From 8062e18a9a9d0bd9767ed8dcf9f0c6e6d4d06499 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9F=D0=B5=D0=BB=D0=B8=D0=BF=D0=B5=D0=BD=D0=BA=D0=BE=20?= =?UTF-8?q?=D0=98=D0=B2=D0=B0=D0=BD?= Date: Thu, 26 Mar 2020 07:11:31 +0000 Subject: [PATCH] git-svn-id: svn://db.shs.com.ru/pip@988 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5 --- cmake/DeployMacros.cmake | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/cmake/DeployMacros.cmake b/cmake/DeployMacros.cmake index 47290ac6..997e09ea 100644 --- a/cmake/DeployMacros.cmake +++ b/cmake/DeployMacros.cmake @@ -70,6 +70,7 @@ # PLUGINS | root | /usr/lib/COMPANY | Contents/PlugIns # FILES | root | /usr/bin | Contents/MacOS # +# Relative paths are taken from DEPLOY_DIR # Also check library dependencies from PLUGINS and FILES # # @@ -294,12 +295,12 @@ END endmacro() -macro(__add_file_or_dir _DIR_VAR _FILE_VAR _PATH) +macro(__add_file_or_dir _DIR_VAR _FILE_VAR _PATH _RELPATH) set(_p) if (IS_ABSOLUTE "${_PATH}") set(_p "${_PATH}") else() - set(_p "${CMAKE_CURRENT_SOURCE_DIR}/${_PATH}") + set(_p "${_RELPATH}/${_PATH}") endif() if (EXISTS "${_p}") if (IS_DIRECTORY "${_p}") @@ -356,11 +357,11 @@ macro(deploy_target _T) set(_is_deploy_dir 0) set(_DEPLOY_DIR "${_i}/") elseif (_is_res) - __add_file_or_dir(_RES_DIRS _RES_FILES "${_i}") + __add_file_or_dir(_RES_DIRS _RES_FILES "${_i}" "${_DEPLOY_DIR}") elseif (_is_plug) - __add_file_or_dir(_PLUG_DIRS _PLUG_FILES "${_i}") + __add_file_or_dir(_PLUG_DIRS _PLUG_FILES "${_i}" "${_DEPLOY_DIR}") elseif (_is_file) - __add_file_or_dir(_FILE_DIRS _FILE_FILES "${_i}") + __add_file_or_dir(_FILE_DIRS _FILE_FILES "${_i}" "${_DEPLOY_DIR}") endif() endif() #message("-i = ${_i}")