Skip to content

Commit 05ba660

Browse files
committed
Add CMake 4.2 result variable for OpenSSL
1 parent d9f9d35 commit 05ba660

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#[=============================================================================[
2+
# FindOpenSSL
3+
4+
This module overrides the upstream CMake `FindOpenSSL` module with few
5+
customizations:
6+
7+
* Added OpenSSL_VERSION result variable for CMake < 4.2.
8+
9+
See: https://cmake.org/cmake/help/latest/module/FindOpenSSL.html
10+
#]=============================================================================]
11+
12+
# Find package with upstream CMake find module. Absolute path prevents the
13+
# maximum nesting/recursion depth error on some systems, like macOS.
14+
include(${CMAKE_ROOT}/Modules/FindOpenSSL.cmake)
15+
16+
if(CMAKE_VERSION VERSION_LESS 4.2)
17+
set(OpenSSL_VERSION "${OPENSSL_VERSION}")
18+
endif()

0 commit comments

Comments
 (0)