[Rcpp-devel] question re: LdFlags, RcppLdFlags

Kevin Ushey kevinushey at gmail.com
Tue Oct 8 23:46:09 CEST 2013


In previous versions of Rcpp, we typically constructed the PKG_LIBS
variable in Makevars through

    PKG_LIBS = `$(R_HOME)/bin/Rscript -e "Rcpp:::LdFlags()"`

This is also what's done in e.g. Rcpp.package.skeleton. However, following
the new guidelines from CRAN, RcppLdFlags was exported, but not LdFlags. I
wonder if the intention was to export LdFlags as well, so that we can
simply omit one colon from the LdFlags call:

    PKG_LIBS = `$(R_HOME)/bin/Rscript -e "Rcpp::LdFlags()"`

As is, because RcppLdFlags was exported and returns its result invisibly,
it's required to write e.g.

    PKG_LIBS = `$(R_HOME)/bin/Rscript -e "cat(Rcpp::RcppLdFlags())"`

which is a bit uglier.

Can we have LdFlags exported in addition to RcppLdFlags? It would also help
keep everything consistent with the available documentation.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20131008/9b11ee2b/attachment.html>

More information about the Rcpp-devel mailing list