Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] Windows CMake build problems ...
From: Shiqing Fan (fan_at_[hidden])
Date: 2010-01-26 09:48:52


Hi Charlie,

There is definitely something wrong in the cxx library for Windows, but
it's still not very clear to me yet. We'll try to find the reason and
fix it.

Thanks for reporting it.

Regards,
Shiqing

cjohnson_at_[hidden] wrote:
> Was able to build and run all the c examples from the tutorial at
> <http://ci-tutor.ncsa.illinois.edu/index.php>
> <http://ci-tutor.ncsa.illinois.edu/index.php%3E>
>
> However, none of the extended or simple c++ examples work, they all
> die with the same link error.
>
> For instance: mpi_gather.cc
> ______________________________________________
>
> #include <stdio.h>
> #include <mpi.h>
> #include <math.h>
>
> using namespace MPI;
>
> int main(int argc, char* argv[]) {
> int rank;
> int recvcount,sendcount;
> int reap[8];
> int sow[2];
>
> Init(argc,argv);
> rank=COMM_WORLD.Get_rank();
> sendcount=2;
> sow[0]=rank; sow[1]=-rank;
> if(rank==1) {
> recvcount=2;
> }
> COMM_WORLD.Gather(sow,sendcount,INT,reap,recvcount,INT,1);
> if(rank==1) {
> printf("P:%d",rank);
> for(int i=0;i<8;++i) {
> printf(" %2d ",reap[i]);
> }
> printf("\n");
> }
> Finalize();
> }
> ______________________________________
>
> Here's the compile output from mpic++:
>
> C:\prog\mon\examples>mpic++ mpi_gather.cc
> Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 14.00.50727.762
> for 80x86
> Copyright (C) Microsoft Corporation. All rights reserved.
>
> mpi_gather.cc
> Microsoft (R) Incremental Linker Version 8.00.50727.762
> Copyright (C) Microsoft Corporation. All rights reserved.
>
> /out:mpi_gather.exe
> "/LIBPATH:C:\Program Files\OpenMPI_v1.4-win32\lib"
> libmpid.lib
> libopen-pald.lib
> libopen-rted.lib
> libmpi_cxxd.lib
> libmpid.lib
> libopen-pald.lib
> libopen-rted.lib
> advapi32.lib
> Ws2_32.lib
> shlwapi.lib
> mpi_gather.obj
> mpi_gather.obj : error LNK2019: unresolved external symbol "void
> __cdecl MPI::InitializeIntercepts(void)"
> (?InitializeIntercepts_at_MPI@@YAXXZ)
> referenced in function "void __cdecl MPI::Real_init(void)"
> (?Real_init_at_MPI@@YAXXZ)mpi_gather.exe : fatal error LNK1120: 1
> unresolved externals
>
> Every c++ dies with this link error.
>
> Charlie ...
>
> -------- Original Message --------
> Subject: RE: [OMPI users] Windows CMake build problems ...
> From: cjohnson_at_[hidden]
> Date: Tue, January 26, 2010 2:10 am
> To: fan_at_[hidden]
> Cc: "Open MPI Users" <users_at_[hidden]>
>
> Yeah, that was it. Thanks.
>
> Charlie ...
>
> -------- Original Message --------
> Subject: Re: [OMPI users] Windows CMake build problems ...
> From: Shiqing Fan <fan_at_[hidden]>
> Date: Tue, January 26, 2010 1:57 am
> To: cjohnson_at_[hidden]
> Cc: Open MPI Users <users_at_[hidden]>
>
>
> Hi Charlie ,
>
> Did you run the mpicc command in the Visual Studio Command
> Prompt? Is it
> possible for you to call cl.exe from there? Because it sounds
> like the
> VS compiler was not found.
>
>
> Regards,
> Shiqing
>

-- 
--------------------------------------------------------------
Shiqing Fan                          http://www.hlrs.de/people/fan
High Performance Computing           Tel.: +49 711 685 87234
  Center Stuttgart (HLRS)            Fax.: +49 711 685 65832
Address:Allmandring 30               email: fan_at_[hidden]    
70569 Stuttgart