diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2016-10-18 16:17:47 -0700 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2016-10-18 16:17:47 -0700 |
| commit | 4488064f81d58c34d329bb2ebdd589c3349cdd91 (patch) | |
| tree | 5d3212dfbe92c7cadfa14fe0f0f185174b8d14f3 /scripts/cmake | |
| parent | 8fd12fed6cbe6ea563eb709b34a86967d562c78e (diff) | |
| download | vcpkg-4488064f81d58c34d329bb2ebdd589c3349cdd91.tar.gz vcpkg-4488064f81d58c34d329bb2ebdd589c3349cdd91.zip | |
[vcpkg_apply_patches] Check if patch was properly applied
Diffstat (limited to 'scripts/cmake')
| -rw-r--r-- | scripts/cmake/vcpkg_apply_patches.cmake | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/cmake/vcpkg_apply_patches.cmake b/scripts/cmake/vcpkg_apply_patches.cmake index 939edbd14..42f7a84f9 100644 --- a/scripts/cmake/vcpkg_apply_patches.cmake +++ b/scripts/cmake/vcpkg_apply_patches.cmake @@ -13,6 +13,15 @@ function(vcpkg_apply_patches) WORKING_DIRECTORY ${_ap_SOURCE_PATH} RESULT_VARIABLE error_code ) + + if(error_code) + message(FATAL_ERROR + "Applying patch failed: ${GIT} --work-tree=. apply \"${PATCH}\" --ignore-whitespace --whitespace=nowarn --verbose\n" + "See logs for more information:\n" + " ${CURRENT_BUILDTREES_DIR}/${LOGNAME}-out.log\n" + " ${CURRENT_BUILDTREES_DIR}/${LOGNAME}-err.log\n") + endif() + message(STATUS "Applying patch ${PATCH} done") math(EXPR PATCHNUM "${PATCHNUM}+1") endforeach() |
