[R-sig-hpc] Problems Installing Rmpi

Hao Yu hyu at stats.uwo.ca
Tue May 12 15:51:42 CEST 2009


Can you change configure.ac with
###################################
AC_INIT(DESCRIPTION)

AC_PROG_CC

AC_ARG_WITH(mpi,
[   --with-mpi=/opt/lib32/usr/lib          Location of MPI library.],
[   if test "${withval}" != no; then
        MPI_ROOT=${withval}
        MPI_INCLUDE="-I${MPI_ROOT}/include"
        LDFLAGS="$LDFLAGS -L${withval}/lib"
        CFLAGS="$CFLAGS -I${withval}/include"
    fi  ]
)
MPITYPE="OPENMPI"
MPI_DEPS="-DMPI2"
AC_CHECK_LIB(util, openpty, [ MPI_LIBS="$MPI_LIBS -lutil" ])
AC_CHECK_LIB(pthread, main, [ MPI_LIBS="$MPI_LIBS -lpthread" ])

PKG_LIBS="${MPI_LIBS} -fPIC"
PKG_CPPFLAGS="${MPI_INCLUDE} ${MPI_DEPS} -D${MPITYPE} -fPIC"

AC_SUBST(PKG_LIBS)
AC_SUBST(PKG_CPPFLAGS)
AC_SUBST(DEFS)

AC_OUTPUT(src/Makevars)
###################################
Then, run "autoconf" to generate a new "configure" file. Use build to
build a new tgz file and install again.

If you look the original configure.ac, there is no place where mpi.h is
appended to ${MPI_INCLUDE}. I don't know why the OS does such a way.

Hao

Rick B. wrote:
>
> On Mon, 2009-05-11 at 10:00 -0400, Hao Yu wrote:
>> I am not so sure why Rmpi script doesn't supply include dir. Can you try
>> R CMD INSTALL Rmpi_0.5-7.tar.gz
>> --configure-args=--with-mpi=/usr/lib64/openmpi/1.2.7-gcc
>>
>> Hao
>>
>
>
> Would it be better to use mpich instead of openmpi? I could not get lam
> to run under CentOS 5.3.
>
> Thanks.
>
> Rick
>
> _______________________________________________
> R-sig-hpc mailing list
> R-sig-hpc at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-hpc
>


-- 
Department of Statistics & Actuarial Sciences
Fax Phone#:(519)-661-3813
The University of Western Ontario
Office Phone#:(519)-661-3622
London, Ontario N6A 5B7
http://www.stats.uwo.ca/faculty/yu



More information about the R-sig-hpc mailing list