Created attachment 525162 [details] emerge --info wpa_supplicant with the following options fails to compile: [ebuild R ] net-wireless/wpa_supplicant-2.6-r4::gentoo USE="hs2-0 libressl readline ssl -ap -dbus -eap-sim -eapol_test -fasteap -gnutls -p2p -privsep (-ps3) -qt5 (-selinux) -smartcard -tdls -uncommon-eap-types (-wimax) -wps" 0 KiB This is being compiled against dev-libs/libressl-2.7.0 which I strongly suspect may be the cause given the comments in the source code at this location. x86_64-pc-linux-gnu-gcc -c -o ../src/crypto/tls_openssl.o -O2 -pipe -march=native -mtune=native -I/var/tmp/portage/net-wireless/wpa_supplicant-2.6-r4/work/wpa_supplicant-2.6/src -I/var/tmp/portage/net-wireless/wpa_supplicant-2.6-r4/work/wpa_supplicant-2.6/src/utils -DCONFIG_BACKEND_FILE -DCONFIG_IEEE80211W -DCONFIG_IEEE80211R -DCONFIG_MESH -DCONFIG_SAE -DCONFIG_PEERKEY -DCONFIG_IBSS_RSN -DCONFIG_NO_VLAN -DCONFIG_MATCH_IFACE -DCONFIG_HS20 -DCONFIG_INTERWORKING -DCONFIG_DRIVER_WIRED -DCONFIG_DRIVER_NL80211 -DCONFIG_LIBNL20 -I/usr/include/libnl3 -DCONFIG_DRIVER_WEXT -DCONFIG_WIRELESS_EXTENSION -DCONFIG_DRIVER_HOSTAP -DEAP_TLS -DEAP_PEAP -DEAP_TTLS -DEAP_MD5 -DEAP_MSCHAPv2 -DEAP_GTC -DEAP_OTP -DEAP_LEAP -DEAP_PSK -DEAP_PAX -DEAP_PWD -DIEEE8021X_EAPOL -DCONFIG_AP -DCONFIG_NO_RADIUS -DCONFIG_NO_ACCOUNTING -DCONFIG_NO_VLAN -DEAP_SERVER -DEAP_SERVER_IDENTITY -DNEED_AP_MLME -DCONFIG_NO_RADIUS -DPKCS12_FUNCS -DCONFIG_SMARTCARD -DEAP_TLS_OPENSSL -DCONFIG_SHA256 -DCONFIG_ECC -DCONFIG_CTRL_IFACE -DCONFIG_CTRL_IFACE_UNIX -DCONFIG_SME -DCONFIG_DEBUG_SYSLOG -DCONFIG_DEBUG_FILE -DCONFIG_DELAYED_MIC_ERROR_REPORT -DCONFIG_BGSCAN_SIMPLE -DCONFIG_BGSCAN_LEARN -DCONFIG_BGSCAN -DCONFIG_GAS -DCONFIG_OFFCHANNEL ../src/crypto/tls_openssl.c ../src/crypto/tls_openssl.c:70:15: error: static declaration of ‘SSL_get_client_random’ follows non-static declaration static size_t SSL_get_client_random(const SSL *ssl, unsigned char *out, ^~~~~~~~~~~~~~~~~~~~~ In file included from ../src/crypto/tls_openssl.c:19:0: /usr/include/openssl/ssl.h:1558:8: note: previous declaration of ‘SSL_get_client_random’ was here size_t SSL_get_client_random(const SSL *s, unsigned char *out, size_t max_out); ^~~~~~~~~~~~~~~~~~~~~ ../src/crypto/tls_openssl.c:80:15: error: static declaration of ‘SSL_get_server_random’ follows non-static declaration static size_t SSL_get_server_random(const SSL *ssl, unsigned char *out, ^~~~~~~~~~~~~~~~~~~~~ In file included from ../src/crypto/tls_openssl.c:19:0: /usr/include/openssl/ssl.h:1559:8: note: previous declaration of ‘SSL_get_server_random’ was here size_t SSL_get_server_random(const SSL *s, unsigned char *out, size_t max_out); ^~~~~~~~~~~~~~~~~~~~~ make: *** [Makefile:1776: ../src/crypto/tls_openssl.o] Error 1 make: *** Waiting for unfinished jobs.... * ERROR: net-wireless/wpa_supplicant-2.6-r4::gentoo failed (compile phase): * emake failed
Created attachment 525208 [details, diff] Updated wpa_supplicant-2.6-libressl.patch It turns out that this problem was caused by libressl-2.7.0 afterall. This patch file (attached) updates/replaces the existing wpa_supplicant-2.6-libressl.patch file so that the build now completes when libressl-2.7.0 is installed on the system.
All bug reporters, can you please test against dev-libs/libressl-2.7.1
- Upgraded to libressl-2.7.1 - Tested by not applying the patch, attempting to recompile (fails) - Tested again applying the patch, (compile succeeds) => no change in behaviour or changes to the patch with 2.7.1.
(In reply to Reuben Farrelly from comment #3) > - Upgraded to libressl-2.7.1 > - Tested by not applying the patch, attempting to recompile (fails) > - Tested again applying the patch, (compile succeeds) > > => no change in behaviour or changes to the patch with 2.7.1. Okay I'm cc-ing zerochaos to see if we can add that patch contigent on USE=libressl.
I don't have anything against this patch, but has this been submitted to upstream at all yet? Could it be please?
Upstream appears to now have committed patches to fix this. See: https://w1.fi/cgit/hostap/commit/?id=ba3658cfff2278bc2ba24c32773962b37648d0b2 https://w1.fi/cgit/hostap/commit/?id=dee566d98e85e00b917d3eff42cd7e969de089cc https://w1.fi/cgit/hostap/commit/?id=4b603f01dec28d9ae022effb060a15e5a84b1f0c https://w1.fi/cgit/hostap/commit/?id=5ecdf06c8ceff8a817291b1f1ea5b681ca119f4d
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=128b2837afe310dd39d0895310116c5b40988db5 commit 128b2837afe310dd39d0895310116c5b40988db5 Author: Aaron Bauman <bman@gentoo.org> AuthorDate: 2018-04-19 02:10:02 +0000 Commit: Aaron Bauman <bman@gentoo.org> CommitDate: 2018-04-19 02:10:02 +0000 net-wireless/wpa_supplicant: compatibility patch for LibreSSL This patch fixes building with dev-libs/libressl-2.7.x. Patch was backported from upstream commits: ba3658cfff2278bc2ba24c32773962b37648d0b2 dee566d98e85e00b917d3eff42cd7e969de089cc Bug: https://bugs.gentoo.org/651314 Package-Manager: Portage-2.3.29, Repoman-2.3.9 ...wpa_supplicant-2.6-libressl-compatibility.patch | 106 +++++ .../wpa_supplicant/wpa_supplicant-2.6-r6.ebuild | 436 +++++++++++++++++++++ 2 files changed, 542 insertions(+)}