From 2779b733c221361aa33290f2dce1dd2cc5a0cbf1 Mon Sep 17 00:00:00 2001 From: Alexander Neumann <30894796+Neumann-A@users.noreply.github.com> Date: Wed, 31 Mar 2021 21:47:35 +0200 Subject: [vcpkg/scripts] add a way to define another tool destination (#16935) --- docs/maintainers/vcpkg_copy_tools.md | 4 ++++ docs/maintainers/vcpkg_fixup_cmake_targets.md | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) (limited to 'docs') diff --git a/docs/maintainers/vcpkg_copy_tools.md b/docs/maintainers/vcpkg_copy_tools.md index 34a4bb84a..98e86e05b 100644 --- a/docs/maintainers/vcpkg_copy_tools.md +++ b/docs/maintainers/vcpkg_copy_tools.md @@ -9,6 +9,7 @@ Copy tools and all their DLL dependencies into the `tools` folder. vcpkg_copy_tools( TOOL_NAMES ... [SEARCH_DIR <${CURRENT_PACKAGES_DIR}/bin>] + [DESTINATION <${CURRENT_PACKAGES_DIR}/tools/${PORT}>] [AUTO_CLEAN] ) ``` @@ -19,6 +20,9 @@ A list of tool filenames without extension. ### SEARCH_DIR The path to the directory containing the tools. This will be set to `${CURRENT_PACKAGES_DIR}/bin` if ommited. +### DESTINATION +Destination to copy the tools to. This will be set to `${CURRENT_PACKAGES_DIR}/tools/${PORT}` if ommited. + ### AUTO_CLEAN Auto clean executables in `${CURRENT_PACKAGES_DIR}/bin` and `${CURRENT_PACKAGES_DIR}/debug/bin`. diff --git a/docs/maintainers/vcpkg_fixup_cmake_targets.md b/docs/maintainers/vcpkg_fixup_cmake_targets.md index dbb6fb432..704ac4ad1 100644 --- a/docs/maintainers/vcpkg_fixup_cmake_targets.md +++ b/docs/maintainers/vcpkg_fixup_cmake_targets.md @@ -10,7 +10,10 @@ Additionally corrects common issues with targets, such as absolute paths and inc ## Usage ```cmake -vcpkg_fixup_cmake_targets([CONFIG_PATH ] [TARGET_PATH ] [DO_NOT_DELETE_PARENT_CONFIG_PATH]) +vcpkg_fixup_cmake_targets([CONFIG_PATH ] + [TARGET_PATH ] + [TOOLS_PATH ] + [DO_NOT_DELETE_PARENT_CONFIG_PATH]) ``` ## Parameters @@ -36,12 +39,15 @@ Disables the correction of_IMPORT_PREFIX done by vcpkg due to moving the targets Currently the correction does not take into account how the files are moved and applies I rather simply correction which in some cases will yield the wrong results. +### TOOLS_PATH +Define the base path to tools. Default: `tools/` + ## Notes Transform all `/debug//*targets-debug.cmake` files and move them to `/`. Removes all `/debug//*targets.cmake` and `/debug//*config.cmake`. -Transform all references matching `/bin/*.exe` to `/tools//*.exe` on Windows. -Transform all references matching `/bin/*` to `/tools//*` on other platforms. +Transform all references matching `/bin/*.exe` to `/${TOOLS_PATH}/*.exe` on Windows. +Transform all references matching `/bin/*` to `/${TOOLS_PATH}/*` on other platforms. Fix `${_IMPORT_PREFIX}` in auto generated targets to be one folder deeper. Replace `${CURRENT_INSTALLED_DIR}` with `${_IMPORT_PREFIX}` in configs and targets. -- cgit v1.2.3