How to add OpenSSL to the project link?

I have seen FingOpenSSL (cmake), but it’s not clear what to do about it. Please give an example of how to add OpenSSL to the project link.

    1 answer 1

    Did you read the documentation ? All are elementary:

    find_package(OpenSSL) add_executable(yourapp ...) target_link_libraries(yourapp ${OPENSSL_LIBRARIES}) 
    • Set the variable OPENSSL_ROOT_DIR ? It should point to the directory that contains the lib and include list. - arrowd
    • Can I set an example? - continue98
    • Either `cmake -DOPENSSL_ROOT_DIR = c: \ openssl`, or in cmake-gui through the windows and buttons. - arrowd
    • It is worth it, but you cannot connect it (I write #include and there is no choice of libraries from openssl) )} \ GnuWin32 \ include \ openssl - continue98