gnu: libretro-lowresnx: Update to 1.2.
[jackhill/guix/guix.git] / gnu / packages / ftp.scm
CommitLineData
158adb66 1;;; GNU Guix --- Functional package management for GNU
a4bf1b1a 2;;; Copyright © 2014, 2015, 2018, 2021, 2021 Ludovic Courtès <ludo@gnu.org>
8cc91fa0 3;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
87d79282 4;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
634d9845 5;;; Copyright © 2016–2021 Tobias Geerinckx-Rice <me@tobias.gr>
afa59535 6;;; Copyright © 2017 Rene Saavedra <rennes@openmailbox.org>
634d9845 7;;; Copyright © 2021 David Larsson <david.larsson@selfhosted.xyz>
158adb66
LC
8;;;
9;;; This file is part of GNU Guix.
10;;;
11;;; GNU Guix is free software; you can redistribute it and/or modify it
12;;; under the terms of the GNU General Public License as published by
13;;; the Free Software Foundation; either version 3 of the License, or (at
14;;; your option) any later version.
15;;;
16;;; GNU Guix is distributed in the hope that it will be useful, but
17;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19;;; GNU General Public License for more details.
20;;;
21;;; You should have received a copy of the GNU General Public License
22;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23
24(define-module (gnu packages ftp)
74ba3a68 25 #:use-module ((guix licenses) #:select (gpl2 gpl2+ gpl3+ clarified-artistic))
158adb66 26 #:use-module (guix build-system gnu)
8cc91fa0
AE
27 #:use-module (guix download)
28 #:use-module (guix packages)
29 #:use-module (gnu packages)
2d125a9b 30 #:use-module (gnu packages autotools)
afa59535 31 #:use-module (gnu packages check)
634d9845 32 #:use-module (gnu packages cpio)
afa59535 33 #:use-module (gnu packages compression)
afa59535 34 #:use-module (gnu packages freedesktop)
2d125a9b 35 #:use-module (gnu packages gettext)
0bc26f66
RS
36 #:use-module (gnu packages glib)
37 #:use-module (gnu packages gtk)
38 #:use-module (gnu packages libidn)
634d9845 39 #:use-module (gnu packages linux)
158adb66 40 #:use-module (gnu packages ncurses)
0bc26f66 41 #:use-module (gnu packages nettle)
158adb66 42 #:use-module (gnu packages pkg-config)
0bc26f66 43 #:use-module (gnu packages readline)
cd0322a3 44 #:use-module (gnu packages sqlite)
a7fd7b68 45 #:use-module (gnu packages tls)
0bc26f66
RS
46 #:use-module (gnu packages wxwidgets)
47 #:use-module (gnu packages xml))
158adb66
LC
48
49(define-public lftp
50 (package
51 (name "lftp")
3a4a5be1 52 (version "4.9.2")
158adb66
LC
53 (source (origin
54 (method url-fetch)
d736eec2
MB
55 ;; See https://lftp.tech/get.html for mirrors.
56 (uri (list (string-append "https://lftp.tech/ftp/lftp-"
ee5bae30 57 version ".tar.xz")
61dd253f 58 (string-append "https://lftp.tech/ftp/old/lftp-"
d736eec2
MB
59 version ".tar.xz")
60 (string-append "ftp://ftp.st.ryukoku.ac.jp/pub/network/"
61 "ftp/lftp/lftp-" version ".tar.xz")))
158adb66
LC
62 (sha256
63 (base32
3a4a5be1 64 "03b7y0h3mf4jfq5y8zw6hv9v44z3n6i8hc1iswax96y3z7sc85y5"))))
158adb66
LC
65 (build-system gnu-build-system)
66 (native-inputs
67 `(("pkg-config" ,pkg-config)))
68 (inputs
69 `(("zlib" ,zlib)
70 ("readline" ,readline)
71 ("gnutls" ,gnutls)))
5e270e8e
TGR
72 (arguments
73 `(#:phases
74 (modify-phases %standard-phases
75 ;; Disable tests that require network access, which is most of them.
76 (add-before 'check 'disable-impure-tests
77 (lambda _
78 (substitute* "tests/Makefile"
79 (("(ftp-cls-l|ftp-list|http-get)\\$\\(EXEEXT\\)") "")
70dcf9c9
MB
80 (("lftp-https-get ") ""))
81 #t)))
5e270e8e
TGR
82 #:configure-flags
83 (list (string-append "--with-readline="
84 (assoc-ref %build-inputs "readline")))))
61dd253f 85 (home-page "https://lftp.tech/")
158adb66
LC
86 (synopsis "Command-line file transfer program")
87 (description
88 "LFTP is a sophisticated FTP/HTTP client, and a file transfer program
89supporting a number of network protocols. Like Bash, it has job control and
90uses the Readline library for input. It has bookmarks, a built-in mirror
91command, and can transfer several files in parallel. It was designed with
92reliability in mind.")
93 (license gpl3+)))
dd3b6d66
LC
94
95(define-public ncftp
96 (package
97 (name "ncftp")
96d47129 98 (version "3.2.6")
dd3b6d66
LC
99 (source (origin
100 (method url-fetch)
101 (uri (string-append "ftp://ftp.ncftp.com/ncftp/ncftp-"
96d47129 102 version "-src.tar.xz"))
dd3b6d66
LC
103 (sha256
104 (base32
96d47129 105 "1389657cwgw5a3kljnqmhvfh4vr2gcr71dwz1mlhf22xq23hc82z"))
dd3b6d66
LC
106 (modules '((guix build utils)))
107 (snippet
108 '(begin
109 ;; Use the right 'rm' and 'ls'.
110 (substitute* (cons "configure"
111 (find-files "."
112 "^(Makefile\\.in|.*\\.sh)$"))
113 (("/bin/(rm|ls)" _ command)
114 command))
115
116 ;; This is free software, avoid any confusion.
117 (substitute* (find-files "." "\\.c$")
118 (("a freeware program")
6cbee49d
MW
119 "free software"))
120 #t))))
a4bf1b1a
LC
121 (properties
122 `((release-monitoring-url . "https://www.ncftp.com/download/")))
dd3b6d66
LC
123 (build-system gnu-build-system)
124 (arguments
f5d37732
TGR
125 '(#:phases
126 (modify-phases %standard-phases
127 (replace 'configure
128 (lambda* (#:key outputs #:allow-other-keys)
129 ;; This is an old 'configure' script that doesn't
130 ;; understand variables passed as arguments.
131 (let ((out (assoc-ref outputs "out")))
132 (setenv "CONFIG_SHELL" (which "sh"))
133 (setenv "SHELL" (which "sh"))
ec7245f0
RW
134 (invoke "./configure"
135 (string-append "--prefix=" out))))))
136 #:tests? #f)) ;there are no tests
dd3b6d66 137 (inputs `(("ncurses" ,ncurses)))
a96d4897 138 (home-page "https://www.ncftp.com/ncftp/")
dd3b6d66
LC
139 (synopsis "Command-line File Transfer Protocol (FTP) client")
140 (description
141 "NcFTP Client (or just NcFTP) is a set of command-line programs to access
36a4366d
EF
142File Transfer Protocol (FTP) servers. This includes @code{ncftp}, an interactive
143FTP browser, as well as non-interactive commands such as @code{ncftpput} and
144@code{ncftpget}.")
dd3b6d66 145 (license clarified-artistic)))
8cc91fa0
AE
146
147
148(define-public weex
149 (package
150 (name "weex")
2d125a9b 151 (version "2.8.2")
8cc91fa0
AE
152 (source
153 (origin
154 (method url-fetch)
155 (uri
2d125a9b
LF
156 (string-append "mirror://sourceforge/weex/weex/"
157 "/weex_" version ".tar.gz"))
8cc91fa0
AE
158 (sha256
159 (base32
2d125a9b 160 "1ir761hjncr1bamaqcw9j7x57xi3s9jax3223bxwbq30a0vsw1pd"))))
8cc91fa0 161 (build-system gnu-build-system)
2d125a9b
LF
162 (native-inputs
163 `(("automake" ,automake)
164 ("autoconf" ,autoconf)
7c90d0f4 165 ("gettext" ,gettext-minimal)))
8cc91fa0
AE
166 (home-page "http://weex.sourceforge.net/")
167 (synopsis "Non-interactive client for FTP synchronization")
168 (description
169 "Weex is a utility designed to automate the task of remotely
170maintaining a web page or other FTP archive. It synchronizes a set of
171local files to a remote server by performing uploads and remote deletes
172as required.")
173 (license gpl2+)))
afa59535
RS
174
175(define-public libfilezilla
176 (package
177 (name "libfilezilla")
df7ebbd9 178 (version "0.24.1")
afa59535
RS
179 (source
180 (origin
181 (method url-fetch)
118a0845 182 (uri (string-append "https://download.filezilla-project.org/"
786e0073 183 "libfilezilla/libfilezilla-" version ".tar.bz2"))
afa59535 184 (sha256
df7ebbd9 185 (base32 "1zfnqbn14dx0fl45mfaznr5n5xsxy1kx8z9f80fppbqn37pb9mgx"))))
afa59535 186 (build-system gnu-build-system)
0eca1c5d
TGR
187 (arguments
188 `(#:configure-flags
189 (list "--disable-static")))
afa59535 190 (native-inputs
a9af060e 191 `(("cppunit" ,cppunit)
df7ebbd9 192 ("gettext" ,gettext-minimal)
a9af060e 193 ("pkg-config" ,pkg-config)))
07df80d1 194 (inputs
df7ebbd9
TGR
195 `(("gnutls" ,gnutls)
196 ("nettle" ,nettle)))
afa59535
RS
197 (home-page "https://lib.filezilla-project.org")
198 (synopsis "Cross-platform C++ library used by Filezilla client")
199 (description
200 "This package provides some basic functionality to build high-performing,
7cace186
TGR
201platform-independent programs.
202
203Some of the highlights include:
204@itemize
205@item
206A type-safe, multi-threaded event system that's simple to use yet efficient.
207@item
208Timers for periodic events.
209@item
210A @code{datetime} class that not only tracks timestamp but also their accuracy,
211which simplifies dealing with timestamps originating from different sources.
212@item
213Simple process handling for spawning child processes with redirected input and
214output.
215@end itemize\n")
afa59535 216 (license gpl2+)))
0bc26f66
RS
217
218(define-public filezilla
219 (package
220 (name "filezilla")
df7ebbd9 221 (version "3.50.0")
0bc26f66
RS
222 (source
223 (origin
224 (method url-fetch)
10fadd1e
TGR
225 (uri (string-append "https://download.filezilla-project.org/client/"
226 "FileZilla_" version "_src.tar.bz2"))
0bc26f66 227 (sha256
df7ebbd9 228 (base32 "042w2f5cf8g9cr7d3m6294ygx7jggcria9502jnql855khk8gnz0"))))
0bc26f66 229 (build-system gnu-build-system)
a78e0bda
LF
230 (arguments
231 ;; Don't let filezilla phone home to check for updates.
232 '(#:configure-flags '("--disable-autoupdatecheck")))
0bc26f66 233 (native-inputs
2450ccb4
TGR
234 `(("cppunit" ,cppunit)
235 ("gettext" ,gettext-minimal)
0bc26f66 236 ("pkg-config" ,pkg-config)
0bc26f66
RS
237 ("xdg-utils" ,xdg-utils)))
238 (inputs
239 `(("dbus" ,dbus)
240 ("gnutls" ,gnutls)
241 ("gtk+" ,gtk+)
242 ("libfilezilla" ,libfilezilla)
243 ("libidn" ,libidn)
244 ("nettle" ,nettle)
63247277 245 ("pugixml" ,pugixml)
0bc26f66
RS
246 ("sqlite" ,sqlite)
247 ("wxwidgets" ,wxwidgets)))
248 (home-page "https://filezilla-project.org")
249 (synopsis "Full-featured graphical FTP/FTPS/SFTP client")
250 (description
251 "Filezilla client supports FTP, FTP over SSL/TLS (FTPS),
252SSH File Transfer Protocol (SFTP), HTTP/1.1, SOCKS5, FTP-Proxy, IPv6
253and others features such as bookmarks, drag and drop, filename filters,
254directory comparison and more.")
255 (license gpl2+)
256 (properties '((upstream-name . "FileZilla")))))
74ba3a68
DM
257
258(define-public vsftpd
614defcd
TGR
259 ;; Use a significantly patched CentOS variant with TLSv1.2 support and
260 ;; further bug and security fixes.
634d9845 261 (let ((upstream-version "3.0.3")
262 (centos-version "8.3.2011")
263 (revision "32.el8"))
264 (package
265 (name "vsftpd")
614defcd 266 (version (string-append upstream-version "-" revision))
634d9845 267 (source
268 (origin
269 (method url-fetch)
270 (uri (string-append
271 "https://vault.centos.org/centos/" centos-version
272 "/AppStream/Source/SPackages/vsftpd-" upstream-version "-"
273 revision ".src.rpm"))
274 (sha256
275 (base32 "1xl0kqcismf82hl99klqbvvpylpyk1yr1qjy5hd8f80cj4lyl0f4"))))
276 (build-system gnu-build-system)
277 (arguments
278 `(#:make-flags '("LDFLAGS=-lcrypt -lssl -pie")
279 #:tests? #f ; no tests exist
280 #:phases
281 (modify-phases %standard-phases
282 (replace 'unpack
283 (lambda* (#:key source #:allow-other-keys)
284 (invoke "7z" "e" source "-ocpio")
285 (invoke "cpio" "-idmv"
286 (string-append "--file=cpio/vsftpd-"
287 ,upstream-version "-" ,revision
288 ".src.cpio"))
289 (invoke "tar" "xvf"
290 (string-append "vsftpd-" ,upstream-version ".tar.gz"))
291 (chdir (string-append "vsftpd-" ,upstream-version))))
292 (add-after 'unpack 'apply-CentOS-patches
293 ;; Apply all patches as enumerated in vsftpd.spec, in order:
294 ;; simply using FIND-FILES would silently corrupt the result.
295 (lambda _
296 (call-with-input-file "../vsftpd.spec"
297 (lambda (port)
298 (use-modules (ice-9 rdelim))
299 (let loop ()
300 (let ((line (read-line port)))
301 (unless (eof-object? line)
302 (when (string-prefix? "Patch" line)
303 (let* ((space (string-rindex line #\space))
304 (patch (string-drop line (+ 1 space))))
305 (format #t "Applying '~a'.\n" patch)
306 (invoke "patch" "-Np1"
307 "-i" (string-append "../" patch))))
308 (loop))))))))
309 (add-after 'unpack 'patch-installation-directory
310 (lambda* (#:key outputs #:allow-other-keys)
311 (substitute* "Makefile"
312 (("/usr") (assoc-ref outputs "out")))
313 #t))
314 (add-before 'install 'mkdir
315 (lambda* (#:key outputs #:allow-other-keys)
316 (let ((out (assoc-ref outputs "out")))
317 (mkdir-p out)
318 (mkdir (string-append out "/sbin"))
319 (mkdir (string-append out "/man"))
320 (mkdir (string-append out "/man/man5"))
321 (mkdir (string-append out "/man/man8"))
322 #t)))
323 (delete 'configure))))
324 (native-inputs
325 ;; Used to unpack the source RPM.
326 `(("p7zip" ,p7zip)
327 ("cpio" ,cpio)))
328 (inputs
329 `(("libcap" ,libcap)
330 ("linux-pam" ,linux-pam)
331 ("openssl" ,openssl)))
332 (home-page "https://security.appspot.com/vsftpd.html")
333 (synopsis "Share files securely over FTP or FTPS")
334 (description "@command{vsftpd} is a daemon that listens on a TCP socket
74ba3a68
DM
335for clients and gives them access to local files via File Transfer
336Protocol.")
634d9845 337 (license gpl2))))