From 7846a232a95d62a38a2740c35764bafe575b3241 Mon Sep 17 00:00:00 2001 From: Fabian Boehm Date: Tue, 12 Nov 2024 21:23:28 +0100 Subject: [PATCH] cmake: Add some new version gunk CMake Warning (dev) at cmake/Tests.cmake:56 (add_custom_command): Exactly one of PRE_BUILD, PRE_LINK, or POST_BUILD must be given. Assuming POST_BUILD to preserve backward compatibility. Policy CMP0175 is not set: add_custom_command() rejects invalid arguments. Run "cmake --help-policy CMP0175" for policy details. Use the cmake_policy command to set the policy and suppress this warning. So we just keep it the same. --- cmake/Tests.cmake | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cmake/Tests.cmake b/cmake/Tests.cmake index 6b577af1c..5d2099aa3 100644 --- a/cmake/Tests.cmake +++ b/cmake/Tests.cmake @@ -54,6 +54,7 @@ set(TEST_ROOT_DIR ${TEST_DIR}/root) if(NOT FISH_IN_TREE_BUILD) add_custom_target(funcs_dir) add_custom_command(TARGET funcs_dir + POST_BUILD COMMAND mkdir -p ${CMAKE_BINARY_DIR}/share # Don't run ln twice or it will create a new link in the link. COMMAND test -e ${CMAKE_BINARY_DIR}/share/functions || ln -sf @@ -63,6 +64,7 @@ if(NOT FISH_IN_TREE_BUILD) add_custom_target(tests_dir DEPENDS tests) add_custom_command(TARGET tests_dir + POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/tests/ ${CMAKE_BINARY_DIR}/tests/ COMMENT "Copying test files to binary dir"