Skip to content
Prev 11207 / 12125 Next

[R-pkg-devel] Rcpp: how best to include source from another Github repository

There is balance between DRY, safety, and customization needs. The
symlinkish approach would be "dangerous" imo, because you can't guarantee
the wrapper.cpp will stay compatible with changes in the underlying C++
library.

The submodule approach works well. Alternatives that I know of are:


   - a script that pulls the latest sources in the standalone C++ library
   and does things like adding a preprocessor macro, see e.g. rvinecopulib
   - a "patches" folder with patch files in diff format (.patch or .diff),
   see e.g. RcppEigen

Either way, such scripts or patches folders have to be excluded from being
put into the package via the .Rbuildignore.

On Wed, Jan 22, 2025, 2:33?PM John Clarke <john.clarke at cornerstonenw.com>
wrote: