<div dir="ltr">You need to link to GSL as well. RcppGSL provides the appropriate flags within `RcppGSL::LdFlags()`. See what RcppGSL does itself in its configure scripts: <a href="https://github.com/eddelbuettel/rcppgsl/blob/2849b8dd777c8057e524c2141dfeaa8e28840350/inst/skeleton/configure.win">https://github.com/eddelbuettel/rcppgsl/blob/2849b8dd777c8057e524c2141dfeaa8e28840350/inst/skeleton/configure.win</a>.<div><br></div><div>Kevin<br><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 5, 2015 at 2:08 PM, Fabio Tordini <span dir="ltr"><<a href="mailto:tordini@di.unito.it" target="_blank">tordini@di.unito.it</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Ok, I found the 'scrm' Rcpp package: here the file scrmr.cpp provides an interface for calling the scrm C++ application from R. following their solution, I modified my Makevars file, adding:<br>
<br>
OBJECTS.PnuChart = ngraph.o RcppExports.o<br>
OBJECTS.PnuChart = PnuChart/Finder.o<br>
OBJECTS = $(OBJECTS.PnuChart)<br>
<br>
Now the linker finds the object files and knows where functions "are". so, previous error is solved.<br>
<br>
but loading still fails with the following message:<br>
<br>
 /home/fabio/R/x86_64-pc-linux-gnu-library/3.0/NgrapH/libs/NgrapH.so: undefined symbol: gsl_vector_alloc<br>
Error: loading failed<br>
<br>
In fact, I do use gsl, that's why I added RcppGSL in the DESCRIPTION file at 'LinkingTo'. Also, I use the attribute<br>
'// [[Rcpp::depends(RcppGSL)]]' in those headers where GSL functions are used, and included <RcppGSL.h>. I do not export those functions because they're not called directly from R.<br>
<br>
still, I get the loading failed error.<span class="HOEnZb"><font color="#888888"><br>
<br>
<br>
Fabio</font></span><span class="im HOEnZb"><br>
<br>
<br>
<br>
<br>
<br>
On 05/05/2015 10:15 PM, Dirk Eddelbuettel wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
On 5 May 2015 at 16:28, Fabio Tordini wrote:<br>
| Here is the actual (simple) code:<br>
|<br>
|       Finder *f = new Finder();<br>
|       f->parseFiles(str_g, str_f, str_s);<br>
<br>
So where is Finder implemented?<br>
<br>
The computer tells you that you want to use it, but don't supply it.<br>
<br>
Dirk<br>
<br>
</blockquote></span><div class="HOEnZb"><div class="h5">
_______________________________________________<br>
Rcpp-devel mailing list<br>
<a href="mailto:Rcpp-devel@lists.r-forge.r-project.org" target="_blank">Rcpp-devel@lists.r-forge.r-project.org</a><br>
<a href="https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel" target="_blank">https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel</a><br>
</div></div></blockquote></div><br></div>