Debian Patches

Status for r-base/4.6.1-9

Patch Description Author Forwarded Bugs Origin Last update
set_R_LIBS_USER_and_SITE_in_Renviron.patch Modify R_LIBS_USER and R_LIBS_SITE for Debian settings This goes back to a decision made jointly with R Core upstream in the early
2000s to support three default directories: /usr/lib/R/library for base and recommended
packages (as part of the binary), /usr/lib/R/site-library for binary r-cran-* packages
as part of the distro, and /usr/local/lib/R/site-library for user-controlled, non-distro
packages to be visible system-wide.
.
A recent-ish change in R 4.2.* made it that we needed to change where we set this here
and not in Renviron.site which would not be read in 'R -q' mode.
.
r-base (4.2.2.20221110-2) unstable; urgency=medium
.
[ Dirk Eddelbuettel ]
* debian/patches/set_R_LIBS_USER_and_SITE_in_Renviron.patch: Modified following
helpful email discussion with Kurt Hornik
* debian/control: Remove Depends: on perl in light of change by Giole
.
[ Adrian Bunk ]
* debian/rukes: Set -ffloat-store on i386
.
[ Giole Barabucci ]
* debian/r-base-core.postinst: Simplify one perl substitution call to sed
Dirk Eddelbuettel <edd@debian.org> not-needed 2023-01-20
tools_pkg_calls_mkdesc <short summary of the patch>
This ensure a possible PKG_BUILT_STAMP is used as the 'mkdesc' target reflects it.
Dirk Eddelbuettel <edd@debian.org> no 2026-08-05
reflect-SOURCE_DATE_EPOCH-in-help2man <short summary of the patch>
This short patch comes straight from a current version of help2man as in Debian.
Dirk Eddelbuettel <edd@debian.org> no 2026-08-13
do-not-reflect-hostname-in-libtool Do not report hostname in libtool
Upstream is making the same change. Motivation is reproducible builds.
Dirk Eddelbuettel <edd@debian.org> no 2026-08-17
no-systime-sourceEnvironment Make sourceEnvironment class prototype deterministic (reproducible builds)
The 'sourceEnvironment' S4 class prototype embeds 'Sys.time()', which stamps the
wall-clock build time into the methods package's R/methods.rdb (and hence .rdx)
during 'loadNamespace("methods")' at build time. Prefer the value of
SOURCE_DATE_EPOCH when set (as done for reproducible builds), falling back to
Sys.time() otherwise so upstream behaviour is preserved when it is not set.
Dirk Eddelbuettel <edd@debian.org> no 2026-10-14
no-systime-Rd2HTML Make build/install-stage \Sexpr timestamps deterministic
The 'build', 'install' and 'render' stage \Sexpr macros on the Rd2HTML man page call
format(Sys.time()), which is evaluated while the internal help database is built
(stages "build" and "install" and "render") and bakes the wall-clock time into
tools/help/tools.rdb (and hence .rdx). Prefer the value of SOURCE_DATE_EPOCH
when set (as done by e.g. Debian), falling back to Sys.time() otherwise so
upstream behaviour is preserved when it is not set. The 'render' stage is
evaluated only when the page is rendered, so it is left untouched.
Dirk Eddelbuettel <edd@debian.org> no 2026-10-14
no-rds-race Avoid race condition in saving per-package rds
Based on joint work with Kevin Ushey and Claude. Quoting from the analysis:

Difference:
"John M. Chambers (2008)\n``Software for Data Analysis: Programming with R''; Springer NY."
"John M. Chambers (2008) ``Software for Data Analysis:\nProgramming with R''; Springer NY."
The first is the source formatting from src/library/methods/DESCRIPTION.in. The second is
what you get after the field is re-wrapped at 72 columns by R's DESCRIPTION writer. The
mechanism is a timestamp race:

1. mkdesc runs .install_package_description, which writes the installed DESCRIPTION
through write.dcf (re-wrapping References), then immediately saves package.rds from the
original, unwrapped values read from the source file.
2. Later, src/library/Makefile.in:53 runs .vinstall_package_descriptions_as_RDS, which
regenerates package.rds from the installed DESCRIPTION unless package.rds is strictly
newer than it (file_test("-nt") at src/library/tools/R/admin.R:184).
3. The two files are written microseconds apart. Linux stamps files with a coarse clock
(one tick, ~4 ms), so their mtimes usually tie and the rds is regenerated with the wrapped
value. When a tick happens to land between the two writes, the rds is strictly newer and
keeps the unwrapped value. Both builds ran the same 6.12 kernel, so this is pure timing,
not a kernel variation.

I reproduced the re-wrap locally with R 4.6.1 by round-tripping every base package's
DESCRIPTION.in through the same read/write functions. Only two packages change: methods
(References, exactly as diffoscope shows) and tools (Suggests, which gets split before
mathjaxr). So tools/Meta/package.rds has the same exposure and will show up in some future
run even though it happened to match this time. All other base packages are unaffected
because their fields either fit in 72 columns or are in the keep-whitespace list.

Suggested fix. Make the regeneration unconditional so package.rds always comes from the
installed DESCRIPTION, regardless of mtime ties. This only affects the R source build, so
it is a safe Debian patch and a reasonable upstream proposal:
Dirk Eddelbuettel <edd@debian.org> no 2026-10-15

All known versions for source package 'r-base'

Links