Compiling R from source in /opt/R

Thanks @alexv. I think that is something we will explore as we build a process around deploying multiple R versions.

One final twist on this project was that once we compiled from source and removed the system R, images failed to be produced on Connect. Long story short, in RHEL, R will try to use X11 to generate graphics instead of Cario no matter what your compilation arguments are (we tried --without-x and the issue persisted).

The solution is to either yum install pango-devel OR edit your /etc/rprofile.site file and insert this option:

options(bitmapType='cairo')

This forces R to use Cairo no matter how the R version is compiled. I haven't tested it, but I suspect this same problem would exist using MRAN builds.

2 Likes