Re: [Rd] Lapack calls from fortran

From: Douglas Bates <>
Date: Wed 22 Jun 2005 - 15:47:39 GMT

On 6/22/05, Paul Gilbert <> wrote:
> I am trying to call the lapack routine dgesv in the R distribution from
> the fortran code for a package, but when I dyn.load("") I get an
> error about undefined symbol: dgesv_
> I thought the proper incantation was
> MAKEFLAG="FLIBS=/path to/R-2.1.1/" R CMD SHLIB dse1.f
> but apparantly not. How does one do this?

See section 1.2.1 of "Writing R Extensions". You should add a file called Makevars to the src directory and include the line

PKG_LIBS = ${LAPACK_LIBS} ${BLAS_LIBS} in that file mailing list Received on Thu Jun 23 01:50:01 2005

This archive was generated by hypermail 2.1.8 : Mon 24 Oct 2005 - 22:27:21 GMT