[CMake] FindHDF5.cmake configuration -- finds regular, can't find HL

Tim Gallagher tim.gallagher at gatech.edu
Sat Jun 23 16:00:23 EDT 2012


I reported this awhile back: 

http://public.kitware.com/Bug/view.php?id=12316 

The patch I attached would work, but it fails in some select cases so it wasn't put in. I don't remember the details, it may fail when there is no HL or something. But you can try it and see if it works for your case. 

Tim 

----- Original Message -----

From: "Eli Ateljevich" <eli at water.ca.gov> 
To: cmake at cmake.org 
Sent: Saturday, June 23, 2012 3:57:03 PM 
Subject: [CMake] FindHDF5.cmake configuration -- finds regular, can't find HL 



Hi all, 
I am supporting cmake version 2.6. I have included the latest FindHDF5.cmake file I could find in my distro … except for one dependency that needed to be added, this seems to work fine. 

When I try to find_package(HDF5 COMPONENTS … ) it works for the C (and Fortran) component but not for the HL library or Fortran_HL. Here is the output for the C language HL variant: 
-- Found HDF5: HDF5_hdf5_hl_LIBRARY_RELEASE-NOTFOUND;/usr/local/dms/pkg/hdf5/1.8.7-intel12.0-parallel/lib/libhdf5.a;/usr/lib64/libz.so;/usr/lib64/libm.so 

Could it be cmake is looking for the unadorned libhdf5.a for the regular library and libhdf5-release or something like that for the hl library. Why the difference? If so is this a type of behavior that can be switched off? 

Here are the contents of the directory, in case the issue of the HL libraries not being there comes up: 
$ ls /usr/local/dms/pkg/hdf5/1.8.7-intel12.0-parallel/lib 
libhdf5.a libhdf5_hl.a libhdf5_hl.la 
libhdf5_fortran.a libhdf5hl_fortran.a libhdf5.la 
libhdf5_fortran.la libhdf5hl_fortran.la libhdf5.settings 

Thanks for any insight. I realize numerous patches have been made to FindHDF5.cmake, and that I might be voiding my warranty by backwards porting it, but it sure seems like it should work for all the components if it works for two of them. 

Eli 
-- 

Powered by www.kitware.com 

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html 

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ 

Follow this link to subscribe/unsubscribe: 
http://www.cmake.org/mailman/listinfo/cmake 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20120623/937efe55/attachment.htm>


More information about the CMake mailing list