16

I am trying to install package , circular, I get the below error during the installation.

enter image description here

I tried a few option that were suggested in a few posts but it didn't work. I also tried loading other packages such as spatstat and this error doesn't occur while doing that.

Could anyone please assist me in resolving this issue.

DYZ
  • 55,249
  • 10
  • 64
  • 93
RBK
  • 375
  • 2
  • 5
  • 12

2 Answers2

32

You need a Fortran compiler to compile certain R packages. Install it with:

sudo apt-get install gfortran
DYZ
  • 55,249
  • 10
  • 64
  • 93
16

The general idea is to install the (virtual) package r-base-dev:

Depends: r-base-core (>= 3.2.5-1xenial), build-essential, gcc, g++,
    gfortran, libblas-dev | libatlas-base-dev, 
    liblapack-dev | libatlas-base-dev, libncurses5-dev, 
    libreadline-dev, libjpeg-dev, libpcre3-dev, libpng-dev, 
    zlib1g-dev, libbz2-dev, liblzma-dev, cdbs
Suggests: debhelper, texlive-base, texlive-latex-base, 
    texlive-generic-recommended, texlive-fonts-recommended, 
    texlive-fonts-extra, texlive-extra-utils, 
    texlive-latex-recommended, texlive-latex-extra, texinfo

which groups a number of things you need for package building. Including, as you can see, the Fortran compiler.

Dirk Eddelbuettel
  • 360,940
  • 56
  • 644
  • 725