I am compiling on Linux, trying to make a 1.12 private server on Manjaro Linux. I'm having some issues with Cmake.
To run Cmake succesfully, I used the following command, since Cmake found openssl 1.1:
cmake .. -DPREFIX=/home/wow/bin -DOPENSSL_LIBRARIES=/usr/lib/libssl.so.1.0.0 -DOPENSSL_INCLUDE_DIR=/usr/include/openssl-1.0/
Configuration worked. After running 'make' I got into trouble. Here's the output of my Terminal:
make
(....)
[ 20%] Linking CXX executable bnetserver
CMakeFiles/bnetserver.dir/Main.cpp.o: In function `main::{lambda()#3}::operator()() const':
Main.cpp:(.text+0x53d): undefined reference to `SSLeay_version'
CMakeFiles/bnetserver.dir/Main.cpp.o: In function `boost::asio::ssl::detail::openssl_init_base::do_init::do_init()':
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initC2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initC5Ev]+0x1c): undefined reference to `SSL_library_init'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initC2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initC5Ev]+0x21): undefined reference to `SSL_load_error_strings'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initC2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initC5Ev]+0x26): undefined reference to `OPENSSL_add_all_algorithms_noconf'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initC2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initC5Ev]+0x2f): undefined reference to `CRYPTO_num_locks'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initC2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initC5Ev]+0xa2): undefined reference to `CRYPTO_set_locking_callback'
CMakeFiles/bnetserver.dir/Main.cpp.o: In function `boost::asio::ssl::detail::openssl_init_base::do_init::~do_init()':
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initD2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initD5Ev]+0x12): undefined reference to `CRYPTO_set_locking_callback'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initD2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initD5Ev]+0x17): undefined reference to `ERR_free_strings'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initD2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initD5Ev]+0x1c): undefined reference to `EVP_cleanup'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initD2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initD5Ev]+0x21): undefined reference to `CRYPTO_cleanup_all_ex_data'
Main.cpp:(.text._ZN5boost4asio3ssl6detail17openssl_init_base7do_initD2Ev[_ZN5boost4asio3ssl6detail17openssl_init_base7do_initD5Ev]+0x3a): undefined reference to `ENGINE_cleanup'
CMakeFiles/bnetserver.dir/Server/SslContext.cpp.o: In function `boost::asio::ssl::context::context(boost::asio::ssl::context_base::method)':
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x1a9): undefined reference to `SSLv23_method'
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x1c5): undefined reference to `SSLv23_client_method'
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x1e1): undefined reference to `SSLv23_server_method'
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x1fd): undefined reference to `SSLv23_method'
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x247): undefined reference to `SSLv23_client_method'
SslContext.cpp:(.text._ZN5boost4asio3ssl7contextC2ENS1_12context_base6methodE[_ZN5boost4asio3ssl7contextC5ENS1_12context_base6methodE]+0x28a): undefined reference to `SSLv23_server_method'
../../../dep/gsoap/libgsoap.a(stdsoap2.cpp.o): In function `soap_ssl_init':
stdsoap2.cpp:(.text+0x6752): undefined reference to `SSL_library_init'
stdsoap2.cpp:(.text+0x6757): undefined reference to `OPENSSL_add_all_algorithms_noconf'
stdsoap2.cpp:(.text+0x675c): undefined reference to `SSL_load_error_strings'
../../../dep/gsoap/libgsoap.a(stdsoap2.cpp.o): In function `ssl_auth_init':
stdsoap2.cpp:(.text+0x69d7): undefined reference to `SSLv23_method'
../../../dep/gsoap/libgsoap.a(stdsoap2.cpp.o): In function `tcp_connect':
stdsoap2.cpp:(.text+0x8ffd): undefined reference to `SSL_state'
stdsoap2.cpp:(.text+0x91d0): undefined reference to `sk_pop_free'
stdsoap2.cpp:(.text+0x91f9): undefined reference to `sk_num'
stdsoap2.cpp:(.text+0x9225): undefined reference to `sk_value'
stdsoap2.cpp:(.text+0x92c1): undefined reference to `sk_pop_free'
collect2: fout: ld gaf exit-status 1 terug
make[2]: *** [src/server/bnetserver/CMakeFiles/bnetserver.dir/build.make:348: src/server/bnetserver/bnetserver] Fout 1
make[1]: *** [CMakeFiles/Makefile2:1256: src/server/bnetserver/CMakeFiles/bnetserver.dir/all] Fout 2
make: *** [Makefile:130: all] Fout 2
I presume I'm having trouble because of OpenSSL and Boost, but I'm not entirely sure. At least I dont know how to solve this problem. Could anyone help me with this problem?
Many thanks in advance!