[R-pkg-devel] Validate CRAN package using a linked library

Dirk Eddelbuettel edd at debian.org
Wed Sep 14 22:02:27 CEST 2016


On 14 September 2016 at 12:52, Dorel, Mathurin wrote:
| I developed a package using the symbolic calculus C library ginac (http://www.ginac.de/<https://email.charite.de/owa/redir.aspx?REF=fSvQ3yE_XkDlPenE4F0MzYwBnO23griAuHvI5OZfSugms-XfndzTCAFodHRwOi8vd3d3LmdpbmFjLmRlLw..>).
| I want to submit my package to CRAN, but the library is not installed on CRAN computers
| so the C/C++ code does not compile on CRAN winbuilder (http://win-builder.r-project.org/upload.aspx<https://email.charite.de/owa/redir.aspx?REF=KMGXFEO-FDxPH92uJokI4LhZLoWd8IY1gdu9k7Wswrcms-XfndzTCAFodHRwOi8vd2luLWJ1aWxkZXIuci1wcm9qZWN0Lm9yZy91cGxvYWQuYXNweA..>).
| 
| What would be an appropriate solution? Should I ask the CRAN administrators to install ginac on
| their test machines, or should I submit a source package in the style of BH which would provided
| a compiled version of the ginac library that I could link to?

Note that BH is _headers-only_ and hence works by LinkingTo: (which despite
its name is NOT used for linking)  which covers "most" of the Boost
functionality (but eg not Boost graph used in RBGL on BioC).

In general the problem you describe is "hard". See Writing R Extensions, and
use of SystemRequirements, plus possibly use of configure to detect library
presence at the compile-time of you package.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org



More information about the R-package-devel mailing list