跑步时
make pycaffe
我们最终会缺少hdf5
库。
CXX/LD -o python/caffe/_caffe.so python/caffe/_caffe.cpp
/usr/bin/ld: cannot find -lhdf5_hl
/usr/bin/ld: cannot find -lhdf5
collect2: error: ld returned 1 exit status
Makefile:502: recipe for target 'python/caffe/_caffe.so' failed
make: *** [python/caffe/_caffe.so] Error 1
请注意,这些库的每个可能的组合都已安装在此ubuntu 15.10
系统上。
$ dpkg --get-selections | grep hdf5
hdf5-helpers install
libhdf5-10:amd64 install
libhdf5-cpp-10:amd64 install
libhdf5-dev install
libhdf5-mpi-dev install
libhdf5-mpich-10:amd64 install
libhdf5-mpich-dev install
libhdf5-openmpi-10:amd64 install
libhdf5-openmpi-dev install
libhdf5-serial-dev install
现在我意识到这太过分了..但是一次添加了一个-然后我们make pycaffe
在添加另一个之前重试了..我们只是想确保丢失的hdf5库不是核心问题。
更新响应@jon提供的答案
dpkg -L libhdf5-dev | grep so
/usr/lib/x86_64-linux-gnu/libhdf5_cpp.so
/usr/lib/x86_64-linux-gnu/libhdf5_serial.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_cpp.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_hl.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_fortran.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5_hl_cpp.so
/usr/lib/x86_64-linux-gnu/hdf5/serial/libhdf5hl_fortran.so
/usr/lib/x86_64-linux-gnu/libhdf5_hl_cpp.so
/usr/lib/x86_64-linux-gnu/libhdf5_serial_fortran.so
/usr/lib/x86_64-linux-gnu/libhdf5_serial_hl.so
/usr/lib/x86_64-linux-gnu/libhdf5_serialhl_fortran.so
并且在Makefile.config
:
LIBRARY_DIRS := /usr/opt/libsr $(PYTHON_LIB)
/usr/local/lib /usr/lib /usr/lib/x86_64-linux-gnu