-
Notifications
You must be signed in to change notification settings - Fork 934
Closed
Description
Thank you for taking the time to submit an issue!
Background information
What version of Open MPI are you using? (e.g., v1.10.3, v2.1.0, git branch name and hash, etc.)
openmpi-4.0.0
Describe how Open MPI was installed (e.g., from a source/distribution tarball, from a git clone, from an operating system distribution package, etc.)
Compiled from a source/distribution tarball.
Please describe the system on which you are running
- Operating system/version: Ubuntu 18.10
- Computer hardware: x86_64 arch
- Network type:
Details of the problem
This macro in mpi.h produces so many warnings about old-style-cast in any code using OpenMPI, e.g. OpenFOAM opensource package.
#if !OMPI_BUILDING
#define OMPI_PREDEFINED_GLOBAL(type, global) ((type) ((void *) &(global)))
#else
#define OMPI_PREDEFINED_GLOBAL(type, global) ((type) &(global))
#endif
the warnings:
In file included from db/IOstreams/Pstreams/OPwrite.C:29:
db/IOstreams/Pstreams/OPwrite.C: In static member function ‘static bool Foam::OPstream::write(Foam::Pstream::commsTypes, int, const char*, std::streamsize, int, Foam::label)’:
/home/shadowfax/foam/foam-extend-4.1/ThirdParty/packages/openmpi-4.0.0/platforms/linux64GccDPOpt/include/mpi.h:329:72: warning: use of old-style cast to ‘void*’ [-Wold-style-cast]
#define OMPI_PREDEFINED_GLOBAL(type, global) ((type) ((void *) &(global)))
^
/home/shadowfax/foam/foam-extend-4.1/ThirdParty/packages/openmpi-4.0.0/platforms/linux64GccDPOpt/include/mpi.h:1049:18: note: in expansion of macro ‘OMPI_PREDEFINED_GLOBAL’
#define MPI_BYTE OMPI_PREDEFINED_GLOBAL(MPI_Datatype, ompi_mpi_byte)
^~~~~~~~~~~~~~~~~~~~~~
db/IOstreams/Pstreams/OPwrite.C:101:13: note: in expansion of macro ‘MPI_BYTE’
MPI_BYTE,
Metadata
Metadata
Assignees
Labels
No labels