diff options
| author | Shauren <none@none> | 2010-06-24 12:37:08 +0200 | 
|---|---|---|
| committer | Shauren <none@none> | 2010-06-24 12:37:08 +0200 | 
| commit | a5a2676e887cf1661d10dff4835a94164cb6a414 (patch) | |
| tree | 1809aa312d5c1c280855c1ef2314ed330b801fb3 /cmake/FindOpenSSL.cmake | |
| parent | 1522506feb4918962f9422a94f39f5eeba0b1b52 (diff) | |
Fixed OpenSSL cmake detection for x64 windows
--HG--
branch : trunk
Diffstat (limited to 'cmake/FindOpenSSL.cmake')
| -rw-r--r-- | cmake/FindOpenSSL.cmake | 31 | 
1 files changed, 18 insertions, 13 deletions
diff --git a/cmake/FindOpenSSL.cmake b/cmake/FindOpenSSL.cmake index 287527c854e..d48a3d19bae 100644 --- a/cmake/FindOpenSSL.cmake +++ b/cmake/FindOpenSSL.cmake @@ -24,18 +24,16 @@ else( OPENSSL_INCLUDE_DIR AND OPENSSL_LIBRARIES )        /usr/local/include        /usr/local/include/openssl        /usr/local/openssl/include -      "C:/OpenSSL/include/openssl" -      "C:/OpenSSL-Win32/include/openssl" -      "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/include/openssl" -      "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/include/openssl" +      if (CMAKE_CL_64) +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (64-bit)_is1;InstallLocation]/include/openssl" +      else +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/include/openssl" +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/include/openssl" +      endif      DOC        "Specify the directory containing openssl.h."    ) -  if( WIN32 ) -    set(TMP_OPENSSL_LIBRARIES "libeay32 ssleay32") -  endif( WIN32 ) -    find_library(OPENSSL_LIBRARIES      NAMES        ssleay32 @@ -46,9 +44,12 @@ else( OPENSSL_INCLUDE_DIR AND OPENSSL_LIBRARIES )        /usr/local/lib        /usr/local/lib/ssl        /usr/local/ssl/lib -      "C:/OpenSSL/lib" -      "C:/OpenSSL-Win32/lib" -      "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/lib" +      if (CMAKE_CL_64) +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (64-bit)_is1;InstallLocation]/lib" +      else +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/lib" +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/lib" +      endif      DOC "Specify the OpenSSL library here."    ) @@ -57,8 +58,12 @@ else( OPENSSL_INCLUDE_DIR AND OPENSSL_LIBRARIES )      NAMES        libeay32      PATHS -      "C:/OpenSSL/lib" -       "C:/OpenSSL-Win32/lib" +      if (CMAKE_CL_64) +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (64-bit)_is1;InstallLocation]/lib" +      else +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/lib" +        "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\OpenSSL (32-bit)_is1;InstallLocation]/lib" +      endif      DOC        "if more libraries are necessary to link in a OpenSSL client, specify them here."    )  | 
