--- /dev/null
+--- lftp-2.3.9.orig/src/complete.cc Fri Dec 8 16:30:37 2000
++++ lftp-2.3.9/src/complete.cc Sat Apr 14 05:38:44 2001
+@@ -39,7 +39,11 @@
+ #include "url.h"
+
+ CDECL_BEGIN
++#undef __P
++#define __P(args) args
+ #include "readline/readline.h"
++#undef __P
++#define __P(args) args __THROW
+ CDECL_END
+
+ static char *bash_dequote_filename (char *text, int quote_char);
+@@ -575,7 +579,7 @@
+ text=bash_dequote_filename(text, quoted);
+ len=strlen(text);
+
+- char **matches=completion_matches(text,(CPFunction*)generator);
++ char **matches=rl_completion_matches(text,(CPFunction*)generator);
+
+ glob_res=0;
+ if(rg)
+@@ -952,8 +956,6 @@
+
+ int lftp_complete_remote(int count,int key)
+ {
+- extern Function *rl_last_func;
+-
+ if(rl_last_func == (Function*)lftp_complete_remote)
+ rl_last_func = (Function*)rl_complete;
+
Source0: ftp://ftp.yars.free.net/pub/software/unix/net/ftp/client/lftp/%{name}-%{version}.tar.bz2
Patch0: %{name}-am14_fix.patch
Patch1: %{name}-use_system_gettext.m4.patch
+Patch2: %{name}-readline.patch
Icon: ftp.gif
URL: http://ftp.yars.free.net/projects/lftp/
BuildRequires: ncurses-devel >= 5.2
BuildRequires: gettext-devel
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
-%define _sysconfdir /etc
-
%description
LFTP is a shell-like command line ftp client. The main two advantages
over other ftp clients are reliability and ability to perform tasks in
%setup -q
%patch0 -p1
%patch1 -p1
+%patch2 -p1
%build
gettextize --copy --force
install lftp.conf $RPM_BUILD_ROOT%{_sysconfdir}
-chmod +x $RPM_BUILD_ROOT%{_libdir}/lftp/*
-
gzip -9nf README NEWS
%find_lang %{name}
%attr(755,root,root) %{_datadir}/lftp
%dir %{_libdir}/lftp
-%attr(755,root,root) %{_libdir}/lftp/*.so
+%dir %{_libdir}/lftp/%{version}
+%attr(755,root,root) %{_libdir}/lftp/%{version}/*.so