File: SelectWinHTTP.cmake

package info (click to toggle)
libgit2 1.5.1%2Bds-1%2Bdeb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 56,804 kB
  • sloc: ansic: 187,873; sh: 1,186; python: 384; php: 65; makefile: 33
file content (17 lines) | stat: -rw-r--r-- 664 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
if(WIN32 AND USE_WINHTTP)
	set(GIT_WINHTTP 1)

	# Since MinGW does not come with headers or an import library for winhttp,
	# we have to include a private header and generate our own import library
	if(MINGW)
		add_subdirectory("${PROJECT_SOURCE_DIR}/deps/winhttp" "${PROJECT_BINARY_DIR}/deps/winhttp")
		list(APPEND LIBGIT2_SYSTEM_LIBS winhttp)
		list(APPEND LIBGIT2_DEPENDENCY_INCLUDES "${PROJECT_SOURCE_DIR}/deps/winhttp")
	else()
		list(APPEND LIBGIT2_SYSTEM_LIBS "winhttp")
		list(APPEND LIBGIT2_PC_LIBS "-lwinhttp")
	endif()

	list(APPEND LIBGIT2_SYSTEM_LIBS "rpcrt4" "crypt32" "ole32")
	list(APPEND LIBGIT2_PC_LIBS "-lrpcrt4" "-lcrypt32" "-lole32")
endif()