Browse Source

Merge pull request #8681 from Michael-Gardner/HPCC-15567

HPCC-15567 Remove libmemcached download artifact on failed download

Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
Richard Chapman 9 years ago
parent
commit
aaf8b96451
1 changed files with 3 additions and 0 deletions
  1. 3 0
      cmake_modules/FindLIBMEMCACHED.cmake

+ 3 - 0
cmake_modules/FindLIBMEMCACHED.cmake

@@ -88,6 +88,9 @@ IF (NOT LIBMEMCACHED_FOUND)
             list(GET libmemcached_status 0 status_code)
             list(GET libmemcached_status 0 status_code)
             list(GET libmemcached_status 1 status_msg)
             list(GET libmemcached_status 1 status_msg)
             if(NOT status_code EQUAL 0)
             if(NOT status_code EQUAL 0)
+                if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/libmemcached-${LIBMEMCACHED_VERSION}.tar.gz")
+                    file(REMOVE ${CMAKE_CURRENT_SOURCE_DIR}/libmemcached-${LIBMEMCACHED_VERSION}.tar.gz)
+                endif()
                 message(FATAL_ERROR "Fatal Error: download of ${LIBMEMCACHED_URL} failed
                 message(FATAL_ERROR "Fatal Error: download of ${LIBMEMCACHED_URL} failed
                 status_code: ${status_code}
                 status_code: ${status_code}
                 status_msg: ${status_msg}
                 status_msg: ${status_msg}