Hi,

Am 28.06.2010 um 08:10 schrieb Srinivas Gopal:

I have used the wrapper compilers ($FC=mpif90 and $CC=mpicc), even then i was getting these errors. Anyway I used -lmpi in place of - lmpich and the build was successful. Thanks a lot for your help :)

I saw makefiles, where the compilers (i.e. MPI wrappers) were only used for compiling the source to object files. Later on these were still linked with `gcc` or `ld`. Hence the MPI library must be accessed also for the linker step by `mpicc` instead of `gcc` when setting $LD is supported, or set in e.g. $LDFLAGS for the latter.

Why is there no `mpild` to do this automatically then?

-- Reuti


Cheers,
Srinivas

On Fri, Jun 25, 2010 at 5:19 PM, Jeff Squyres <jsquy...@cisco.com> wrote:
On Jun 25, 2010, at 4:11 AM, Götz Waschk wrote:

> libmpich is not part of open-mpi. Maybe your software build with mpich
> only? If your software does not use anything specific to mpich, you
> could try to change -lmpich to -lmpi .

Better yet, the Open MPI team strongly discourages listing individual MPI libraries on the link line because we reserve the right to change them over time.

Instead, we *strongly* advise you to just use Open MPI's wrapper compilers, which will insert all the Right compiler and linker flags. Then you don't have to worry about any of those pesky -I and -L options, especially when transitioning between different MPI implementations and versions of Open MPI.

http://www.open-mpi.org/faq/?category=mpi-apps#general-build
http://www.open-mpi.org/faq/?category=mpi-apps#cant-use-wrappers

--
Jeff Squyres
jsquy...@cisco.com
For corporate legal information go to:
http://www.cisco.com/web/about/doing_business/legal/cri/


_______________________________________________
users mailing list
us...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/users

_______________________________________________
users mailing list
us...@open-mpi.org
http://www.open-mpi.org/mailman/listinfo.cgi/users


Reply via email to