Ubuntu18.04下编译Caffe-GPU时,在终端执行:

sudo make runtest -j16  

出现以下错误:

.build_release/tools/caffe
.build_release/tools/caffe: error while loading shared libraries: libhdf5_hl.so.100: cannot open shared object file: No such file or directory
Makefile:545: recipe for target 'runtest' failed
make: *** [runtest] Error 127

错误原因:找不到动态链接库.


解决方法:
该方法可以解决:error while loading shared libraries: libhdf5_hl.so.XXX: cannot open shared object file: No such file or directory的错误。
进入/etc/ld.so.conf.d目录.

/etc/ld.so.conf.d

创建anaconda3.conf

touch anaconda3.conf

打开anaconda3.conf文件.

sudo vim anaconda3.conf	//打开文件
输入以下内容:
/home/user/anaconda3/lib

在vim命令行执行 wq 命令.
在终端执行:

sudo ldconfig

在caffe目录下运行:

sudo make runtest -j16 

完美解决错误:libhdf5_hl.so.100(XXX): cannot open shared object file: No such file or directory,Error127
编译通过~!

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-15
  • 2021-08-14
  • 2021-08-20
  • 2021-10-29
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-08-04
  • 2022-12-23
相关资源
相似解决方案