mannau / h5

Interface to the HDF5 Library
Other
70 stars 22 forks source link

Error when installing h5 with hdf5-devel present #70

Open geneorama opened 6 years ago

geneorama commented 6 years ago

I believe that I have hdf5-devel, but I'm still unable to install. I'm not sure how to test that I meet the System Requirements. The command h5cc -showconfig seems to provide a lot of relevant detail, but I don't see anything about an API version that's anywhere close to the "v18" mentioned in the docs (h5 requires the 'new' v18 API version). My hdf5 installation is fairly recent, from last fall.

I am able to read / write hdf5 files in Python, but maybe Python doesn't require that the C++ interface is enabled --enable-cxx=yes?

System info

The OS:

$ cat /etc/*elease
LSB_VERSION=base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Red Hat Enterprise Linux Server release 6.9 (Santiago)
Red Hat Enterprise Linux Server release 6.9 (Santiago)

Error message

My error message, at the end of the installation:

checking for h5c++... no
configure: error: 'h5c++' does not seem to be installed on your platform.
    Please install the hdf5 library with C++ interface enabled (--enable-cxx=yes).
    The required HDF5 library files can be installed as follows:
        - Debian-based (e.g. Debian >= 8.0, Ubuntu >= 15.04): 'sudo apt-get install libhdf5-dev'
        - Old Debian-based (e.g Debian < 8.0, Ubuntu < 15.04): Install from source (see INSTALL)
        - OS X using Homebrew: 'brew install homebrew/science/hdf5 --enable-cxx'
        - RPM-based (e.g Fedora): 'sudo yum install hdf5-devel'

Details of hdf5 installation

Some info about my hdf5 installation based on h5cc -showconfig:

$ h5cc -showconfig
            SUMMARY OF THE HDF5 CONFIGURATION
            =================================

General Information:
-------------------
                   HDF5 Version: 1.10.1
                  Configured on: Mon Sep 18 10:08:50 UTC 2017
                  Configured by: rdonnelly@raybuild-centos6x64-01.build.corp.continuum.io
                    Host system: x86_64-conda_cos6-linux-gnu
              Uname information: Linux raybuild-centos6x64-01.build.corp.continuum.io 2.6.32-696.10.1.el6.x86_64 #1 SMP Tue Aug 22 18:51:35 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
                       Byte sex: little-endian
             Installation point: /app/Anaconda2

Compiling Options:
------------------
                     Build Mode: production
              Debugging Symbols: no
                        Asserts: no
                      Profiling: no
             Optimization Level: high

Linking Options:
----------------
                      Libraries: static, shared
  Statically Linked Executables:
                        LDFLAGS: -Wl,-O2,--sort-common,--as-needed,-z,relro,-z,now
                     H5_LDFLAGS:
                     AM_LDFLAGS:  -L/app/Anaconda2/lib
                Extra libraries: -lrt -lpthread -lz -ldl -lm
                       Archiver: /app/Anaconda2/bin/x86_64-conda_cos6-linux-gnu-ar
                         Ranlib: /app/Anaconda2/bin/x86_64-conda_cos6-linux-gnu-ranlib

Languages:
----------
                              C: yes
                     C Compiler: /app/Anaconda2/bin/x86_64-conda_cos6-linux-gnu-cc
                       CPPFLAGS: -D_FORTIFY_SOURCE=2 -O2
                    H5_CPPFLAGS: -D_GNU_SOURCE -D_POSIX_C_SOURCE=200112L   -DNDEBUG -UH5_DEBUG_API
                    AM_CPPFLAGS:  -I/app/Anaconda2/include
                        C Flags: -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe
                     H5 C Flags:   -std=c99 -pedantic -Wall -W -Wundef -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -finline-functions -s -Wno-inline -Wno-aggregate-return -O
                     AM C Flags:
               Shared C Library: yes
               Static C Library: yes

                        Fortran: yes
               Fortran Compiler: /app/Anaconda2/bin/x86_64-conda_cos6-linux-gnu-gfortran
                  Fortran Flags:
               H5 Fortran Flags:  -pedantic -Wall -Wextra -Wunderflow -Wimplicit-interface -Wsurprising -Wno-c-binding-type  -s -O2
               AM Fortran Flags:
         Shared Fortran Library: yes
         Static Fortran Library: yes

                            C++: yes
                   C++ Compiler: /app/Anaconda2/bin/x86_64-conda_cos6-linux-gnu-c++
                      C++ Flags: -fvisibility-inlines-hidden -std=c++17 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -pipe
                   H5 C++ Flags:   -pedantic -Wall -W -Wundef -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion -Wredundant-decls -Winline -Wsign-promo -Woverloaded-virtual -Wold-style-cast -Weffc++ -Wreorder -Wnon-virtual-dtor -Wctor-dtor-privacy -Wabi -finline-functions -s -O
                   AM C++ Flags:
             Shared C++ Library: yes
             Static C++ Library: yes

                           Java: no

Features:
---------
                  Parallel HDF5: no
             High-level library: yes
                   Threadsafety: yes
            Default API mapping: v110
 With deprecated public symbols: yes
         I/O filters (external): deflate(zlib)
                            MPE: no
                     Direct VFD: no
                        dmalloc: no
 Packages w/ extra debug output: none
                    API tracing: no
           Using memory checker: no
Memory allocation sanity checks: no
            Metadata trace file: no
         Function stack tracing: no
      Strict file format checks: no
   Optimization instrumentation: no

(This means very little to me, maybe it's helpful to someone else)

Thank you.

geneorama commented 6 years ago

@ravipatel4 For some reason I don't see your comment anymore, but I'm replying to this:

I have the same problem. Were you able to resolve this @geneorama? Please let me know. Thank you.

I'm not sure how they did it, and I can't find the commands in the history.

I found these notes from my emails:

This command appears to be able to check the version number of HDF5: strings /usr/lib64/libhdf5.so | grep "HDF5 library version:"

The other missing piece of the puzzle was that we had to rebuild the tables package against the correct HDF5 library. This was the winning command: pip install --install-option='--hdf5=/app/Anaconda/pkgs/hdf5-1.8.17-1/' tables

And the final fix was adding the HDF5 path to LD_LIBRARY_PATH. export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/app/Anaconda/lib/

I think that these notes were about fixing the tables package.

The admin said that he installed hdf5-1.8.18 in another email.

This was all over a year ago, so I don't know that anyone's going to be able to track down the details.

ravipatel4 commented 6 years ago

@geneorama, you weren't able to see my comment since I deleted it as I could resolve the issue. I am glad that you could resolve the problem.

For other people's reference, I reinstalled hdf5 again and configured correctly (as mentioned in their README), which solved my problem.