gnu: r-with-tests: Fix reference to grep.
detectCores.R fails to return the number of cores when running R in a container without grep. Reported-by: Jonas Freimuth. * gnu/packages/statistics.scm (r-with-tests)[arguments]: Fix references to grep and wc in detectCores.R. [inputs]: Add grep.
This commit is contained in:
parent
093e920418
commit
ff0d34a29b
1 changed files with 10 additions and 1 deletions
|
@ -244,7 +244,15 @@ This package also provides @command{xls2csv} to export Excel files to CSV.")
|
||||||
(substitute* "src/scripts/R.sh.in"
|
(substitute* "src/scripts/R.sh.in"
|
||||||
(("uname") uname-bin))
|
(("uname") uname-bin))
|
||||||
(substitute* "src/unix/sys-std.c"
|
(substitute* "src/unix/sys-std.c"
|
||||||
(("rm -Rf ") (string-append rm-bin " -Rf "))))))
|
(("rm -Rf ") (string-append rm-bin " -Rf ")))
|
||||||
|
(substitute* "src/library/parallel/R/detectCores.R"
|
||||||
|
(("'grep")
|
||||||
|
(string-append "'"
|
||||||
|
(search-input-file inputs "/bin/grep")))
|
||||||
|
(("\\| wc -l")
|
||||||
|
(string-append "| "
|
||||||
|
(search-input-file inputs "/bin/wc")
|
||||||
|
" -l"))))))
|
||||||
(add-after 'unpack 'patch-tests
|
(add-after 'unpack 'patch-tests
|
||||||
(lambda _
|
(lambda _
|
||||||
;; This is needed because R is run during the check phase and
|
;; This is needed because R is run during the check phase and
|
||||||
|
@ -401,6 +409,7 @@ as.POSIXct(if (\"\" != Sys.getenv(\"SOURCE_DATE_EPOCH\")) {\
|
||||||
curl
|
curl
|
||||||
openblas
|
openblas
|
||||||
gfortran
|
gfortran
|
||||||
|
grep
|
||||||
icu4c
|
icu4c
|
||||||
libjpeg-turbo
|
libjpeg-turbo
|
||||||
libpng
|
libpng
|
||||||
|
|
Reference in a new issue