[MPICH] Error compiling c++ programs with mpiCC

Anna Mereu anna.mereu at diee.unica.it
Fri Jun 15 10:01:48 CDT 2007


Hi, i'm trying to compile c++ program including mpi++.h files with the
mpiCC complier. The errors are the following:

/usr/local/mpich-g2-cpp/include/mpi2c++/comm.h:106: warning: ‘class 
MPI::Comm’ has virtual functions but non-virtual destructor
/usr/local/mpich-g2-cpp/include/mpi2c++/intracomm.h:30: warning: ‘class 
MPI::Intracomm’ has virtual functions but non-virtual destructor
/usr/local/mpich-g2-cpp/include/mpi2c++/topology.h:31: warning: ‘class 
MPI::Cartcomm’ has virtual functions but non-virtual destructor
/usr/local/mpich-g2-cpp/include/mpi2c++/topology.h:112: warning: ‘class 
MPI::Graphcomm’ has virtual functions but non-virtual destructor
/usr/local/mpich-g2-cpp/include/mpi2c++/intercomm.h:31: warning: ‘class 
MPI::Intercomm’ has virtual functions but non-virtual destructor
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_algobase.h: 
In function ‘MPI2CPP_BOOL_T std::lexicographical_compare(const unsigned 
char*, const unsigned char*, const unsigned char*, const unsigned char*)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_algobase.h:887: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<char>::eq(const char&, const char&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:245: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<char>::lt(const char&, const char&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:249: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<char>::eq_int_type(const int&, const int&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:287: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<wchar_t>::eq(const wchar_t&, const wchar_t&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:315: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<wchar_t>::lt(const wchar_t&, const wchar_t&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:319: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h: 
In static member function ‘static MPI2CPP_BOOL_T 
std::char_traits<wchar_t>::eq_int_type(const wint_t&, const wint_t&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/char_traits.h:353: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits: 
At global scope:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:380: 
error: cannot convert ‘bool’ to ‘const MPI2CPP_BOOL_T’ in initialization
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:533: 
error: cannot convert ‘bool’ to ‘const MPI2CPP_BOOL_T’ in initialization
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1006: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1007: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1023: 
error: cannot convert ‘bool’ to ‘const MPI2CPP_BOOL_T’ in initialization
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1063: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1064: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1080: 
error: cannot convert ‘bool’ to ‘const MPI2CPP_BOOL_T’ in initialization
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1120: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1121: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/limits:1138: 
error: cannot convert ‘bool’ to ‘const MPI2CPP_BOOL_T’ in initialization
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_classes.h: 
In member function ‘MPI2CPP_BOOL_T std::locale::operator!=(const 
std::locale&) const’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_classes.h:242: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_classes.h: 
In member function ‘MPI2CPP_BOOL_T 
std::locale::_Impl::_M_check_same_name()’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_classes.h:540: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in assignment
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/i486-linux-gnu/bits/ctype_inline.h: 
In member function ‘MPI2CPP_BOOL_T std::ctype<char>::is(short unsigned 
int, char) const’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/i486-linux-gnu/bits/ctype_inline.h:40: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo: 
In member function ‘MPI2CPP_BOOL_T std::type_info::before(const 
std::type_info&) const’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo:106: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo: 
In member function ‘MPI2CPP_BOOL_T std::type_info::operator==(const 
std::type_info&) const’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo:108: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo: 
In member function ‘MPI2CPP_BOOL_T std::type_info::operator!=(const 
std::type_info&) const’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/typeinfo:111: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_facets.tcc: 
In function ‘MPI2CPP_BOOL_T std::__verify_grouping(const char*, size_t, 
const std::string&)’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_facets.tcc:2473: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in assignment
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_facets.tcc:2475: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in assignment
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/locale_facets.tcc:2480: 
error: invalid conversion from ‘int’ to ‘MPI2CPP_BOOL_T’
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_algobase.h: 
In function ‘MPI2CPP_BOOL_T 
std::lexicographical_compare(_InputIterator1, _InputIterator1, 
_InputIterator2, _InputIterator2) [with _InputIterator1 = const signed 
char*, _InputIterator2 = const signed char*]’:
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_algobase.h:901: 
instantiated from here
/usr/lib/gcc/i486-linux-gnu/4.1.2/../../../../include/c++/4.1.2/bits/stl_algobase.h:835: 
error: cannot convert ‘bool’ to ‘MPI2CPP_BOOL_T’ in return
make: *** [confronto.o] Error 1

How can i fix them??

Thank you very much for the help

Anna




More information about the mpich-discuss mailing list