[R] sub-architecture installation difficulty with various valgrind-instrumentation levels

pleydell at supagro.inra.fr pleydell at supagro.inra.fr
Tue Aug 11 11:51:53 CEST 2009

"R Installation and Administration", section 2.5 "Sub-architectures" describes
calling specific builds of R using the call "R --arch=name". I am trying to
build and install three versions of R-2.9.1, each configured with a different
valgrind-instrumentation level ("Writing R Extensions", section 4.3.2 "Using
valgrind"). My goal is to be able to choose which install I launch so that I
can choose among the valgrind levels with commands such as

R --arch=valgrind0 -d valgrind --vanilla < myPkg.R
R --arch=valgrind1 -d valgrind --vanilla < myPkg.R
R --arch=valgrind2 -d valgrind --vanilla < myPkg.R

R-2.9.1.tar.gz is unzipped to /usr/local/src/R-2.9.1 and I have tried executing
the following code from that directory

sudo ./configure --enable-memory-profiling --with-valgrind-instrumentation=2
r_arch=vg2 --with-recommended-packages=no
sudo make
sudo make install rhome=/usr/local/lib/R-2.9.1_vg2

sudo ./configure --enable-memory-profiling --with-valgrind-instrumentation=1
r_arch=vg1 --with-recommended-packages=no
sudo make
sudo make install rhome=/usr/local/lib/R-2.9.1_vg1

sudo ./configure --enable-memory-profiling --with-valgrind-instrumentation=0
r_arch=vg0 --with-recommended-packages=no
sudo make
sudo make install rhome=/usr/local/lib/R-2.9.1_vg0

using this approach the second "sudo make" results in error.

I also tried installing from three seperate copies of the R-2.9.1 directory i.e.


with this set up the above code runs without error and the shell command "R
--arch=valgrind0" works (level zero being the level used in the most recent
install) but the shell commands "R --arch=valgrind1" and "R --arch=valgrind2"
result in error messages.

I have lost nearly 2 days trying various variations of the above, if someone
knows how I might get this to work I'd be most grateful. Perhaps a workable
example could be added to the "R Installation and Administration" document.

I am running a recent install of Ubuntu (Jaunty) on a 32 bit laptop with all
previous R installations removed / uninstalled.


More information about the R-help mailing list