Stuart Henderson <st...@openbsd.org> writes: > On 2014/07/26 21:49, Rafael Sadowski wrote: >> Hey ports@, >> >> here is a boring update for lftp. build/tested@amd64. >> >> have fun, Rafael > > lftp's autoconf check for libssl (ssl.m4) is broken with libressl, so it can > no > longer use any tls-based protocols. Do you have time to look at fixing that > while > you're there?
I got curious, here's an attempt. I did not patch the offending code since that would have added a file to the CVS tree. For the record, here is where RAND_egd appears. lftp_ssl_openssl_instance::lftp_ssl_openssl_instance() { crl_store=0; ssl_ctx=0; #ifdef WINDOWS RAND_screen(); #endif RAND_file_name(file,sizeof(file)); if(RAND_egd(file)>0) return; if(RAND_load_file(file,-1) && RAND_status()!=0) atexit(lftp_ssl_write_rnd); #if SSLEAY_VERSION_NUMBER < 0x0800 ssl_ctx=SSL_CTX_new(); X509_set_default_verify_paths(ssl_ctx->cert); #else SSLeay_add_ssl_algorithms(); ssl_ctx=SSL_CTX_new(SSLv23_client_method()); [...] Looks dubious IMO. :) Tested against https only. I removed MAINTAINER while here. Index: Makefile =================================================================== RCS file: /cvs/ports/net/lftp/Makefile,v retrieving revision 1.97 diff -u -p -r1.97 Makefile --- Makefile 24 Apr 2014 16:29:03 -0000 1.97 +++ Makefile 8 Aug 2014 19:57:18 -0000 @@ -2,13 +2,11 @@ COMMENT= shell-like command line ftp and sftp client -DISTNAME = lftp-4.4.15 +DISTNAME= lftp-4.5.3 CATEGORIES= net HOMEPAGE= http://lftp.yar.ru/ -MAINTAINER= Kevin Lo <ke...@openbsd.org> - # GPLv3+ PERMIT_PACKAGE_CDROM= Yes @@ -24,8 +22,9 @@ CONFIGURE_STYLE= gnu CONFIGURE_ARGS= --with-openssl \ --without-gnutls \ --disable-shared -CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include/ereadline -I${LOCALBASE}/include" \ - LDFLAGS="-L${LOCALBASE}/lib" +# XXX hack to get rid of RAND_egd +CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include/ereadline -I${LOCALBASE}/include \ + -DRAND_egd\(f\)=-1" LDFLAGS="-L${LOCALBASE}/lib" MODULES= devel/gettext Index: distinfo =================================================================== RCS file: /cvs/ports/net/lftp/distinfo,v retrieving revision 1.59 diff -u -p -r1.59 distinfo --- distinfo 24 Apr 2014 16:29:03 -0000 1.59 +++ distinfo 8 Aug 2014 19:57:40 -0000 @@ -1,2 +1,2 @@ -SHA256 (lftp-4.4.15.tar.gz) = d+/dknM5//7OIZgQOXV5FyVdUX198WZqfifzFPfugMc= -SIZE (lftp-4.4.15.tar.gz) = 2539525 +SHA256 (lftp-4.5.3.tar.gz) = i+JqVSioomn473gDgLwIVVRbfXzJ3dgsw5WVORhIzJ0= +SIZE (lftp-4.5.3.tar.gz) = 2614641 Index: patches/patch-configure =================================================================== RCS file: /cvs/ports/net/lftp/patches/patch-configure,v retrieving revision 1.3 diff -u -p -r1.3 patch-configure --- patches/patch-configure 24 Apr 2014 16:29:03 -0000 1.3 +++ patches/patch-configure 8 Aug 2014 20:01:11 -0000 @@ -1,10 +1,11 @@ $OpenBSD: patch-configure,v 1.3 2014/04/24 16:29:03 benoit Exp $ Use GNU readline as our base readline lacks add_history_time(). +Fix failing test for libssl, LibreSSL doesn't provide RAND_egd. ---- configure.orig Fri Jan 24 08:59:53 2014 -+++ configure Sun Apr 13 08:55:09 2014 -@@ -48459,7 +48459,7 @@ if ${lftp_cv_precompiled_readline+:} false; then : +--- configure.orig Sun Jul 6 14:15:50 2014 ++++ configure Fri Aug 8 21:57:44 2014 +@@ -47994,7 +47994,7 @@ if ${lftp_cv_precompiled_readline+:} false; then : else old_LIBS="$LIBS" @@ -13,7 +14,7 @@ Use GNU readline as our base readline la cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ extern int (*rl_getc_function)(); -@@ -48499,7 +48499,7 @@ if test $lftp_cv_precompiled_readline = yes; then +@@ -48034,7 +48034,7 @@ if test $lftp_cv_precompiled_readline = yes; then READLINE_DIR='' { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } @@ -22,3 +23,12 @@ Use GNU readline as our base readline la READLINE_DEPEND='' COMPILE_READLINE=no else +@@ -48327,7 +48327,7 @@ else + int + main () + { +-static SSL_CTX *ctx; SSL_new(ctx); RAND_status(); RAND_egd("file") ++static SSL_CTX *ctx; SSL_new(ctx); RAND_status(); + ; + return 0; + } Index: pkg/PLIST =================================================================== RCS file: /cvs/ports/net/lftp/pkg/PLIST,v retrieving revision 1.26 diff -u -p -r1.26 PLIST --- pkg/PLIST 29 May 2013 14:08:06 -0000 1.26 +++ pkg/PLIST 8 Aug 2014 20:00:58 -0000 @@ -28,6 +28,7 @@ share/locale/ko/LC_MESSAGES/lftp.mo share/locale/pl/LC_MESSAGES/lftp.mo share/locale/pt_BR/LC_MESSAGES/lftp.mo share/locale/ru/LC_MESSAGES/lftp.mo +share/locale/uk/LC_MESSAGES/lftp.mo share/locale/zh_CN/LC_MESSAGES/lftp.mo share/locale/zh_HK/LC_MESSAGES/lftp.mo share/locale/zh_TW/LC_MESSAGES/lftp.mo -- jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE