Compiling R Modules on FreeBSD

|

Installing modules for R can be tricky on FreeBSD due to differences between the compiler environment on FreeBSD and Linux. If the R module links against a third-party library, it is likely that the library will not be found without a bit off additional tweaking of the install command. On my FreeBSD 7.1 workstation, I have to use the following commands to install the GSL and Cairo R libraries, both of which link against external libraries. (They are wrappers to these libraries.)

Sys.setenv(MAKE="gmake") 
install.packages(c("gsl", "Cairo"), configure.args=c("CPPFLAGS=-I/usr/local/include", "LIBS=-L/usr/local/lib"))

It would be nice if this was supported out of the box in R, but if you know the solution it’s rather trivial to do.

About this Entry

This page contains a single entry by Reed A. Cartwright published on January 16, 2009 1:47 PM.

Problems and Solutions for Estimating Indel Rates and Length Distributions was the previous entry in this blog.

2008 College Football Rankings---Final is the next entry in this blog.

Find recent content on the main index or look in the archives to find all content.

Archives

Powered by Movable Type 4.37