changeset 3423:f5fe6d08f910

improving single file uncompression on Windows
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 13 Jun 2019 16:37:20 +0200
parents 8b4169a88039
children 07c3b6044e9d
files Resources/CMake/DownloadPackage.cmake
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/Resources/CMake/DownloadPackage.cmake	Thu Jun 13 14:49:12 2019 +0200
+++ b/Resources/CMake/DownloadPackage.cmake	Thu Jun 13 16:37:20 2019 +0200
@@ -222,7 +222,9 @@
 
       if ("${TMP_EXTENSION}" STREQUAL "gz")
         execute_process(
-          COMMAND ${ZIP_EXECUTABLE} e -y ${TMP_PATH}
+          # "-so" writes uncompressed file to stdout
+          COMMAND ${ZIP_EXECUTABLE} e -so -y ${TMP_PATH}
+          OUTPUT_FILE "${TargetFile}"
           WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
           RESULT_VARIABLE Failure
           OUTPUT_QUIET