[Rcpp-devel] LinkingTo: again
francoisromain at free.fr
Sun Dec 13 21:57:25 CET 2009
On 12/13/2009 09:39 PM, Dirk Eddelbuettel wrote:
> On 13 December 2009 at 21:06, Romain François wrote:
> | No, you don't need to do any of that. you can if you want (I think you
> | define what Matrix uses), but you don't have to. As far as I can see it,
> | adding "LinkingTo: foo" to the DESCRIPTION file just adds
> | -Isomewhere/foo/include so that you can then do #include<somefile.h>
> | where somefile.h is in the somewhere/foo/include directory.
> | This is it, no voodoo needed.
> Then that passes the _compile_ stage as you find headers and the blows up
> when the _linking_ stage finds no object code.
> Some voodoo needed, after all. ;-)
> [ That is, unless you're Whit Armstrong and you do everything in C++
> templates without object code. Rcpp will need -lRcpp to be found
> somewhere. ]
> I looked at what Martin had suggested and it is all C code. So no example
> there either.
This is what I've just realized when trying to make an example
(attached). now I understand your point.
Then I think this is a feature request for R-devel. Having LinkingTo C++
compatible if we follow the convention (yours) of :
- having a lib directory at the root of the installed package
- containing headers and and a shared object
then LinkingTo would add the -L, -l where appropriate.
Professional R Enthusiast
+33(0) 6 28 91 30 30
|- http://tr.im/HlX9 : new package : bibtex
|- http://tr.im/Gq7i : ohloh
`- http://tr.im/FtUu : new package : highlight
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 954 bytes
Desc: not available
Url : http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20091213/2f5fd4df/attachment.bin
More information about the Rcpp-devel