summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-12-17 12:00:57 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-12-17 12:03:40 -0800
commit63290e31551329d27846b2fb06010b802cbb8264 (patch)
treef2178b4faaedda9dbfdc28896532b008b9ed053f /cmake
parent88d5fc0fbc6b1e48558cede0c404a1252a884368 (diff)
downloadsubsurface-63290e31551329d27846b2fb06010b802cbb8264.tar.gz
Cmake: fix variable name case confusion
I don't know why on one of my Macs (running El Capitan, XCode 7.2, cmake 3.4.1) I get Libssh2_FOUND instead of LIBSSH2_FOUND, but this hack works around the problem. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/Modules/HandleFindGit2.cmake4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmake/Modules/HandleFindGit2.cmake b/cmake/Modules/HandleFindGit2.cmake
index 2f88b36dd..875d0a5b6 100644
--- a/cmake/Modules/HandleFindGit2.cmake
+++ b/cmake/Modules/HandleFindGit2.cmake
@@ -19,6 +19,10 @@ else()
if ("${LIBSSH2_VERSION}" STRGREATER "1.6.1")
set(LIBSSH2_LIBRARIES Libssh2::libssh2)
endif()
+ # at least on my Mac I get the mixed case variable instead...
+ if(Libssh2_FOUND)
+ set(LIBSSH2_FOUND ${Libssh2_FOUND})
+ endif()
if(!LIBSSH2_FOUND OR "${LIBSSH2_FOUND}" STREQUAL "")
pkg_config_library(LIBSSH2 libssh2 REQUIRED)
endif()