After upgrading to Ubuntu 24.04, library(sf) wasn’t happy:
libgdal.so.33: cannot open shared object file: No such file or directory
Often, the solution lies in installing the relevant library using apt, but this time it was no longer available after the upgrade. So re-installing library sf only led to an error.
I recalled r2u, and indeed it was up-to-date to work with Ubuntu 24.04. After setting this up, I could install r-cran-sf as a binary, and it still didn’t work. Rather than fiddling with the paths, I removed gdal-bin and r-cran-sf, re-installed r-cran-sf. It worked.