AMBER: pmemd: "undefined reference to `mpi_(name-varies)'"

From: Lachele Foley (Lists) <"Lachele>
Date: Thu, 24 Apr 2008 10:22:42 -0400

I'm trying to compile parallel pmemd for Amber 10. The serial compile
goes fine.

Short version: At the final stage ("(compiler) -o pmemd
gbl_constants.o (etc.)"), I get lots (>100) of variations on:

mdin_ctrl_dat.o(.text+0xa456): In function
: undefined reference to `mpi_bcast_'

Can this be made to work for us?

More info:

We have ScaMPI (Scali MPI). I've tried gfortran and ifort. Gfortran
compiles in serial just fine (and I assume ifort would, too). Both
have the same mpi issues in the parallel compile. I tried setting
-fno-second-underscore because that was indicated in the config.h for
parallel amber, but it didn't change anything. The parallel version
of Amber 10 compiles and tests fine (with some trivial and unrelated
exceptions). $MPI_HOME is set to /opt/scali.

Here's the config data file I made for gfortran with ScaMPI. I got a
file that works with gfortran by starting with the ifort file and
deleting compiler options until it stopped complaining. I didn't
delete options from the ifort version when I tried ifort, but it
behaved the same WRT the mpi calls. If you need more info, just say.

>more linux_p4.gfortran.scali
MPI_LIBS = -L$(MPI_LIBDIR) -lmpi -Wl -lpthread

CPP = /lib/cpp
CPPFLAGS = -traditional -P

F90 = gfortran
F90FLAGS = -c -fno-second-underscore
F90_OPT_DBG = -g -traceback
F90_OPT_LO = -O0
F90_OPT_MED = -O2
F90_OPT_HI = -ip -O3
F90_OPT_DFLT = $(F90_OPT_HI)

CC = gcc

LOAD = gfortran
LOADLIBS = -lmpi -Wl

:-) Lachele
Lachele Foley
The AMBER Mail Reflector
To post, send mail to
To unsubscribe, send "unsubscribe amber" to
Received on Sun Apr 27 2008 - 06:07:35 PDT
Custom Search