mirror of
https://github.com/git-for-windows/git.git
synced 2026-03-29 23:17:17 -05:00
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>
This commit is contained in:
committed by
Johannes Schindelin
parent
6ea06d278b
commit
3cdde1fcb0
@@ -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/")
|
||||
|
||||
Reference in New Issue
Block a user