[Rd] further f77/gfortran

Prof Brian Ripley ripley at stats.ox.ac.uk
Wed Jun 7 18:29:22 CEST 2006


On Wed, 7 Jun 2006, Dirk Eddelbuettel wrote:

>
> On 7 June 2006 at 11:44, Ben Bolker wrote:
> |   OK: despite Dirk's very kind help, I decided that
>
> Yeah, kind but still not useful to you. No cigar yet :)
>
> | trying to deal with R configuration and Debian configuration
> | simultaneously was too difficult.
>
> [ I'd still like to learn from useRs what I could do to make the Debian
> package more appealing. Local rebuilds seems natural to me; I do that eg on
> the Ubuntu boxen at work to combine 'stability' ('frozen' outer system) with
> 'current' apps where I need and what them. By keeping those within the
> package management framework, I feel I combine the best of two worlds. YMMV. ]
>
> |   I did manage to solve my problem by reconfiguring/making/
> | installing all of 2.3.1 from source:
> |
> | ./configure F77=/usr/bin/g77
> | make
> | make install
> |
> |    A few questions inspired by this experience:
> |
> |   (1) it seems a bit odd that R sets F77=gfortran
> | by default, since the system has both g77 and gfortran
> | compilers on it, and given that there is a separate
> | variable (FC) for the Fortran 90/95 compiler --
> | does it make any sense to switch
> | the search order in configure so that g77 comes up first if present?
> |
> |   (2) I couldn't figure out a way to set the F77 variable
> | on a per-package basis: adding a src/Makevars file or a configure
> | file to the package didn't seem to help, but perhaps I didn't
> | put it in the right place/get it exactly right.  Any clues?
>
> That came up recently:
>
> a)  ~/.Makevars  (as I recall)

~/.R/Makevars, but that applies to all packages on all builds.

> b)  on a per invocation basis:
> 	MAKEFLAGS="FFLAGS=-O1" R CMD INSTALL ...
>    is something that worked for me.

Yes, but it only works in some Makes, including GNU Make.

> That said, I personally still dislike that I cannot 'undo' the settings the
> R's global Makeconf.  I'd love to turn debugging, optimisation, ... on/off on
> demand.

It might make sense to separate CFLAGS, FFLAGS, CXXFLAGS, FCFLAGS out of 
etc/Makeconf into a Makefile included before Makevars.  But I am very 
reluctant to make it easy to change the F77 compiler or FLIBS or 
FPICFLAGS.

-- 
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