Skip to content

Commit b4b1de8

Browse files
dschoGit for Windows Build Agent
authored andcommitted
cmake: install headless-git. (#4338)
Even if CMake is not the canonical way to build Git for Windows, but CMake support merely exists in Git to support building Git for Windows using Visual Studio, we should include `headless-git` in such a scenario when installing the binaries to a given location.
2 parents d7268c8 + 95d0c7d commit b4b1de8

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

contrib/buildsystems/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -749,6 +749,7 @@ if(WIN32)
749749
endif()
750750

751751
add_executable(headless-git ${CMAKE_SOURCE_DIR}/compat/win32/headless.c)
752+
list(APPEND PROGRAMS_BUILT headless-git)
752753
if(CMAKE_C_COMPILER_ID STREQUAL "GNU" OR CMAKE_C_COMPILER_ID STREQUAL "Clang")
753754
target_link_options(headless-git PUBLIC -municode -Wl,-subsystem,windows)
754755
elseif(CMAKE_C_COMPILER_ID STREQUAL "MSVC")
@@ -928,7 +929,7 @@ list(TRANSFORM git_perl_scripts PREPEND "${CMAKE_BINARY_DIR}/")
928929

929930
#install
930931
foreach(program ${PROGRAMS_BUILT})
931-
if(program MATCHES "^(git|git-shell|scalar)$")
932+
if(program MATCHES "^(git|git-shell|headless-git|scalar)$")
932933
install(TARGETS ${program}
933934
RUNTIME DESTINATION bin)
934935
else()

0 commit comments

Comments
 (0)