aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt18
1 files changed, 12 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2f0dfa0..ca7f565 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -414,6 +414,18 @@ else()
414 set(LIBTLS_TEST_LIBS tls ${PLATFORM_LIBS}) 414 set(LIBTLS_TEST_LIBS tls ${PLATFORM_LIBS})
415endif() 415endif()
416 416
417if(OPENSSLDIR STREQUAL "")
418 if(WIN32)
419 set(OPENSSLDIR "C:/Windows/libressl/ssl")
420 else()
421 set(OPENSSLDIR "${CMAKE_INSTALL_PREFIX}/etc/ssl")
422 endif()
423
424 set(CONF_DIR "${CMAKE_INSTALL_PREFIX}/etc/ssl")
425else()
426 set(CONF_DIR "${OPENSSLDIR}")
427endif()
428
417add_subdirectory(include) 429add_subdirectory(include)
418add_subdirectory(crypto) 430add_subdirectory(crypto)
419add_subdirectory(ssl) 431add_subdirectory(ssl)
@@ -495,12 +507,6 @@ if(ENABLE_LIBRESSL_INSTALL)
495 endif() 507 endif()
496endif(ENABLE_LIBRESSL_INSTALL) 508endif(ENABLE_LIBRESSL_INSTALL)
497 509
498if(NOT "${OPENSSLDIR}" STREQUAL "")
499 set(CONF_DIR "${OPENSSLDIR}")
500else()
501 set(CONF_DIR "${CMAKE_INSTALL_PREFIX}/etc/ssl")
502endif()
503
504if(ENABLE_LIBRESSL_INSTALL) 510if(ENABLE_LIBRESSL_INSTALL)
505 install(FILES cert.pem openssl.cnf x509v3.cnf DESTINATION ${CONF_DIR}) 511 install(FILES cert.pem openssl.cnf x509v3.cnf DESTINATION ${CONF_DIR})
506 install(DIRECTORY DESTINATION ${CONF_DIR}/certs) 512 install(DIRECTORY DESTINATION ${CONF_DIR}/certs)