FAQ entry

Create issue
Issue #358 closed
Frank Löffler created an issue

For a new FAQ:

Q: I get errors like "/usr/include/H5Dpublic.h:145: error: too many arguments to function ‘hid_t H5Dopen1(hid_t, const char*)’"

A: The HDF5 library you use is either version 1.6 or defaults to it. If it is version 1.6.x, update to 1.8.x. If it is 1.8.x and it defaults to the 1.6 API version, you might be out of luck, especially on Debian Squeeze systems, see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=537414. What you can then do is to remove (comment) out the macro H5_USE_16_API_DEFAULT in /usr/include/H5pubconf.h. This isn't pretty, but is really a bug in the package and has to be fixed there. There is no way to switch to the new API on those systems, other than specifying the API version of each symbol separately, which would be even messier.


Comments (9)

  1. Erik Schnetter
    • removed comment

    To my knowledge, we are not using any of the features of the 1.8 API, and we spent quite some effort ensuring we are compatible with both APIs in the past. I believe that any such problems with PUGH or Carpet should be treated as errors.

    On a side note: recommending that people modify system headers is a really bad idea, as this will influence many other parts of the system, e.g. potentially even Debian's autoupdate feature (if building from source). If you don't like the default settings of a system package, and the system package can't be changed in an official manner, then it is best to install HDF5 yourself, e.g. via ExternalThorns/HDF5.

    I also disagree strongly that specifying the 1.6 API is "really a bug in the package".

  2. Frank Löffler reporter
    • removed comment

    The HDF5 recombiner uses the new API, and IMHO we should switch everything to it eventually.

    It is a bug in the Debian hdf5 package IMHO, and it even got corrected already - but this didn't make it into squeeze in time for the release. So either you install hdf5 from sid or maybe testing, or change the system header. Of course this could influence other things - but the current setup just breaks a lot of software which assumes that 1.8 is used by default when the 1.8 lib is installed. There is an easy mechanism to use 1.6 when 1.8 is installed, that's not a problem.

    So, we should probably point out that changing a system header can have its problems, and an alternative would be to install a newer Debian hdf5 package.

  3. Erik Schnetter
    • removed comment

    FAQ entries are for people who don't have a deep understanding of the problem, maybe because they don't care, and just want a quick solution. We need to provide a safe and simple solution.

    What Debian did do, should have done, or should be doing, or what we should be doing with Carpet doesn't really matter in this context. We can't change Debian retroactively, and we either will or will not make our HDF5 recombiner compatible.

    As long as this problem exists, there is one easy solution: use ExternalLibraries/HDF5. This is what we should advocate.

    Asking people to change system files is not a good advertisement for Cactus.

  4. Ian Hinder
    • removed comment

    Q: I get errors like "/usr/include/H5Dpublic.h:145: error: too many arguments to function ‘hid_t H5Dopen1(hid_t, const char*)’"

    A: If you are using Debian, you might get this error due to a bug in the Debian HDF5 package. Instead of using the system HDF5 library, you can build HDF5 as part of Cactus by setting HDF5 = BUILD in your optionlist.

  5. Frank Löffler reporter
    • removed comment

    Sure, let's go with that. That should work, and it mentions the real problem. I think this is important as they will have a hard time building anything using the 1.8 API using the Debian hdf5 version (which is 1.8.4, with the 1.8 API disabled without an easy way to enable it). I spend quite some time figuring out why a version 1.8.x insists on the 1.6 API. This is not what upstream does. I would like to spare others from this.

  6. Log in to comment