summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosé Simões <jose.simoes@eclo.pt>2016-12-15 14:31:08 (GMT)
committerBrad King <brad.king@kitware.com>2016-12-15 14:57:30 (GMT)
commitcaeb6d1dfb7ec9ab471d24e71244d7899f044c27 (patch)
tree824ce7f8ac6325410f960c57a7dbd07d452ec578
parent94c6040b730e5b77e72c39dda10a0df3228ce279 (diff)
downloadCMake-caeb6d1dfb7ec9ab471d24e71244d7899f044c27.zip
CMake-caeb6d1dfb7ec9ab471d24e71244d7899f044c27.tar.gz
CMake-caeb6d1dfb7ec9ab471d24e71244d7899f044c27.tar.bz2
FindGit: Fix check for Windows host
When cross-compiling to or from a Windows platform we should still find a Git for the host environment.
-rw-r--r--Modules/FindGit.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/FindGit.cmake b/Modules/FindGit.cmake
index 769c6c3..b830c08 100644
--- a/Modules/FindGit.cmake
+++ b/Modules/FindGit.cmake
@@ -30,7 +30,7 @@ set(git_names git eg)
# Prefer .cmd variants on Windows unless running in a Makefile
# in the MSYS shell.
#
-if(WIN32)
+if(CMAKE_HOST_WIN32)
if(NOT CMAKE_GENERATOR MATCHES "MSYS")
set(git_names git.cmd git eg.cmd eg)
# GitHub search path for Windows