gnu: r-with-tests: Hardcode path to coreutils’ rm
When running R in a container like this guix environment --no-cwd -C --ad-hoc r-minimal -- Rscript -e 'Sys.timezone()' it would print an additional line sh: rm: command not found before exiting. * gnu/packages/statistics.scm (r-with-tests) [#:phases]: Add substitute* to patch call to `rm` and rename phase to reflect what it does now.
This commit is contained in:
parent
042b6971d7
commit
9ac9bc6051
@ -213,12 +213,15 @@ This package also provides @command{xls2csv} to export Excel files to CSV.")
|
||||
(substitute* "src/library/base/makebasedb.R"
|
||||
(("compress = TRUE") "compress = FALSE"))
|
||||
#t))
|
||||
(add-before 'configure 'patch-uname
|
||||
(add-before 'configure 'patch-coreutils-paths
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
(let ((uname-bin (string-append (assoc-ref inputs "coreutils")
|
||||
"/bin/uname")))
|
||||
(let* ((coreutils (assoc-ref inputs "coreutils"))
|
||||
(uname-bin (string-append coreutils "/bin/uname"))
|
||||
(rm-bin (string-append coreutils "/bin/rm")))
|
||||
(substitute* "src/scripts/R.sh.in"
|
||||
(("uname") uname-bin)))
|
||||
(("uname") uname-bin))
|
||||
(substitute* "src/unix/sys-std.c"
|
||||
(("rm -Rf ") (string-append rm-bin " -Rf "))))
|
||||
#t))
|
||||
(add-after 'unpack 'build-reproducibly
|
||||
(lambda _
|
||||
|
Loading…
Reference in New Issue
Block a user