nextgen-astrodata/DAL — Issue #1: Problem with FindHDF5 and LUS
Author: pschella
Created: 2012-02-09 13:11:42+00:00
State: open

When configuring the following error occurs:

build $ cmake .. -DHDF5_C_INCLUDE_DIR=$LOFARSOFT/release/include/hdf5 -DHDF5_ROOT=$LOFARSOFT/release
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Checking whether C compiler has -isysroot
-- Checking whether C compiler has -isysroot - yes
-- Checking whether C compiler supports OSX deployment target flag
-- Checking whether C compiler supports OSX deployment target flag - yes
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Checking whether CXX compiler has -isysroot
-- Checking whether CXX compiler has -isysroot - yes
-- Checking whether CXX compiler supports OSX deployment target flag
-- Checking whether CXX compiler supports OSX deployment target flag - yes
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found HDF5: HDF5_hdf5_LIBRARY_RELEASE-NOTFOUND;/usr/local/lib/libz.a;/usr/lib/libm.dylib
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
HDF5_hdf5_LIBRARY_RELEASE
linked by target "cmTryCompileExec" in directory /Users/pschella/Development/DAL/build/CMakeFiles/CMakeTmp

CMake Error: Internal CMake error, TryCompile configure of cmake failed
CMake Error at cmake/TestHDF5.cmake:11 (message):
Could not compile HDF5 test program:

Call Stack (most recent call first):
src/CMakeLists.txt:5 (include)

-- Configuring incomplete, errors occurred!

The FindHDF5 script shipped with CMake is very complicated and does not work well when there are multiple installations of HDF5 on a machine, we also cannot fix any bugs it contains.
Perhaps it is best to ship DAL with its own simplified version of FindHDF5.
I would be willing to write one that works on my system and submit it for review if so desired.