summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-05-06 14:39:05 (GMT)
committerBrad King <brad.king@kitware.com>2021-05-07 12:30:52 (GMT)
commitd7522b8f864db8df25b99eeabc625e55ad690a3e (patch)
tree6f9bc3bcbc373f103696c8c20565b45d7c6a45cf /Tests/RunCMake/CommandLine/RunCMakeTest.cmake
parente0b4a22ca6874a15912eea86cde16f47cb5f9d93 (diff)
downloadCMake-d7522b8f864db8df25b99eeabc625e55ad690a3e.zip
CMake-d7522b8f864db8df25b99eeabc625e55ad690a3e.tar.gz
CMake-d7522b8f864db8df25b99eeabc625e55ad690a3e.tar.bz2
cmSystemTools: Improve CreateLink and CreateSymlink error codes
In commit 7f89053953 (cmSystemTools: Return KWSys Status from CreateLink and CreateSymlink, 2021-04-15) we just took the `-err` from libuv and treated it as a POSIX error. This is accurate on POSIX, but on Windows does not match the POSIX error codes. Use `uv_fs_get_system_error` to get the actual system error code. This requires libuv 1.38 or higher. Require that for Windows, but fall back to the previous approach on POSIX.
Diffstat (limited to 'Tests/RunCMake/CommandLine/RunCMakeTest.cmake')
-rw-r--r--Tests/RunCMake/CommandLine/RunCMakeTest.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
index 78c3508..a1edbd0 100644
--- a/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
+++ b/Tests/RunCMake/CommandLine/RunCMakeTest.cmake
@@ -359,7 +359,7 @@ run_cmake_command(E_create_symlink-missing-dir
# These tests are special on Windows since it will only fail if the user
# running the test does not have the priveldge to create symlinks. If this
# happens we clear the msg in the -check.cmake and say that the test passes
-set(RunCMake_DEFAULT_stderr "(operation not permitted)?")
+set(RunCMake_DEFAULT_stderr "(A required privilege is not held by the client)?")
set(RunCMake_TEST_BINARY_DIR
${RunCMake_BINARY_DIR}/E_create_symlink-broken-build)
set(RunCMake_TEST_NO_CLEAN 1)
@@ -403,7 +403,7 @@ run_cmake_command(E_create_hardlink-no-directory
#On Windows, if the user does not have sufficient privileges
#don't fail this test
-set(RunCMake_DEFAULT_stderr "(operation not permitted)?")
+set(RunCMake_DEFAULT_stderr "(A required privilege is not held by the client)?")
run_cmake_command(E_create_hardlink-unresolved-symlink-prereq
${CMAKE_COMMAND} -E create_symlink ${dir}/1 ${dir}/1-symlink
)