Hi Uwe,
Thank you, I have a series of cc files that use similar function names, so to
avoid overriding functions, I thought to compile and load each of the cc files
separately. In more detail, I have a series of models for the use in deSolve,
they all have the same initmod and derivs internal functions. See 2.2 section:
https://cran.r-project.org/web/packages/deSolve/vignettes/compiledCode.pdf
I realised I need to define the makevars file, but I don't know where to start,
would you be able to advise on how to structure the makevars file?
Best,
M.
On May 05, 2017, at 09:26 AM, Uwe Ligges <lig...@statistik.tu-dortmund.de>
wrote:
Why do you want to build separate dll files if you want to load all of
them anyway? That way you add some overhead, at least.
From Writing R Extensions:
"A few packages use the src directory for purposes other than making a
shared object (e.g. to create executables). Such packages should have
files src/Makefile and src/Makefile.win (unless intended for only
Unix-alikes or only Windows)."
Best,
Uwe Ligges
On 04.05.2017 17:09, Mark wrote:
Hi,
I am creating an R package with multiple c files within src directory.
If possible, I would like to create separate dll files for each c file.
Also I would like those dll files to have the same name as the input c
files. i.e:
mod01.c -o mod01.dll
mod02.c -o mod02.dll
mod03.c -o mod03.dll
...
I could then load different dll files in the NAMESPACE:
useDynLib("mod01")
useDynLib("mod02")
useDynLib("mod03")
...
I don't know how can I set the MAKEVARS to do this correctly, and any
suggestions would be much appreciated.
Mark
______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel
______________________________________________
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel