blJOg
blJOg

Reputation: 461

Error while installing Rmpfr on Ubuntu

I am trying to install the R package Rmpfr on Linux Ubuntu and I get the following error message:

*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) : 
  unable to load shared object '/usr/local/lib/R/site-library/Rmpfr/libs/Rmpfr.so':
  libmpfr.so.4: cannot open shared object file: No such file or directory
Error: loading failed
Execution halted
ERROR: loading failed

I am already aware that similar questions have been asked, but the error message is different and I have tried the suggestion on this post: In R, using Ubuntu, try to install a lib depending on GMP C lib, it won't find GMP, but I have GMP installed

Upvotes: 1

Views: 1875

Answers (1)

Dirk is no longer here
Dirk is no longer here

Reputation: 368351

Do you have the libmpfr4 and libmpfr-dev packages installed?

edd@max:~$ COLUMNS=90 dpkg -l | grep mpfr | cut -c-80
ii  libmpfr-dev:amd6 3.1.1-2       amd64         multiple precision floating-poi
ii  libmpfr4:amd64   3.1.1-2       amd64         multiple precision floating-poi
edd@max:~$ 

You need both libmpfr4 and libmpfr-dev. I am fairly certain that your build failed before the line you showed because 'cannot load' due to a lack of library suggests that the linking, and possibly compilation failed.

You are installing from the Rmpfr source package, correct?

Upvotes: 4

Related Questions