Compile R on Mac OS X
Mac OS X
I did this before on my Macbook, but never documented. Wanted to document my attempt on the Mac virtual machine.
- Install Xcode (gcc/g++) and gfortran per this site.
- Download the R source file (2.12 in this example), and extract it.
./configure
did not work (Fortran issue). Per this, this, and this, I used:./configure --with-blas
'-framework vecLib' –with-lapack –with-aqua –enable-R-framework F77="gfortran -arch x86_64"= (the F77 is needed!).make
thensudo make install
.- Add
/Library/Frameworks/R.framework/Versions/Current/Resources/bin
toPATH
in~/.bashrc
.