[R-pkg-devel] Reproducing CRAN checks
Dirk Eddelbuettel
edd @end|ng |rom deb|@n@org
Fri Sep 5 00:08:35 CEST 2025
On 4 September 2025 at 21:30, Pepijn de Vries wrote:
| when not found. 3) "Could not find the required static library BLOSC"
| Here Prof. Ripley implies that blosc is not static on Linux. I don't think this is
| the case. So I'm not sure how to proceed with this.
What is your system / your reference? "Here" on Ubuntu libblosc* is set up
like thousands of other libraries: the shared library in the run-time
package, the static library in the -dev package.
Your build picks up the shared library as we'd expect:
$ ldd /usr/local/lib/R/site-library/blosc/libs/blosc.so | grep blosc
libblosc.so.1 => /lib/x86_64-linux-gnu/libblosc.so.1 (0x00007f4b56501000)
$
To pick just one other package with compressors libraries:
$ ldd /usr/local/lib/R/site-library/zip/libs/zip.so | grep 'lib.*z'
libzstd.so.1 => /lib/x86_64-linux-gnu/libzstd.so.1 (0x000078af0e90f000)
liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x000078af0e8cf000)
libbz2.so.1.0 => /lib/x86_64-linux-gnu/libbz2.so.1.0 (0x000078af0e8bb000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x000078af0e89d000)
$
Now, it has become a little 'fashionable' to ship libraries with their CRAN
package and embed them, but the default is still to rely on established
system libraries:
$ ldd /usr/local/lib/R/site-library/RPostgreSQL/libs/RPostgreSQL.so | grep libpq
libpq.so.5 => /lib/x86_64-linux-gnu/libpq.so.5 (0x000071fe7fc53000)
$ ldd /usr/local/lib/R/site-library/RPostgres/libs/RPostgres.so | grep libpq
libpq.so.5 => /lib/x86_64-linux-gnu/libpq.so.5 (0x000072e718fd6000)
$
Maybe Prof Ripley wanted you to play along the common theme of relying on an
external shared library? For libblosc the default (as seen from `pkgconf`
aka `pkg-config`) appears to be standard linking just as we saw above:
$ pkgconf --libs blosc
-lblosc
$
Hope this helps, Dirk
--
dirk.eddelbuettel.com | @eddelbuettel | edd using debian.org
More information about the R-package-devel
mailing list