Problems installing the R package amap in a Mac 10.9.5

767 views Asked by At

I am trying to install the package amap in R to do some parallel distance matrix calculations.

I run:

 install.packages("amap", dependencies = TRUE)

and I get this error:

make: gfortran-4.8: No such file or directory
make: *** [pop.o] Error 1
ERROR: compilation failed for package ‘amap’
* removing ‘/Users/javier/Library/R/3.1/library/amap’

However, gfortran-4.8 is installed in my computer:

gfortran -v
Using built-in specs.
COLLECT_GCC=gfortran
COLLECT_LTO_WRAPPER=/usr/local/gfortran/libexec/gcc/x86_64-apple-darwin13/4.8.2/lto-wrapper
Target: x86_64-apple-darwin13
Configured with: ../gcc-4.8.2/configure --prefix=/usr/local/gfortran --with-gmp=/Users/fx/devel/gcc/deps-static/x86_64 --enable-languages=c,c++,fortran,objc,obj-c++ --build=x86_64-apple-darwin13
Thread model: posix
gcc version 4.8.2 (GCC) 

I read somewhere here that a way around is typing the following in the .bash_source

alias fixrs="launchctl setenv PATH /usr/texbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin"

And then execute fixrs in the terminal. I use .tcshrc so I typed

alias fixrs launchctl setenv PATH /usr/texbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin 

on my .tcshrc, and execute the fixrs command in the terminal before launching RStudio or the R Console and I keep getting the same error (also mentioning that I have also tried change to bash, generate a .bash_profile include the command and the lunch RStudio and the result was the same).

should the comment be placed in a specific part of the .tcshrc file? is my bash to tcshrc translation wrong? I have also tried alias fixrs "launchctl setenv PATH /usr/texbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin"

Anyway, at this stage I don't really know how to proceed to simply install amap. Does anyone know how to solve this issue?

0

There are 0 answers