Fixing Rcpp warning in Mac OS
This article is originally published at https://www.quantumforest.com
In Mac OS I was getting an annoying warning when compiling Cpp code via Rcpp in R:
ld: warning: directory not found for option '-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin15/version_number'
Adding a file called Makevars
in ~/.R
defining FLIBS
to the actual location of gfortran in my machine fixed the problem. In my case, Makevars
only contains the following line:
FLIBS=-L/usr/local/gfortran/lib
That’s it.
Thanks for visiting r-craft.org
This article is originally published at https://www.quantumforest.com
Please visit source website for post related comments.