This is an automated email from the ASF dual-hosted git repository.
jonkeane pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/master by this push:
new c875c5d MINOR: [R][CI] use Renviron.site for setting `MAKEFLAGS`
c875c5d is described below
commit c875c5d17b2f74246a5b727706a4bf28e722483e
Author: Jonathan Keane <[email protected]>
AuthorDate: Wed Oct 13 09:44:05 2021 -0500
MINOR: [R][CI] use Renviron.site for setting `MAKEFLAGS`
According to
https://cran.r-project.org/doc/manuals/r-devel/R-admin.html#Customizing-package-compilation
`R_HOME/etc/Makevars.site` (or `Makevars` under `~/.R/`) should work, but when
trying that I was unable to get R to recognize that (e.g. the Makevars file
would exist, with the appropriate line in it), but `Sys.getenv("MAKEFLAGS")`
would return nothing.
Renviron.site, does, however work!
Closes #11394 from jonkeane/parallel-build-r
Authored-by: Jonathan Keane <[email protected]>
Signed-off-by: Jonathan Keane <[email protected]>
---
ci/docker/linux-apt-docs.dockerfile | 2 +-
ci/docker/linux-apt-lint.dockerfile | 2 +-
ci/docker/linux-apt-r.dockerfile | 2 +-
ci/scripts/r_docker_configure.sh | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/ci/docker/linux-apt-docs.dockerfile
b/ci/docker/linux-apt-docs.dockerfile
index 8f124a7..12c797f 100644
--- a/ci/docker/linux-apt-docs.dockerfile
+++ b/ci/docker/linux-apt-docs.dockerfile
@@ -93,7 +93,7 @@ RUN gem install --no-document bundler && \
COPY ci/etc/rprofile /arrow/ci/etc/
RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
# Also ensure parallel compilation of C/C++ code
-RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Makeconf
+RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Renviron.site
COPY ci/scripts/r_deps.sh /arrow/ci/scripts/
COPY r/DESCRIPTION /arrow/r/
diff --git a/ci/docker/linux-apt-lint.dockerfile
b/ci/docker/linux-apt-lint.dockerfile
index 0464658..84de6b0 100644
--- a/ci/docker/linux-apt-lint.dockerfile
+++ b/ci/docker/linux-apt-lint.dockerfile
@@ -61,7 +61,7 @@ RUN apt-key adv \
COPY ci/etc/rprofile /arrow/ci/etc/
RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
# Also ensure parallel compilation of C/C++ code
-RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Makeconf
+RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Renviron.site
COPY ci/scripts/r_deps.sh /arrow/ci/scripts/
diff --git a/ci/docker/linux-apt-r.dockerfile b/ci/docker/linux-apt-r.dockerfile
index 3a84a11..5232cb2 100644
--- a/ci/docker/linux-apt-r.dockerfile
+++ b/ci/docker/linux-apt-r.dockerfile
@@ -79,7 +79,7 @@ RUN if [ "${gcc_version}" != "" ]; then \
COPY ci/etc/rprofile /arrow/ci/etc/
RUN cat /arrow/ci/etc/rprofile >> $(R RHOME)/etc/Rprofile.site
# Also ensure parallel compilation of C/C++ code
-RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Makeconf
+RUN echo "MAKEFLAGS=-j$(R -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Renviron.site
COPY ci/scripts/r_deps.sh /arrow/ci/scripts/
COPY r/DESCRIPTION /arrow/r/
diff --git a/ci/scripts/r_docker_configure.sh b/ci/scripts/r_docker_configure.sh
index d138d03..eaaceb8 100755
--- a/ci/scripts/r_docker_configure.sh
+++ b/ci/scripts/r_docker_configure.sh
@@ -28,7 +28,7 @@ if [ -f "/arrow/ci/etc/rprofile" ]; then
fi
# Ensure parallel compilation of C/C++ code
-echo "MAKEFLAGS=-j$(${R_BIN} -s -e 'cat(parallel::detectCores())')" >>
$(${R_BIN} RHOME)/etc/Makeconf
+echo "MAKEFLAGS=-j$(${R_BIN} -s -e 'cat(parallel::detectCores())')" >> $(R
RHOME)/etc/Renviron.site
# Special hacking to try to reproduce quirks on fedora-clang-devel on CRAN
# which uses a bespoke clang compiled to use libc++