To set so called feature flags in our code we use an external file. There we define the macro
#define LB
We just ported our software to C++ and then the errors came, specificially this one
/usr/local/openmpi-1.6.4/include/openmpi/ompi/mpi/cxx/constants.h:174:28: error: declaration does not declare anything [-fpermissive]
Looking it up in the corresponding file brought up that OpenMPI uses an internal datatype called LB
.
OMPI_DECLSPEC extern const Datatype LB;
How can I avoid the name conflict? Renaming the macro #define LB
is not an option as this destroys backwards compatibility. Is it possible to use the C
-Interface of OpenMPI with C++
?