summaryrefslogtreecommitdiff
path: root/Modules/ExternalData.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-04-22 13:06:11 -0400
committerBrad King <brad.king@kitware.com>2021-04-22 13:06:11 -0400
commit298760661f30faf2014f609506f15ff2d3489ddf (patch)
treefc41299077dc63ad19a964e6fc1de21ba37aff8b /Modules/ExternalData.cmake
parent3a7ee5358b590a6c5044b9d9762675b55219a400 (diff)
downloadcmake-298760661f30faf2014f609506f15ff2d3489ddf.tar.gz
ExternalData: Improve error message when we fail to create a file
Report the underlying system error.
Diffstat (limited to 'Modules/ExternalData.cmake')
-rw-r--r--Modules/ExternalData.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/ExternalData.cmake b/Modules/ExternalData.cmake
index 1850e74625..189374be42 100644
--- a/Modules/ExternalData.cmake
+++ b/Modules/ExternalData.cmake
@@ -949,7 +949,7 @@ function(_ExternalData_link_or_copy src dst)
endif()
if(result)
file(REMOVE "${tmp}")
- message(FATAL_ERROR "Failed to create\n ${tmp}\nfrom\n ${obj}")
+ message(FATAL_ERROR "Failed to create:\n \"${tmp}\"\nfrom:\n \"${obj}\"\nwith error:\n ${result}")
endif()
# Atomically create/replace the real destination.