[Rd] compiling R from source with a catch!

Anwar Ludin anwar.ludin at riskcetera.com
Wed Jun 26 12:05:33 CEST 2013


Professor Ripley,

Thank your for pointing me in the right direction. I will start by reading the manual ;)
From what I can see the least painful way is still to use a fortran compiler, so I will try to get my hands on the intel fortran compiler and cross compile to MIC.

Thanks!

Anwar


On Jun 26, 2013, at 10:47 AM, Prof Brian Ripley <ripley at stats.ox.ac.uk> wrote:

> On 25/06/2013 22:54, Anwar Ludin wrote:
>> I need to rebuild an R interpreter for the Intel Xeon Phi coprocessor which can be considered as an embedded system.
>> 
>> My only option is to use the intel compiler tools and cross compile the interpreter. My first stumbling block is that I don't have a fortran cross compiler and I would like to know if it's possible to build a minimal R system
>> without the need of a  fortran compiler.
> 
> No.  But it is possible to use f2c as a substitute Fortran compiler. This was tested just prior to the release of R 3.0.0 to demonstrate that R could be built using just 'clang'.
> 
>> At the moment I've used the following options with the configure script:
>> 
>> ./configure --host=x86_64 --enable-R-static-lib CXX=icpc CC=icc CFLAGS=-mmic CXXFLAGS=-mmic LDFLAGS=-mmic --with-readline=no --without-recommended-packages
>> 
>> icpc and icc are the intel compilers.
>> -mmic tells the compiler to cross compile for the Intel Xeon Phi.
>> 
>> The configure script stops with the following error:
>> 
>> checking for dummy main to link with Fortran 77 libraries... none
>> checking for Fortran 77 name-mangling scheme... unknown
>> configure: WARNING: unknown Fortran name-mangling scheme
>> checking whether gfortran appends underscores to external names... unknown
>> configure: error: cannot use Fortran
>> 
>> Do I actually need Fortran in order to build the R interpreter?
>> 
>> Any suggestions on how to move forwards would be greatly appreciated!
> 
> Suggestion: study the manual.  To quote the INSTALL file
> 
> 'The main source of information on installation is the `R Installation
> and Administration Manual', an HTML copy of which is available as file
> `doc/html/R-admin.html'.  Please read that before installing R.  But
> if you are impatient, read on but please refer to the manual to
> resolve any problems.'
> 
> It supplies some important information if you use f2c.
> 
> -- 
> Brian D. Ripley,                  ripley at stats.ox.ac.uk
> Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
> University of Oxford,             Tel:  +44 1865 272861 (self)
> 1 South Parks Road,                     +44 1865 272866 (PA)
> Oxford OX1 3TG, UK                Fax:  +44 1865 272595



More information about the R-devel mailing list