If you have a custom installation of cURL to support of HTTP/2 and the recent version 7.62.0 fails to built with the error:
vtls/openssl.c: In function 'Curl_ossl_seed': vtls/openssl.c:454:5: error: implicit declaration of function 'RAND_egd' [-Werror=implicit-function-declaration] int ret = RAND_egd(data->set.str[STRING_SSL_EGDSOCKET]? ^ cc1: some warnings being treated as errors Makefile:2425: recipe for target 'vtls/libcurl_la-openssl.lo' failed make: *** [vtls/libcurl_la-openssl.lo] Error 1 make: Leaving directory '/usr/local/directadmin/custombuild/curl-7.62.0/lib' Makefile:1028: recipe for target 'all' failed make: *** [all] Error 2 make: Leaving directory '/usr/local/directadmin/custombuild/curl-7.62.0/lib' Makefile:929: recipe for target 'all-recursive' failed make: *** [all-recursive] Error 1 *** The make has failed, would you like to try to make again? (y,n):
we’ve got a solution for you.
Who is affected?
It was found that cURL 7.62.0 fails to build against OpenSSL 1.0.1 on Directadmin servers with Debian 8 (jessie) which are having a basic version of OpenSSL 1.0.1t installed from debian packages:
Debian 8 (jessie):
Let’s get it fixed!
This is how you can fix it: you should upgrade the basic version the package to the latest available OpenSSL 1.1.1a.
Here are instructions on how to update it to the latest OpenSSL 1.1.1a:
cd /usr/local/directadmin/scripts/ wget https://raw.githubusercontent.com/StaffNowa/directadmin-utils/master/openssl/openssl.install-1.1.1-primary.sh chmod +x openssl.install-1.1.1-primary.sh ./openssl.install-1.1.1-primary.sh
As we install the newer version over the existing one we need to lock the packages openssl-* with the following commands:
apt-mark hold openssl-*
to keep the newest OpenSSL version away from package updates.
cd /usr/local/directadmin/custombuild/ ./build clean ./build update ./build curl
Check it to see:
curl -V curl 7.62.0 (x86_64-pc-linux-gnu) libcurl/7.62.0 OpenSSL/1.1.1a zlib/1.2.8 nghttp2/1.35.0 Release-Date: 2018-10-31 Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp smb smbs smtp smtps telnet tftp Features: AsynchDNS IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP HTTP2 UnixSockets HTTPS-proxy