Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] Rmpi installation issues
From: Simone Giannerini (sgiannerini_at_[hidden])
Date: 2008-10-13 09:56:19

Dear Dirk,

many thanks for your reply, please see below,

On 13 October 2008 at 11:22, Simone Giannerini wrote:
| Dear all,
| I have troubles installing rmpi 0.5-5 (or 0.5-6) on a quad opteron machine

| with OpenSUSE 11.0 and
| R 2.7.2
| platform x86_64-unknown-linux-gnu
| arch x86_64
| os linux-gnu
| system x86_64, linux-gnu
| status Patched
| major 2
| minor 7.2
| year 2008
| month 09
| day 18
| svn rev 46546
| language R
| version.string R version 2.7.2 Patched (2008-09-18 r46546)
| I tried the following
| # export MPI_ROOT=/usr/lib64/mpi/gcc/openmpi/
| # R CMD INSTALL Rmpi_0.5-6.tar.gz

Where did you get 0.5-6 from? The newest, per the author's website, is

| * Installing to library '/usr/local/lib64/R/library'
| * Installing *source* package 'Rmpi' ...
| checking for gcc... gcc
| checking for C compiler default output file name... a.out
| checking whether the C compiler works... yes
| checking whether we are cross compiling... no
| checking for suffix of executables...
| checking for suffix of object files... o
| checking whether we are using the GNU C compiler... yes
| checking whether gcc accepts -g... yes
| checking for gcc option to accept ISO C89... none needed
| Try to find mpi.h ...
| Found in /usr/lib64/mpi/gcc/openmpi//include
| Try to find or libmpich.a
| checking for main in -lmpi... yes

At this point you have mpi.h and libmpi. Looks good.

| checking for openpty in -lutil... yes
| checking for main in -lpthread... yes
| configure: creating ./config.status
| config.status: creating src/Makevars
| ** libs
| gcc -std=gnu99 -I/usr/local/lib64/R/include -DPACKAGE_NAME=\"\"
| -DPACKAGE_BUGREPORT=\"\" -I/usr/lib64/mpi/gcc/openmpi//include -DMPI2
| -DOPENMPI -fPIC -I/usr/local/include -fpic -g -O2 -c RegQuery.c -o
| RegQuery.o
| gcc -std=gnu99 -I/usr/local/lib64/R/include -DPACKAGE_NAME=\"\"
| -DPACKAGE_BUGREPORT=\"\" -I/usr/lib64/mpi/gcc/openmpi//include -DMPI2
| -DOPENMPI -fPIC -I/usr/local/include -fpic -g -O2 -c Rmpi.c -o Rmpi.o
| gcc -std=gnu99 -I/usr/local/lib64/R/include -DPACKAGE_NAME=\"\"
| -DPACKAGE_BUGREPORT=\"\" -I/usr/lib64/mpi/gcc/openmpi//include -DMPI2
| -DOPENMPI -fPIC -I/usr/local/include -fpic -g -O2 -c conversion.c -o
| conversion.o
| gcc -std=gnu99 -I/usr/local/lib64/R/include -DPACKAGE_NAME=\"\"
| -DPACKAGE_BUGREPORT=\"\" -I/usr/lib64/mpi/gcc/openmpi//include -DMPI2
| -DOPENMPI -fPIC -I/usr/local/include -fpic -g -O2 -c internal.c -o
| internal.o

It all compiles, thanks to mpi.h.

| gcc -std=gnu99 -shared -L/usr/local/lib64 -o RegQuery.o Rmpi.o
| conversion.o internal.o -L/usr/lib64/mpi/gcc/openmpi//lib -lmpi -lutil
| -lpthread -fPIC
| /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../x86_64-suse-linux/bin/ld:

| cannot find -lmpi
| collect2: ld returned 1 exit status
| make: *** [] Error 1
| chmod: cannot access `/usr/local/lib64/R/library/Rmpi/libs/*': No such
| or directory
| ERROR: compilation failed for package 'Rmpi'
| ** Removing '/usr/local/lib64/R/library/Rmpi'

This seems to indicate that your installation of Open MPI conflicts with
setting of
        export MPI_ROOT=/usr/lib64/mpi/gcc/openmpi/
as this directory is expected to contain include/ and lib/

I am not sure I got this, Open MPI is installed in
/usr/lib64/mpi/gcc/openmpi/ and such directory contains both include and lib

gauss:/usr/lib64/mpi/gcc/openmpi # ls -R
bin include lib64 share

mpiCC mpicc mpiexec mpif90 mpivars.csh ompi_info opalc++
ortec++ orted
mpic++ mpicxx mpif77 mpirun opal_wrapper opalcc
ortecc orterun

mpi.h mpif-common.h mpif-config.h mpif.h openmpi

ompi opal opal_config_bottom.h orte
ompi_config.h opal_config.h opal_stdint.h orte_config.h



| I also tried with
| R CMD INSTALL Rmpi_0.5-6.tar.gz
| --configure-args=--with-mpi=/usr/lib64/mpi/gcc/openmpi/
| with the same results.
| Any help would be greatly appreciated.
I'd recommend having a look at, which is pretty
and 'helping' it with the locations you have. I had to do the same for
Debian's Rmpi due to use also having mpich and lam.

Please, could you be more explicit? Thanks, I tried to modify line 8 of the
file without success. BTW I had also LAM and mpich installed
but I removed them.

Thank you for your help,

Kind regards