So to summarise:
– HDF5 is undefining __attribute__, and this is a bug in hdf5.
– In the stack overflow post, argp.h is undefining __attribute__, so this is a bug in glibc
Is that correct? My suggestion to try --std=gnu++11 in CXXFLAGS won't fix the problem in the HFD5 header; it would only affect the argp.h problem, which doesn't apply to us.
Digging a bit deeper, it seems that we have been bitten (again) by trying to track a moving target. The HDF5 MacPorts port was updated from 1.8.14 to 1.8.15 on 16-May-2015 (
https://trac.macports.org/log/trunk/dports/science/hdf5/Portfile), 2 days before the ET release, and after the release branches had been created and the final testing had been done. Note that this also happened with OpenMPI a few days before, introducing a critical regression which we were able to work around in time.
The responsible commit in HDF5 seems to be this one:
They were previously undefining __attribute__ only in H5private.h, which is included by hdf5 source files, but not from the public api used by user code, and this commit moves this definition into a public header file included by user code. Erik, do you want to contact the developers, since you understand this better than I do?
I think the most sensible workaround for us would be set HDF5_DIR = BUILD in osx-macports.cfg, since the current macports version is broken. MacPorts has a single tree, they don't split into stable and unstable branches, presumably due to lack of resources. The same is true of homebrew; presumably they will also update to 1.8.15 at some point, so maybe we should build HDF5 for homebrew as well. The Cactus-provided version in ExternalLibraries is 1.8.14.
--