[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
12/21: gnu: lsof: Factorise source URIs.
From: |
Tobias Geerinckx-Rice |
Subject: |
12/21: gnu: lsof: Factorise source URIs. |
Date: |
Mon, 19 Feb 2018 00:07:25 -0500 (EST) |
nckx pushed a commit to branch master
in repository guix.
commit cb443e55dcfdce628c0f4f81269adad9fed414d2
Author: Tobias Geerinckx-Rice <address@hidden>
Date: Sun Feb 18 20:27:24 2018 +0100
gnu: lsof: Factorise source URIs.
* gnu/packages/lsof.scm (%ftp-base): Remove variable.
(lsof)[source]: Construct mirror URI list programatically.
---
gnu/packages/lsof.scm | 61 ++++++++++++++++++++-------------------------------
1 file changed, 24 insertions(+), 37 deletions(-)
diff --git a/gnu/packages/lsof.scm b/gnu/packages/lsof.scm
index eff361d..f8742b6 100644
--- a/gnu/packages/lsof.scm
+++ b/gnu/packages/lsof.scm
@@ -25,48 +25,35 @@
#:use-module (guix build-system gnu)
#:use-module (gnu packages perl))
-(define %ftp-base
- "ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/")
-
(define-public lsof
(package
(name "lsof")
(version "4.89")
- (source (origin
- (method url-fetch)
- (uri (list (string-append %ftp-base "lsof_"
- version ".tar.bz2")
- (string-append %ftp-base "OLD/lsof_"
- version ".tar.bz2")
+ (source
+ (origin
+ (method url-fetch)
+ (uri
+ (apply append
+ (map
+ (lambda (mirror-uri)
+ (let ((tarball (string-append name "_" version ".tar.bz2")))
+ (list
+ (string-append mirror-uri "/" tarball)
+ ;; Upon every new release, the previous one is moved here:
+ (string-append mirror-uri "/OLD/" tarball))))
+ (list
+ "ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/"
- ;; Add mirrors because the FTP server at purdue.edu
- ;; bails out when it cannot do a reverse DNS lookup, as
- ;; noted at <http://people.freebsd.org/~abe/>.
- (string-append
- "ftp://ftp.fu-berlin.de/pub/unix/tools/lsof/lsof_"
- version ".tar.bz2")
- (string-append
- "ftp://ftp.fu-berlin.de/pub/unix/tools/lsof/OLD/lsof_"
- version ".tar.bz2")
- (string-append
- "http://www.mirrorservice.org/sites/"
- "lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_"
- version ".tar.bz2")
- (string-append
- "http://www.mirrorservice.org/sites/"
- "lsof.itap.purdue.edu/pub/tools/unix/lsof/OLD/lsof_"
- version ".tar.bz2")
- (string-append
- "ftp://ftp.mirrorservice.org/sites/"
- "lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_"
- version ".tar.bz2")
- (string-append
- "ftp://ftp.mirrorservice.org/sites/"
- "lsof.itap.purdue.edu/pub/tools/unix/lsof/OLD/lsof_"
- version ".tar.bz2")))
- (sha256
- (base32
- "061p18v0mhzq517791xkjs8a5dfynq1418a1mwxpji69zp2jzb41"))))
+ ;; Add mirrors because the canonical FTP server at purdue.edu
+ ;; bails out when it cannot do a reverse DNS lookup, as noted
+ ;; at <http://people.freebsd.org/~abe/>.
+ "ftp://ftp.fu-berlin.de/pub/unix/tools/lsof/"
+ (string-append "http://www.mirrorservice.org/sites/"
+ "lsof.itap.purdue.edu/pub/tools/unix/lsof")
+ (string-append "ftp://ftp.mirrorservice.org/sites/"
+ "lsof.itap.purdue.edu/pub/tools/unix/lsof")))))
+ (sha256
+ (base32 "061p18v0mhzq517791xkjs8a5dfynq1418a1mwxpji69zp2jzb41"))))
(build-system gnu-build-system)
(inputs `(("perl" ,perl)))
(arguments
- 20/21: gnu: iverilog: Update to 10.2., (continued)
- 20/21: gnu: iverilog: Update to 10.2., Tobias Geerinckx-Rice, 2018/02/19
- 09/21: gnu: perl-xml-sax: Update to 1.00., Tobias Geerinckx-Rice, 2018/02/19
- 10/21: gnu: dvdstyler: Update to 3.0.4., Tobias Geerinckx-Rice, 2018/02/19
- 14/21: gnu: lsof: Update phase style., Tobias Geerinckx-Rice, 2018/02/19
- 11/21: gnu: lsof: Replace dead mirror., Tobias Geerinckx-Rice, 2018/02/19
- 21/21: gnu: iverilog: Use Texinfo in description., Tobias Geerinckx-Rice, 2018/02/19
- 13/21: gnu: lsof: Make perl a native input., Tobias Geerinckx-Rice, 2018/02/19
- 03/21: gnu: awscli: Update to 1.14.41., Tobias Geerinckx-Rice, 2018/02/19
- 19/21: gnu: nyacc: Update to 0.83.3., Tobias Geerinckx-Rice, 2018/02/19
- 18/21: gnu: nasm: Update to 2.13.03., Tobias Geerinckx-Rice, 2018/02/19
- 12/21: gnu: lsof: Factorise source URIs.,
Tobias Geerinckx-Rice <=
- 16/21: gnu: lsof: Run tests., Tobias Geerinckx-Rice, 2018/02/19