From jeroen.ooms at stat.ucla.edu  Tue Oct 18 12:55:38 2016
From: jeroen.ooms at stat.ucla.edu (Jeroen Ooms)
Date: Tue, 18 Oct 2016 12:55:38 +0200
Subject: [Rd] Cluster: Various GCC, how important is consistency?
In-Reply-To: <CAErODj-6d83ObMb3u0CMXd_-J0A6nbom2HOVTuaV=R1DqZw5+A@mail.gmail.com>
References: <CAErODj-6d83ObMb3u0CMXd_-J0A6nbom2HOVTuaV=R1DqZw5+A@mail.gmail.com>
Message-ID: <CABFfbXsuMCizgN6enRr590fN9+XimeJYLEB8uY=5qYWcNXE+GQ@mail.gmail.com>

On Tue, Oct 18, 2016 at 1:44 AM, Paul Johnson <pauljohn32 at gmail.com> wrote:
>
> Administrator suggested I try to build with the GCC that is provided
> with the nodes, which is gcc-4.4.7.

Redhat provides an alternative compiler (gcc 5.3 based) in one of it's
opt-in repositories called "redhat developer toolkit" (RDT). In CentOS
you install it as follows:

  yum install -y centos-release-scl
  yum install -y devtoolset-4-gcc-c++

This compiler is specifically designed to be used alongside the EL6
stock gcc 4.4.7. It includes a simple 'enable' script which will put
RDT gcc and g++ in front of your PATH and LD_LIBRARY_PATH and so on.

So what I do on CentOS is install R from EPEL (built with stock gcc
4.4.7) and whenever I need to install an R package that uses e.g.
CXX11, simply start an R shell using the RDT compilers:

   source /opt/rh/devtoolset-4/enable
   R

>From what I have been able to test, this works pretty well (though I
am not a regular EL user). But I was able to build R packages that use
C++11 (such as feather) and once installed, these packages can be used
even in a regular R session (without RDT enabled).



[Rd] Cluster: Various GCC, how important is consistency?
Jeroen Ooms