diff options
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r-- | src/CMakeLists.txt | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 5c2c5271d..819fc4246 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -115,6 +115,7 @@ include(SelectHTTPSBackend) include(SelectHashes) include(SelectHTTPParser) include(SelectRegex) +include(SelectSSH) target_sources(git2internal PRIVATE ${SRC_SHA1}) @@ -151,32 +152,6 @@ elseif(USE_BUNDLED_ZLIB OR NOT ZLIB_FOUND) add_feature_info(zlib ON "using bundled zlib") endif() -# Optional external dependency: libssh2 -if(USE_SSH) - find_pkglibraries(LIBSSH2 libssh2) - if(NOT LIBSSH2_FOUND) - find_package(LibSSH2) - set(LIBSSH2_INCLUDE_DIRS ${LIBSSH2_INCLUDE_DIR}) - get_filename_component(LIBSSH2_LIBRARY_DIRS "${LIBSSH2_LIBRARY}" DIRECTORY) - set(LIBSSH2_LIBRARIES ${LIBSSH2_LIBRARY}) - set(LIBSSH2_LDFLAGS "-lssh2") - endif() -endif() -if(LIBSSH2_FOUND) - set(GIT_SSH 1) - list(APPEND LIBGIT2_SYSTEM_INCLUDES ${LIBSSH2_INCLUDE_DIRS}) - list(APPEND LIBGIT2_LIBS ${LIBSSH2_LIBRARIES}) - list(APPEND LIBGIT2_PC_LIBS ${LIBSSH2_LDFLAGS}) - - check_library_exists("${LIBSSH2_LIBRARIES}" libssh2_userauth_publickey_frommemory "${LIBSSH2_LIBRARY_DIRS}" HAVE_LIBSSH2_MEMORY_CREDENTIALS) - if(HAVE_LIBSSH2_MEMORY_CREDENTIALS) - set(GIT_SSH_MEMORY_CREDENTIALS 1) - endif() -else() - message(STATUS "LIBSSH2 not found. Set CMAKE_PREFIX_PATH if it is installed outside of the default search path.") -endif() -add_feature_info(SSH GIT_SSH "SSH transport support") - # Optional external dependency: ntlmclient if(USE_NTLMCLIENT) set(GIT_NTLM 1) |