Skip to content

Commit 26ae8c1

Browse files
committed
[SPARK-56372][INFRA][4.0] Add cmake to CI Docker images for R fs package compilation
This is a cherry-pick of c869549 for branch-4.0. ### What changes were proposed in this pull request? Add `cmake` to the `apt-get install` list in CI Docker images (`docs`, `lint`, `sparkr`). ### Why are the changes needed? The R `fs` package (a transitive dependency of `devtools`, `testthat`, `rmarkdown`) now bundles `libuv v1.52.0`, which requires `cmake` to build. This causes the "Base image build" job to fail with: ``` /bin/bash: line 2: cmake: command not found make: *** [Makevars:44: libuv] Error 127 ERROR: compilation failed for package 'fs' ``` The `fs` compilation failure cascades into: `sass` → `bslib` → `shiny` → `rmarkdown` → `devtools` → `testthat`, breaking the entire R package installation. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? CI should pass with the updated Docker images. ### Was this patch authored or co-authored using generative AI tooling? Co-authored-by: Claude code (Opus 4.6) Closes #55255 from zhengruifeng/cherry-pick-4.0. Authored-by: Ruifeng Zheng <ruifengz@apache.org> Signed-off-by: Ruifeng Zheng <ruifengz@foxmail.com>
1 parent 26a73d3 commit 26ae8c1

3 files changed

Lines changed: 4 additions & 1 deletion

File tree

dev/spark-test-image/docs/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ ENV DEBCONF_NONINTERACTIVE_SEEN=true
3232
RUN apt-get update && apt-get install -y \
3333
build-essential \
3434
ca-certificates \
35+
cmake \
3536
curl \
3637
gfortran \
3738
git \
@@ -70,7 +71,7 @@ RUN apt-get update && apt-get install -y \
7071
RUN Rscript -e "install.packages(c('devtools', 'knitr', 'markdown', 'rmarkdown', 'testthat', 'remotes'), repos='https://cloud.r-project.org/')" && \
7172
Rscript -e "devtools::install_version('roxygen2', version='7.2.0', repos='https://cloud.r-project.org')" && \
7273
Rscript -e "devtools::install_version('pkgdown', version='2.0.1', repos='https://cloud.r-project.org')" && \
73-
Rscript -e "devtools::install_version('preferably', version='0.4', repos='https://cloud.r-project.org')"
74+
Rscript -e "devtools::install_version('preferably', version='0.4', repos='https://cloud.r-project.org', upgrade='never')"
7475

7576
# See more in SPARK-39735
7677
ENV R_LIBS_SITE="/usr/local/lib/R/site-library:${R_LIBS_SITE}:/usr/lib/R/library"

dev/spark-test-image/lint/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ ENV DEBCONF_NONINTERACTIVE_SEEN=true
3232
RUN apt-get update && apt-get install -y \
3333
build-essential \
3434
ca-certificates \
35+
cmake \
3536
curl \
3637
gfortran \
3738
git \

dev/spark-test-image/sparkr/Dockerfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ ENV DEBCONF_NONINTERACTIVE_SEEN=true
3232
RUN apt-get update && apt-get install -y \
3333
build-essential \
3434
ca-certificates \
35+
cmake \
3536
curl \
3637
gfortran \
3738
git \

0 commit comments

Comments
 (0)