I may have a silly question because I am Java-naive but isn't the problem that the libhdf5 gets statically linked into the JNI? Is there any way to make libhdf5 dynamically linked into the JNI? If so, then I think a later dlopen of a libhdf5-dependent shared library (e.g. a compressor) would find and use the libhdf5 already loaded when the JNI was loaded.
On 5/18/16, 9:26 AM, "Hdf-forum on behalf of Derick Swanepoel" <[email protected] on behalf of [email protected]> wrote: >Good day, > >We¹ve been developing a compression filter and have discovered that tools >such as h5dump and libraries such as h5py fail to load the filter, while >our own C++ tools that read/write datasets using the filter work fine. >However, explicitly linking the filter with libpthread allows h5dump to >load it, and additionally linking it with libhdf5 allows h5py to load it. > >Our C++ tools are already linked with these libraries which would explain >why they have no trouble loading it. > >I see that someone came across a similar issue before and it was >recommended that filters that use HDF5 calls should link with the library >(https://lists.hdfgroup.org/pipermail/hdf-forum_lists.hdfgroup.org/2015-De >cember/009100.html). I¹m not sure I understand why this is necessary, >since any code that is capable of opening an HDF5 file would already link >with libhdf5. > >If this is normal, perhaps it¹s worth noting in the filter documentation, >especially since implementing a set_local callback would almost certainly >involve calling some HDF5 functions (we use it to determine type size, >etc.) > >Regards, >Derick >_______________________________________________ >Hdf-forum is for HDF software users discussion. >[email protected] >http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org >Twitter: https://twitter.com/hdf5 _______________________________________________ Hdf-forum is for HDF software users discussion. [email protected] http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org Twitter: https://twitter.com/hdf5
