posit-dev / posit-dev/images-shared
r.j2: add manylinux R tarball install macros
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 2
- Forks
- 0
- Avg merge
- 4d 13h
- Merged PRs (30d)
- 22
Description
Add install_manylinux() / run_install_manylinux() to r.j2, so R can be
installed from a self-contained manylinux_2_34 tarball instead of the
deb/RPM package.
Why
The deb/RPM install dynamically links against system libraries (libcairo2,
libcurl4t64, libicu-dev, libopenblas-dev, libpango-1.0-0,
libtcl8.6, libtk8.6, libx11-6, etc.) that live in the installing OS's
own package tree. That's fine for a normal product image that ships its full
OS alongside R, but breaks for posit-dev/images-volumes, whose images are
built FROM scratch and only carry /opt/R — none of those system
libraries make the cut, so R fails at runtime once mounted into a container
that doesn't happen to have Ubuntu's exact package set installed. Verified
directly: copying only /opt/R into an unrelated debian:12-slim container
and running R fails with error while loading shared libraries: libblas.so.3: cannot open shared object file.
The manylinux_2_34 tarball at cdn.posit.co/r/manylinux_2_34/ bundles its
own non-glibc runtime dependencies (RUNPATH $ORIGIN/../../lib/.libs) and
only requires glibc >= 2.34 from the host, so it's safe to copy alone into a
scratch image.
Notes
Originally written as a workaround for the RHEL 10 (UBI) flexiblas-devel
blocker (posit-dev/images-shared#575), but that's fixed upstream
(rstudio/r-builds#329, merged) and doesn't need this. The macros are being
kept for the unrelated images-volumes use case instead.
Related
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading r.j2 and the related images-shared pull request #577 to understand the existing installation macros. Add install_manylinux() and run_install_manylinux() for the manylinux_2_34 R tarball, and verify that the resulting /opt/R installation can be copied into a scratch image without the listed system libraries.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, r
- Domain
- build-system, devops
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 72/100