[Rcpp-devel] Question regarding new pacakge registration requirements
Tim Keitt
tkeitt at utexas.edu
Thu Mar 30 22:06:30 CEST 2017
On Thu, Mar 30, 2017 at 2:55 PM, Avraham Adler <avraham.adler at gmail.com>
wrote:
> If so, do I add
> them asa regards the functions *I* wrote in lamw.cpp or as regards the
> function wrappers that Rcpp wrote and the .R files call in
> RcppExports.R?
>
I'm a bit confused about this as well. My impression is that the only
reason to register functions is so that *other* packages can call them. If
you do not want to make them available, you don't need to register them. Or
I could have that complete wrong.
THK
If you don't want to register anything, this snippet placed in init.c will
get you past CRAN checks currently:
#include <R.h>
#include <Rinternals.h>
#include <R_ext/Rdynload.h>
R_CallMethodDef callMethods[] = {{NULL, NULL, 0}};
R_CMethodDef cMethods[] = {{NULL, NULL, 0}};
void
R_init_myLib(DllInfo *info)
{
R_registerRoutines(info, cMethods, callMethods, NULL, NULL);
R_useDynamicSymbols(info, FALSE);
}
http://www.keittlab.org/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20170330/32c5c920/attachment.html>
More information about the Rcpp-devel
mailing list