[MPICH] Still having problems after switching to Visual Studio.net C++
David Ashton
ashton at mcs.anl.gov
Fri Oct 14 15:48:11 CDT 2005
1) You should link with mpi.lib. But we cannot say that definitively until
the next release because there is a bug in the current distribution that
makes mpi.lib not work with some applications. If it does not work with
your code then you will have to link with mpich2.lib.
2) For Visual Studio .NET you can add link libraries to the
Properties>Linker>Input>Additional Dependencies input box.
3) cxx.lib contains the C++ interface so you only link with it if you are
using the MPI C++ interface. If you are using the MPI C interface then you
don't need to link with that library.
-David Ashton
_____
From: Oberta A. Slotterbeck (Obie) [mailto:obie at hiram.edu]
Sent: Thursday, October 13, 2005 10:23 PM
To: David Ashton
Subject: Re: [MPICH] Still having problems after switching to Visual
Studio.net C++
Sorry to be such a pain, but I just can't seem to get things working.
1) Why would I choose mpi.lib instead of mpich2.lib or vice versa?
2) By linking with one of those do you mean from the solution editor :
project > properties> linker > command line and insert, say, mpi.lib?
3) The user guide says "add mpi.lib and cxx.lib to the link command". Should
I add cxx.lib?
Is there any more detailed instructions for doing this?
Sorry- I am new to Visual Studio .net as well as MPI.
----- Original Message -----
From: David Ashton <mailto:ashton at mcs.anl.gov>
To: 'Oberta A. Slotterbeck <mailto:obie at hiram.edu> (Obie)' ; 'MPICH2
Discuss' <mailto:mpich-discuss at mcs.anl.gov>
Sent: Thursday, October 13, 2005 7:21 PM
Subject: RE: [MPICH] Still having problems after switching to Visual
Studio.net C++
Just setting the environment variables isn't enough. You need to link with
mpi.lib or mpich2.lib.
-David Ashton
_____
From: owner-mpich-discuss at mcs.anl.gov
[mailto:owner-mpich-discuss at mcs.anl.gov] On Behalf Of Oberta A. Slotterbeck
(Obie)
Sent: Thursday, October 13, 2005 5:17 PM
To: MPICH2 Discuss
Subject: [MPICH] Still having problems after switching to Visual Studio.net
C++
Trying to build an exe image for the sample problem provided with MPICH2
software (interactive version of cpi). In response to earlier message
suggesting switching to VS.net C++, I did and still have the same problems.
The environment variables have been set for include, lib, and path, but it
looks like the linker isn't finding what it needs:
icpi error LNK2019: unresolved external symbol _MPI_Bcast referenced in
function _main
icpi error LNK2019: unresolved external symbol _MPI_Comm_rank referenced in
function _main
.... etc down to:
icpi fatal error LNK1120: 8 unresolved externals
I'm attempting to run on a single machine for development purposes.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20051014/37f94473/attachment.htm>
More information about the mpich-discuss
mailing list