View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0013290VTK(No Category)public2012-07-02 13:562014-10-02 17:28
ReporterMatthew Woehlke 
Assigned ToDave DeMarle 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version6.0.0 
Summary0013290: vtk netcdf does not link when using system hdf5
DescriptionTrying to build VTK master (50e193b2) on Fedora 17 using the system version of HDF5 fails with the following link errors:

ThirdParty/netcdf/vtknetcdf/CMakeFiles/vtkNetCDF.dir/libsrc4/nc4var.c.o: In function `nc4_find_default_chunksizes2':
/usr/local/src/matthew/work/vtk/ThirdParty/netcdf/vtknetcdf/libsrc4/nc4var.c:299: undefined reference to `pow'
ThirdParty/netcdf/vtknetcdf/CMakeFiles/vtkNetCDF.dir/libsrc4/nc4hdf.c.o: In function `var_create_dataset':
/usr/local/src/matthew/work/vtk/ThirdParty/netcdf/vtknetcdf/libsrc4/nc4hdf.c:1379: undefined reference to `pow'
Tagshackaton
ProjectTBD
Typeincorrect functionality
Attached Files

 Relationships

  Notes
(0028743)
Matthew Woehlke (reporter)
2012-07-02 13:58

Two changes are needed to fix this issue. The first is obvious:

diff --git a/ThirdParty/netcdf/vtknetcdf/CMakeLists.txt b/ThirdParty/netcdf/vtknetcdf/CMakeLists.txt
index 8643c35..a5f6ea6 100644
--- a/ThirdParty/netcdf/vtknetcdf/CMakeLists.txt
+++ b/ThirdParty/netcdf/vtknetcdf/CMakeLists.txt
@@ -338,7 +338,7 @@ VTK_ADD_LIBRARY(vtkNetCDF
 
 IF (NETCDF_ENABLE_NETCDF4)
   if (VTK_USE_SYSTEM_HDF5)
- TARGET_LINK_LIBRARIES(vtkNetCDF ${HDF5_hdf5_LIBRARY} ${HDF5_hdf5_hl_LIBRARY})
+ TARGET_LINK_LIBRARIES(vtkNetCDF ${HDF5_hdf5_LIBRARY} ${HDF5_hdf5_hl_LIBRARY} ${HDF5_m_LIBRARY})
   else()
      TARGET_LINK_LIBRARIES(vtkNetCDF ${vtkhdf5_LIBRARIES})
   endif()

The second is more subtle; when calling find_package(HDF5), it is necessary to specify 'COMPONENTS HL'.

I have a local patch to teach vtk_module_third_party to pass through a COMPONENTS list, but a: am not sure this is the best way, and b: am not sure it is okay to share the patch (as it was written under DARPA contract). If this seems like a good approach, please let me know, and I will see about getting approval to share the patch.
(0033553)
Dave DeMarle (administrator)
2014-10-02 17:28

I believe this was fixed in f680cc75.

 Issue History
Date Modified Username Field Change
2012-07-02 13:56 Matthew Woehlke New Issue
2012-07-02 13:58 Matthew Woehlke Note Added: 0028743
2013-06-25 14:54 Dave DeMarle Assigned To => Dave DeMarle
2013-06-25 14:54 Dave DeMarle Status backlog => todo
2013-07-22 20:07 Dave DeMarle Status todo => backlog
2014-09-30 10:45 Dave DeMarle Tag Attached: hackaton
2014-10-02 17:28 Dave DeMarle Note Added: 0033553
2014-10-02 17:28 Dave DeMarle Status backlog => closed
2014-10-02 17:28 Dave DeMarle Resolution open => fixed
2014-10-02 17:28 Dave DeMarle Fixed in Version => 6.0.0


Copyright © 2000 - 2018 MantisBT Team