[Rd] R CMD check error with the GNU Scientific Library

pleydell at supagro.inra.fr pleydell at supagro.inra.fr
Fri Jan 22 18:37:58 CET 2010


> You'll need something like :
>
> PKG_LIBS=-lgsl -lgslcblas
>
> in your Makevars.
>
> This is from package gsl (on CRAN).

Of course! That makes sense 'cause I was already compiling using

MAKEFLAGS="CFLAGS=-g -O0" R CMD SHLIB sharka.c -lgsl -lgslcblas

and including the above line in Makevars has done the job, great!!

I was copying QRMlib and not the gsl package since the former includes 
.h files
while the later uses .c files. I have a binary and not source installation of
gsl (not the R package) and so .h files were more readily accessible to me. I
wonder about the pros / cons of using .c vs. .h in an R package and how QRMlib
was compiled without the above line in Makevars.

Thanks for your help
David



More information about the R-devel mailing list