[mpich2-dev] MPE and C++: 'mpi.h' is being #include'd inside a extern "C" { } block

Lisandro Dalcin dalcinl at gmail.com
Tue Nov 17 13:52:38 CST 2009


If you try to compile the lines below using the 'mpicxx' (i.e. C++
compiler wrapper) it fails.

#include <stdlib.h>
#include <mpe.h>
int main(int n, char**v) { return 0; }

This happens because "mpi.h" end-up being #include'd inside a extern
"C" { } block, and that is obviously wrong for the C++ bindings.


-- 
Lisandro Dalcín
---------------
Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
PTLC - Güemes 3450, (3000) Santa Fe, Argentina
Tel/Fax: +54-(0)342-451.1594


More information about the mpich2-dev mailing list