Rcpp warning: “directory not found for option '-L/usr/local/Cellar/gfortran/4.8.2/gfortran'”

后端 未结 2 885
梦谈多话
梦谈多话 2020-12-05 20:48

This question relates to some others out there, like RccpArmadillo or element-wise-multiplication.

However, my settings are such that I do not know what I have to ed

2条回答
  •  长情又很酷
    2020-12-05 21:47

    A small tweak to the answer from @kevin-ushey (that at least I needed; I use Prezto) was adding single quotes to grep '^libraries:', resulting in:

    FLIBS=`gfortran -print-search-dirs | grep '^libraries:' | sed 's|libraries: =||' | sed 's|:| -L|g' | sed 's|^|-L|'`
    

    Adding that line to my ~/.R/Makevars file did the trick!

提交回复
热议问题