On Thu, May 28, 2015 at 10:57 AM, Erik Schnetter schnetter@cct.lsu.edu wrote:
Originally, __attribute__ is a built-in keyword for the compiler. It is not a macro, as others suggested earlier. If you #define it to be empty, then the compiler will never see the keyword, as the preprocessor deletes it. So using #undef exactly undoes the action of the HDF5 header file, making the original keyword again visible to the compiler.
This sounds like a good idea to me. I'd suggest only doing the #undef for version 1.8.15 with the following check
((H5_VERS_MAJOR==1) && (H5_VERS_MINOR==8) && (H5_VERS_RELEASE==15)
since only that particular version is affected.