summarylogtreecommitdiffstats
path: root/cran_multithread.patch
diff options
context:
space:
mode:
Diffstat (limited to 'cran_multithread.patch')
-rw-r--r--cran_multithread.patch13
1 files changed, 13 insertions, 0 deletions
diff --git a/cran_multithread.patch b/cran_multithread.patch
new file mode 100644
index 000000000000..57cacc88a746
--- /dev/null
+++ b/cran_multithread.patch
@@ -0,0 +1,13 @@
+diff --git a/dependencies/common/install-packages b/dependencies/common/install-packages
+index e0d184e5f0..658fd31fd4 100755
+--- a/dependencies/common/install-packages
++++ b/dependencies/common/install-packages
+@@ -104,7 +104,7 @@ fi
+
+ # install packages needed to run tests
+ for RPKG in rmarkdown renv testthat xml2 yaml; do
+- RINSTALLCMD="if("'!'"require($RPKG, quietly = TRUE)) { install.packages('$RPKG', lib='$RPKGLIB', repos='https://cran.rstudio.com/') }"
++ RINSTALLCMD="if("'!'"require($RPKG, quietly = TRUE)) { options(Ncpus = @@proc_num@@ ); install.packages('$RPKG', lib='$RPKGLIB', repos='https://cran.rstudio.com/') }"
+ echo "> $RINSTALLCMD"
+ Rscript -e "$RINSTALLCMD"
+ done