build: Add cran-uri procedure.
* guix/build-system/r.scm (cran-uri): New procedure.
This commit is contained in:
parent
fed5a6898b
commit
5546114e73
@ -28,7 +28,8 @@ (define-module (guix build-system r)
|
||||
#:use-module (srfi srfi-26)
|
||||
#:export (%r-build-system-modules
|
||||
r-build
|
||||
r-build-system))
|
||||
r-build-system
|
||||
cran-uri))
|
||||
|
||||
;; Commentary:
|
||||
;;
|
||||
@ -36,6 +37,15 @@ (define-module (guix build-system r)
|
||||
;;
|
||||
;; Code:
|
||||
|
||||
(define (cran-uri name version)
|
||||
"Return a list of URI strings for the R package archive on CRAN for the
|
||||
release corresponding to NAME and VERSION. As only the most recent version is
|
||||
available via the first URI, the second URI points to the archived version."
|
||||
(list (string-append "mirror://cran/src/contrib/"
|
||||
name "_" version ".tar.gz")
|
||||
(string-append "mirror://cran/src/contrib/Archive/"
|
||||
name "/" name "_" version ".tar.gz")))
|
||||
|
||||
(define %r-build-system-modules
|
||||
;; Build-side modules imported by default.
|
||||
`((guix build r-build-system)
|
||||
|
Loading…
Reference in New Issue
Block a user