[R-SIG-Mac] Problems with R CMD config

Prof Brian Ripley ripley at stats.ox.ac.uk
Thu Sep 1 09:46:16 CEST 2016

On 01/09/2016 00:43, Ken Beath wrote:
> I’m trying to use STAN which uses R CMD config to check the availability of the compilers.
> This works fine on my MacBook but on my iMac I have the documents on a separate hard drive. Within R CMD config it uses the location of the home  folder which because of my choice of name of hard drive has a space in it, and that causes problems with the batch file. In the following the volume should be Ken Main.
> Kens-iMac:~ kjbeath1$ R CMD config CXX
> make: /Volumes/Ken: No such file or directory
> make: *** No rule to make target `/Volumes/Ken'.  Stop.
> For those who are wondering why I don’t just change the name, this produces problems with other software.
> Any ideas on a solution?

Edit the script config.

We have nothing to reproduce here (what is your home directory?), but I 
am guessing that in

     elif test -f "${HOME}/.R/Makevars-${R_PLATFORM}"; then
       makefiles="${makefiles} -f ${HOME}/.R/Makevars-${R_PLATFORM}"
     elif test -f "${HOME}/.R/Makevars"; then
       makefiles="${makefiles} -f ${HOME}/.R/Makevars"

you need \"${HOME}\" twice.

Or set R_MAKEVARS_USER to a path without spaces.

Brian D. Ripley,                  ripley at stats.ox.ac.uk
Emeritus Professor of Applied Statistics, University of Oxford

More information about the R-SIG-Mac mailing list