0

I have R 2.15.2 installed on Linux Red Hat 6.2 and I want install pROC package but I get an error related to Rcpp package. Then I tried to install Rcpp with no success. How can achieve that?. I already have installed the most recent version of EPEL (epel-release-6-8.noarch.rpm). Thanks!

> install.packages("pROC")
Installing package(s) into "/usr/lib64/R/library"

Warning: dependency "Rcpp" is not available
trying URL 'http://cran.parentingamerica.com/src/contrib/pROC_1.7.3.tar.gz'
Content type 'application/x-gzip' length 93082 bytes (90 Kb)
opened URL
==================================================
downloaded 90 Kb

* installing *source* package "pROC" ...
** package "pROC" successfully unpacked and MD5 sums checked
** libs
g++ -m64 -I/usr/include/R -DNDEBUG  -I/usr/local/include -I"/usr/lib64/R/library                                                     /Rcpp/include"   -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions                                                      -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c RcppExports.                                                     cpp -o RcppExports.o
RcppExports.cpp: In function "SEXPREC* pROC_delongPlacementsCpp(SEXPREC*)":
RcppExports.cpp:15: error: "input_parameter" is not a member of "Rcpp::traits"
RcppExports.cpp:15: error: expected primary-expression before ">" token
RcppExports.cpp:15: error: "::type" has not been declared
RcppExports.cpp:15: error: expected ";" before "roc"
RcppExports.cpp:16: error: "roc" was not declared in this scope
RcppExports.cpp: In function "SEXPREC* pROC_rocUtilsPerfsAllC(SEXPREC*, SEXPREC*                                                     , SEXPREC*, SEXPREC*)":
RcppExports.cpp:30: error: "input_parameter" is not a member of "Rcpp::traits"
RcppExports.cpp:30: error: expected primary-expression before ">" token
RcppExports.cpp:30: error: "::type" has not been declared
RcppExports.cpp:30: error: expected ";" before "thresholds"
RcppExports.cpp:31: error: "input_parameter" is not a member of "Rcpp::traits"
RcppExports.cpp:31: error: expected primary-expression before ">" token
RcppExports.cpp:31: error: "::type" has not been declared
RcppExports.cpp:31: error: expected ";" before "controls"
RcppExports.cpp:32: error: "input_parameter" is not a member of "Rcpp::traits"
RcppExports.cpp:32: error: expected primary-expression before ">" token
RcppExports.cpp:32: error: "::type" has not been declared
RcppExports.cpp:32: error: expected ";" before "cases"
RcppExports.cpp:33: error: "input_parameter" is not a member of "Rcpp::traits"
RcppExports.cpp:33: error: expected primary-expression before ">" token
RcppExports.cpp:33: error: "::type" has not been declared
RcppExports.cpp:33: error: expected ";" before "direction"
RcppExports.cpp:34: error: "thresholds" was not declared in this scope
RcppExports.cpp:34: error: "controls" was not declared in this scope
RcppExports.cpp:34: error: "cases" was not declared in this scope
RcppExports.cpp:34: error: "direction" was not declared in this scope
make: *** [RcppExports.o] Error 1
ERROR: compilation failed for package "pROC"
* removing "/usr/lib64/R/library/pROC"

The downloaded source packages are in
        "/tmp/RtmpGVsd3V/downloaded_packages"
Updating HTML index of packages in '.Library'
Making packages.html  ... done
Warning message:
In install.packages("pROC") :
  installation of package "pROC" had non-zero exit status
>
> install.packages("Rcpp")
Installing package(s) into "/usr/lib64/R/library"
(as "lib" is unspecified)
Warning message:
package "Rcpp" is not available (for R version 2.15.2)
>
> R.version
platform       x86_64-redhat-linux-gnu
arch           x86_64
os             linux-gnu
system         x86_64, linux-gnu
status
major          2
minor          15.2
year           2012
month          10
day            26
svn rev        61015
language       R
version.string R version 2.15.2 (2012-10-26)
nickname       Trick or Treat


[root@*********:~]$ lsb_release -a
LSB Version:    :core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Distributor ID: RedHatEnterpriseServer
Description:    Red Hat Enterprise Linux Server release 6.2 
MSS
  • 159

1 Answers1

1

Unfortunately, you are running a pretty outdated version of RHEL (I understand it is no longer supported) that comes with a pretty outdated version of R.

The current version of Rcpp requires R >= 3.0.0, which you don't have. Thus, you have two possibilities:

  1. You update your R installation to have at least R 3.0.0
  2. You install an old version of Rcpp
  3. You update your RHEL version.

Option 1 means downloading and compiling the latest version of R. If you choose option 2, you'll have to manually figure out which version of Rcpp supports R 2.15.2 (it appears to be the 0.10.5) and install it manually (R CMD INSTALL Rcpp-*.tar.gz).

I would recommend going with option 3.

Calimo
  • 1,425
  • Thank you for your answer. I didn't understand well, if Rcpp requires R 3.x, and R 3.x requires RHEL over 6.x, Do you suggest that I need to update from RHEL 6.2 to RHEL 7? – MSS Sep 26 '14 at 16:26
  • @MSS I don't know exactly what RHEL would come with R 3, but definitely yes, it would be a perfect occasion to upgrade your distro. – Calimo Sep 26 '14 at 19:11