Scanning dependencies of target caffe.bin
[ 89%] Building CXX object tools/CMakeFiles/caffe.bin.dir/caffe.cpp.o
Linking CXX executable caffe
../lib/libcaffe.so: undefined reference to H5LTget_dataset_ndims'
../lib/libcaffe.so: undefined reference toH5Fcreate'
../lib/libcaffe.so: undefined reference to H5LTread_dataset_int'
../lib/libcaffe.so: undefined reference toH5Fclose'
../lib/libcaffe.so: undefined reference to H5Gclose'
../lib/libcaffe.so: undefined reference toH5check_version'
../lib/libcaffe.so: undefined reference to H5LTfind_dataset'
../lib/libcaffe.so: undefined reference toH5Lget_name_by_idx'
../lib/libcaffe.so: undefined reference to H5Lexists'
../lib/libcaffe.so: undefined reference toH5Gcreate2'
../lib/libcaffe.so: undefined reference to H5LTmake_dataset_double'
../lib/libcaffe.so: undefined reference toH5LTmake_dataset_int'
../lib/libcaffe.so: undefined reference to H5LTread_dataset_float'
../lib/libcaffe.so: undefined reference toH5LTmake_dataset_float'
../lib/libcaffe.so: undefined reference to H5LTget_dataset_info'
../lib/libcaffe.so: undefined reference toH5LTread_dataset_string'
../lib/libcaffe.so: undefined reference to H5Gget_info'
../lib/libcaffe.so: undefined reference toH5Gopen2'
../lib/libcaffe.so: undefined reference to H5LTread_dataset_double'
../lib/libcaffe.so: undefined reference toH5Fopen'
../lib/libcaffe.so: undefined reference to `H5LTmake_dataset_string'
collect2: error: ld returned 1 exit status
tools/CMakeFiles/caffe.bin.dir/build.make:111: recipe for target 'tools/caffe' failed
make[2]: ** [tools/caffe] Error 1
CMakeFiles/Makefile2:406: recipe for target 'tools/CMakeFiles/caffe.bin.dir/all' failed
make[1]: ** [tools/CMakeFiles/caffe.bin.dir/all] Error 2
Makefile:117: recipe for target 'all' failed
make: *** [all] Error 2
Fixed it by
$ sudo cp /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5.so /usr/local/lib/libhdf5.so
$ sudo cp /usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_hl.so /usr/local/lib/libhdf5_hl.so
$ make
Closing this resolved usage/installation issue.
From https://github.com/BVLC/caffe/blob/master/CONTRIBUTING.md:
_Please do not post usage, installation, or modeling questions, or other requests for help to Issues._
Use the caffe-users list instead. This helps developers maintain a clear, uncluttered, and efficient view of the state of Caffe.
This is still a code issue and not a "usage/installation" one. Please reopen.
Hi, I edited the dependencies.cmake file with the edits you gave, but when I run makepkg the file gets overwritten again. How do I stop this?
@kwotsin: run makepkg -so (install deps & extract sources), patch sources, then run makepkg -ei (do not extract sources, build & install).
@longjon Hi, I have copied two files to the /usr/local/lib, but cannot solve this issue. Is there anything I have to pay attention to? Thank you so much.
Did you apply the patch from PR ( https://github.com/BVLC/caffe/pull/4516 ), @bragilee ?
I followed https://github.com/Fazecast/caffe/commit/942d22d075851a0c5735042308e72f8f739f40f5
provided above. It seems to work.
well...it doesn't work on me,
and I solved it by modifying the file
---[ HDF5
find_package(HDF5 COMPONENTS HL REQUIRED)
include_directories(SYSTEM ${HDF5_INCLUDE_DIRS} ${HDF5_HL_INCLUDE_DIR})
list(APPEND Caffe_LINKER_LIBS ${HDF5_LIBRARIES})
list(APPEND Caffe_LINKER_LIBS ${HDF5_HL_LIBRARIES}) #added
Most helpful comment
This is still a code issue and not a "usage/installation" one. Please reopen.