[Rcpp-devel] basic usage help
    Vinh Nguyen 
    vinhdizzo at gmail.com
       
    Thu May 27 05:07:31 CEST 2010
    
    
  
On Wed, May 26, 2010 at 6:31 PM, Davor Cubranic <cubranic at stat.ubc.ca> wrote:
> On 2010-05-26, at 4:08 PM, Vinh Nguyen wrote:
>> Also, I didn't include BLAS or LAPACK linking -- still don't know how
>> to get the compilation flags easily.   I read the skeleton stuff but I
>> don't understand (sorry).
>
> Just put in your package's 'src' directory the Makevars file that's generated by RcppArmadillo's package.skeleton function. This is what it looks like on my machine:
>
> PKG_LIBS = $(shell $(R_HOME)/bin/Rscript -e "Rcpp:::LdFlags()" ) $(LAPACK_LIBS) $(BLAS_LIBS) $(FLIBS)
>
> How do you compile the code, by the way? It sounds like you do it by hand. Why not let R do it? With the above Makevars and the correct 'Depends' line in your package description (again, see the skeleton), you won't have to muck about with compiler switches and lookup paths, and everything should 'just work'.
>
> Davor
Yes, I'm doing it by hand since I'm still coding.  I compile after
some progress to make sure everything is OK.
Let's say I place the my code in in /src.  Do I HAVE to turn this into
a package in order to compile?  Or is there a way to compile from
here.  Sorry I'm new at this approach.
Thanks.
Vinh
    
    
More information about the Rcpp-devel
mailing list