Skip to content
Prev 25292 / 63424 Next

Question about Running C code from R

Since you are using Borland C++, the examples in the online complement to 
'S Programming' are relevant, as is README.packages.

Basically, you have not managed to export any entry points, and to do so 
you will need to make a DLL and not a .exe.

*However* it is much easier to make use of the MinGW compiler used to make 
R.

You are trying too hard using getNativeSymbolInfo etc, and R CMD INSTALL 
does work under Windows.

I would study 'Writing R Extensions' and 'R Installation and 
Administration Manual', install MinGW and use

R CMD SHLIB

to make a DLL.  It really is a lot easier to follow a well-trodden path
than to create your own.  (In Roger Bivand's analogy: you need stepping 
stones across this morass/mire/bog.)
On Fri, 8 Jun 2007, Marthews, T. R. wrote: