I'm trying to install ranger package (any version) in Ubuntu 14 from a tar.gz 
file already downloaded, but unsuccessfully. System admin has already installed 
gcc 5.4 and g++ 5.4 and I've created a ~/.R/Makevars file pointing to these 
compilers instead of gcc 4.8 that comes in Ubuntu 14 by default.  Ranger 
requires gcc 4.9 or higher. That Makevars file looks like this:

CC=/storage/home/user/bin/gcc-5
CCXX=/storage/home/user/bin/g++-5
FC=/storage/home/user/bin/gfortran-6
F77=/storage/home/user/bin/gfortran-6

I don’t have admin rights and system admin can't change gcc path for the whole 
server. Output error is this one:

=========================================
* installing *source* package ârangerâ ...
** package ârangerâ successfully unpacked and MD5 sums checked
** libs
g++ -std=gnu++11 -I/usr/share/R/include -DNDEBUG -DR_BUILD 
-I"/storage/home/user/R/x86_64-pc-linux-gnu-library/3.4/Rcpp/include"    -fpic  
-g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time 
-D_FORTIFY_SOURCE=2 -g -c AAA_check_cpp11.cpp -o AAA_check_cpp11.o
g++: error: unrecognized command line option â-fstack-protector-strongâ
g++: error: unrecognized command line option â-Wdate-timeâ
/usr/lib/R/etc/Makeconf:168: recipe for target 'AAA_check_cpp11.o' failed
make: *** [AAA_check_cpp11.o] Error 1
ERROR: compilation failed for package ârangerâ
* removing â/storage/home/u382324/R/x86_64-pc-linux-gnu-library/3.4/rangerâ

The downloaded source packages are in
        â/tmp/RtmpXUQwl6/downloaded_packagesâ
Warning message:
In install.packages("ranger") :
  installation of package ârangerâ had non-zero exit status
==============================================

It seems I’m missing some flag defintion in my Makevars and R is using the 
default gcc 4.8 compiler, I don’t know. Any advice about how to procceed would 
be very helpful. Thanks.

Kind regards,

Ivan

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to