3
5
Fork 0
mirror of git://git.savannah.gnu.org/guix.git synced 2023-12-14 03:33:07 +01:00

gnu: racket-minimal: Don't configure non-existant catalogs.

* gnu/packages/racket.scm (racket-minimal)[arguments]<#:phases>: Change
'initialize-config.rktd' to only add a release catalog when the package
version is a release version.

Signed-off-by: Liliana Marie Prikler <liliana.prikler@gmail.com>
This commit is contained in:
Philip McGrath 2022-02-27 16:29:01 -05:00 committed by Liliana Marie Prikler
parent 9e5e413c81
commit 9f8f785014
No known key found for this signature in database
GPG key ID: 442A84B8C70E2F87

View file

@ -231,6 +231,15 @@
(format #t "(~s . ~s)" k v)))
alist)
(display ")\n"))
(define maybe-release-catalog
(let ((v #$(package-version this-package)))
(if (string-match "^[0-9]+\\.[0-9]+($|\\.[0-8][0-9]*$)"
v)
`(,(string-append
"https://download.racket-lang.org/releases/"
v
"/catalog/"))
'())))
(mkdir-p "racket/etc")
(with-output-to-file "racket/etc/config.rktd"
(lambda ()
@ -239,12 +248,8 @@
. (#f #$(file-append (this-package-input "openssl") "/lib")
#$(file-append (this-package-input "sqlite") "/lib")))
(build-stamp . "")
(catalogs
. (,(string-append
"https://download.racket-lang.org/releases/"
#$(package-version this-package)
"/catalog/")
#f))))))))
(catalogs ,@maybe-release-catalog
#f)))))))
(add-before 'configure 'chdir
(lambda _
(chdir "racket/src")))