
Hi all, I installed the boostpro libraries version 1.46.1. Then I got the openmpi 1.4.3 sources and successfully built them with cmake/VS2008. Now I'm trying to run some example code: #include <boost/mpi.hpp> #include <iostream> #include <string> #include <boost/serialization/string.hpp> namespace mpi = boost::mpi; int main(int argc, char* argv[]) { mpi::environment env(argc, argv); mpi::communicator world; if (world.rank() == 0) { world.send(1, 0, std::string("Hello")); std::string msg; world.recv(1, 1, msg); std::cout << msg << "!" << std::endl; } else { std::string msg; world.recv(0, 0, msg); std::cout << msg << ", "; std::cout.flush(); world.send(0, 1, std::string("world")); } return 0; } This keeps giving me the linker error below. My dependencies are libmpi.lib, libmpi_cxx.lib, boost_mpi-vc90-mt-1_46_1.lib, libboost_mpi-vc90-mt-1_46_1.lib. I also tried with the pre built openmpi version 1.5.3 library files, this didn't help. Error 1 error LNK2019: unresolved external symbol "public: __thiscall boost::mpi::communicator::operator struct ompi_communicator_t *(void)const " (??Bcommunicator@mpi@boost@@QBEPAUompi_communicator_t@@XZ) referenced in function "protected: void __thiscall boost::mpi::communicator::send_impl<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > >(int,int,class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,struct boost::mpl::bool_<0>)const " (??$send_impl@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@communicator@mpi@boost@@IBEXHHABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@U?$bool_@$0A@@mpl@2@@Z) MPITest.obj MPITest I suppose this is caused by the boost.org libraries?! Could somebody help me out here?Thanks
participants (1)
-
Nils van der Struis