Skip to content

Rmpi: -lopa parameter on compiling needed? Works without

2 messages · Arne Hendrik Schulz, Hao Yu

#
Hi all,
I am using the current development version of Rmpi (0.6-4) on a Cray
Cluster. The problem is that it does not compile with the -lopa parameter as
opa.c/libopa.c is not installed on the cluster (see attachted output below).
Compiling Rmpi without the -lopa parameter works and using the cluster with
MPI works, too. Is it really necessary to include libopa? I cannot see any
drawbacks so far.

Kind regards,
Arne

P.S.: If anyone would like to test without -lopa, I uploaded a branch of
Rmpi-0.6-4: http://www.ahschulz.de/pub/R/packages/Rmpi_0.6-4_branch.tar.gz
--with-Rmpi-type=CRAY uses the -lopa parameter, --with-Rmpi-type=CRAY_NOLOPA
dies not.

Installing Rmpi with -lopa:
R/bin/R CMD INSTALL temp/packages/Rmpi_0.6-4.tar.gz
--configure-args="--with-Rmpi-include=/opt/cray/mpt/6.1.1/gni/mpich2-cray64/
81/include --with-Rmpi-libpath=/opt/cray/mpt/6.1.1/gni/mpich2-cray64/81/lib
--with-Rmpi-type=CRAY" --no-test-load
* installing to library '/gfs1/work/hbmahs32/R/lib64/R/library'
* installing *source* package 'Rmpi' ...
checking for openpty in -lutil... no
checking for main in -lpthread... no
configure: creating ./config.status
config.status: creating src/Makevars
** libs
(...)
gcc -std=gnu99 -shared -L/usr/local/lib64 -o Rmpi.so RegQuery.o Rmpi.o
conversion.o internal.o -L/opt/cray/mpt/6.1.1/gni/mpich2-cray64/81/lib
-lmpich_cray_default64 -lmpl -lopa
/usr/bin/ld: cannot find -lopa
collect2: error: ld returned 1 exit status
make: *** [Rmpi.so] Error 1
ERROR: compilation failed for package 'Rmpi'


Installing Rmpi without -lopa
R/bin/R CMD INSTALL temp/packages/Rmpi_0.6-4_branch.tar.gz
--configure-args="--with-Rmpi-include=/opt/cray/mpt/6.1.1/gni/mpich2-cray64/
81/include --with-Rmpi-libpath=/opt/cray/mpt/6.1.1/gni/mpich2-cray64/81/lib
--with-Rmpi-type=CRAY_NOLOPA" --no-test-load
* installing to library '/gfs1/work/hbmahs32/R/lib64/R/library'
* installing *source* package 'Rmpi' ...
checking for openpty in -lutil... no
checking for main in -lpthread... no
configure: creating ./config.status
config.status: creating src/Makevars
** libs
(...)
gcc -std=gnu99 -shared -L/usr/local/lib64 -o Rmpi.so RegQuery.o Rmpi.o
conversion.o internal.o -L/opt/cray/mpt/6.1.1/gni/mpich2-cray64/81/lib
-lmpich_cray_default64 -lmpl
installing to /gfs1/work/hbmahs32/R/lib64/R/library/Rmpi/libs
** R
** demo
** inst
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
* DONE (Rmpi)
1 day later
#
Hi Arne,

Last year, I was given an access of a Cray cluster to make Rmpi work.
After many tries and errors, -lmpich_cray_default64 -lmpl -lopa were used
eventually. Whether -lopa is necessary or not for other Cray cluster, I
have no answer. But it is good to know that some Cray clusters, -lopa is
not necessary.

Hao
Arne Hendrik Schulz wrote: