summaryrefslogtreecommitdiff
path: root/contrib/buildsystems/CMakeLists.txt
diff options
context:
space:
mode:
authorCarlo Marcelo Arenas Belón <carenas@gmail.com>2022-07-27 09:05:56 (GMT)
committerJunio C Hamano <gitster@pobox.com>2022-07-27 15:57:33 (GMT)
commit476e54b1c604c7e0bb5265e8995e53aad1a13877 (patch)
tree1fbcac63914facc34be55411f491a5432b958b94 /contrib/buildsystems/CMakeLists.txt
parentbbea4dcf42b28eb7ce64a6306cdde875ae5d09ca (diff)
downloadgit-476e54b1c604c7e0bb5265e8995e53aad1a13877.zip
git-476e54b1c604c7e0bb5265e8995e53aad1a13877.tar.gz
git-476e54b1c604c7e0bb5265e8995e53aad1a13877.tar.bz2
cmake: support local installations of git
At least in systems where the user is local and not an administrator git will install in a subdirectory of %APPDATALOCAL%, so it makes sense to also look there for the shell needed by the cmake integration with Visual Studio. Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib/buildsystems/CMakeLists.txt')
-rw-r--r--contrib/buildsystems/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/buildsystems/CMakeLists.txt b/contrib/buildsystems/CMakeLists.txt
index 1b23f24..2237109 100644
--- a/contrib/buildsystems/CMakeLists.txt
+++ b/contrib/buildsystems/CMakeLists.txt
@@ -77,7 +77,7 @@ if(USE_VCPKG)
set(CMAKE_TOOLCHAIN_FILE ${VCPKG_DIR}/scripts/buildsystems/vcpkg.cmake CACHE STRING "Vcpkg toolchain file")
endif()
-find_program(SH_EXE sh PATHS "C:/Program Files/Git/bin")
+find_program(SH_EXE sh PATHS "C:/Program Files/Git/bin" "$ENV{LOCALAPPDATA}/Programs/Git/bin")
if(NOT SH_EXE)
message(FATAL_ERROR "sh: shell interpreter was not found in your path, please install one."
"On Windows, you can get it as part of 'Git for Windows' install at https://gitforwindows.org/")