Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error Installing minqa in R/3.0.2

Tags:

r

rscript

lme4

I am installing lme4 using the README.md file on their github account and I fail during installing the dependencies. I tried to install them separately and still crash at installing the minqa package. I'm using R/3.0.2 on RHEL6. During the build the compiler argues about RScript not existing which as I check it is in the R/bin folder.

Here is the log to the R INSTALL:

$ R CMD INSTALL minqa_1.2.2.tar.gz 
* installing to library ‘/gpfs/apps/x86_64-rhel6/R/3.0.2/R/library’
* installing *source* package ‘minqa’ ...
** package ‘minqa’ successfully unpacked and MD5 sums checked
** libs
gfortran   -fpic  -g -O2  -c altmov.f -o altmov.o
gfortran   -fpic  -g -O2  -c bigden.f -o bigden.o
gfortran   -fpic  -g -O2  -c biglag.f -o biglag.o
gfortran   -fpic  -g -O2  -c bobyqa.f -o bobyqa.o
gfortran   -fpic  -g -O2  -c bobyqb.f -o bobyqb.o
gfortran   -fpic  -g -O2  -c lagmax.f -o lagmax.o
g++ -I/gpfs/apps/x86_64-rhel6/R/3.0.2/R/include -DNDEBUG  -I/usr/local/include -I"/gpfs/apps/x86_64-rhel6/R/3.0.2/R/library/Rcpp/include"   -fpic  -g -O2  -c minqa.cpp -o minqa.o
gfortran   -fpic  -g -O2  -c newuoa.f -o newuoa.o
gfortran   -fpic  -g -O2  -c newuob.f -o newuob.o
gfortran   -fpic  -g -O2  -c prelim.f -o prelim.o
gfortran   -fpic  -g -O2  -c rescue.f -o rescue.o
gfortran   -fpic  -g -O2  -c trsapp.f -o trsapp.o
gfortran   -fpic  -g -O2  -c trsbox.f -o trsbox.o
gfortran   -fpic  -g -O2  -c trstep.f -o trstep.o
gfortran   -fpic  -g -O2  -c uobyqa.f -o uobyqa.o
gfortran   -fpic  -g -O2  -c uobyqb.f -o uobyqb.o
gfortran   -fpic  -g -O2  -c update.f -o update.o
gfortran   -fpic  -g -O2  -c updatebobyqa.f -o updatebobyqa.o
Rscript execution error: No such file or directory
g++ -shared -L/usr/local/lib64 -o minqa.so altmov.o bigden.o biglag.o bobyqa.o bobyqb.o lagmax.o minqa.o newuoa.o newuob.o prelim.o rescue.o trsapp.o trsbox.o trstep.o uobyqa.o uobyqb.o update.o updatebobyqa.o -lgfortran -lm -L/gpfs/apps/x86_64-rhel6/R/3.0.2/R/lib -lR
Rscript execution error: No such file or directory
installing to /gpfs/apps/x86_64-rhel6/R/3.0.2/R/library/minqa/libs
** R
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) : 
  unable to load shared object '/gpfs/apps/x86_64-rhel6/R/3.0.2/R/library/minqa/libs/minqa.so':
  /gpfs/apps/x86_64-rhel6/R/3.0.2/R/library/minqa/libs/minqa.so: undefined symbol: _ZTIN4Rcpp7RObjectE
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/gpfs/apps/x86_64-rhel6/R/3.0.2/R/library/minqa’
like image 259
HoofarLotusX Avatar asked Jan 15 '14 21:01

HoofarLotusX


1 Answers

A similar error also occurs when trying to upgrade lme4 from 1.0-5 to 1.0-6. The error message is something like:

Error in dyn.load(file, DLLpath = DLLpath, ...) :
  unable to load shared object '/usr/local/lib/R/site-library/minqa/libs/minqa.so':
  libRcpp.so: cannot open shared object file: No such file or directory
ERROR: lazy loading failed for package ‘lme4’

To resolve this install the packages in the order below:

install.packages('Rcpp')
install.packages('RcppEigen')
install.packages('minqa')
install.packages('lme4')

I guess it's related to RCpp; just upgrade the version from 0.10.6 to 0.11.0 and some ABI break change happens?

Credit from dmbates

like image 169
Eric Guo Avatar answered Sep 20 '22 01:09

Eric Guo