‘SSL_R_SHORT_READ’ was not declared
OpeSSL1.1.0 backwards compatibility issue.
websocketpp0.7.0/transport/asio/security/tls.hpp: In member function ‘std::error_code websocketpp::transport::asio::tls_socket::connection::translate_ec(ErrorCodeType)’:
websocketpp0.7.0/transport/asio/security/tls.hpp:358:47: error: ‘SSL_R_SHORT_READ’ was not declared in this scope
if (ERR_GET_REASON(ec.value()) == SSL_R_SHORT_READ) {
^~~~~~~~~~~~~~~~
websocketpp0.7.0/transport/asio/security/tls.hpp:358:47: note: suggested alternative: ‘SSL_F_SSL_READ’
if (ERR_GET_REASON(ec.value()) == SSL_R_SHORT_READ) {
^~~~~~~~~~~~~~~~
SSL_F_SSL_READ
The error also appears with the latest (1-12-0) release of ASIO from https://github.com/chriskohlhoff/asio/releases
i encountered the same problem on centos 7 when building websocketpp 0.8.2 . but i just installed openssl 1.1.0l version which was not the default version on that OS. I removed this openssl and installed the default version (using yum install openssl,1.0.2k), and everything went well then.
Apparently, it seems that websocketpp 0.8.2 is not compatible with newer version of openssl( later than 1.0.2k). Using the proper version of openssl for building websocketpp is quite crucial.