1

Output for 'make all'

[root@parags-pc caffe]# make all

CXX src/caffe/layers/batch_norm_layer.cpp
CXX src/caffe/layers/sigmoid_layer.cpp
CXX src/caffe/layer.cpp
CXX src/caffe/layer_factory.cpp
CXX src/caffe/data_transformer.cpp
AR -o .build_release/lib/libcaffe.a
LD -o .build_release/lib/libcaffe.so
/usr/bin/ld: cannot find -lcblas
/usr/bin/ld: cannot find -latlas
collect2: error: ld returned 1 exit status
Makefile:544: recipe for target '.build_release/lib/libcaffe.so' failed
make: *** [.build_release/lib/libcaffe.so] Error 1
[root@parags-pc caffe]#

I have been trying to install caffe on fedora 21 with little success. On running the following make command I get the errors as given in the screenshot.

I have tried the following to fix this but have had no success.

[root@parags-pc caffe]# export LDFLAGS=-L/lib64/atlas/
[root@parags-pc caffe]# ld -lcblas --verbose
==================================================
attempt to open /usr/x86_64-redhat-linux/lib64/libcblas.so failed
attempt to open /usr/x86_64-redhat-linux/lib64/libcblas.a failed
attempt to open /usr/local/lib64/libcblas.so failed
attempt to open /usr/local/lib64/libcblas.a failed
attempt to open /lib64/libcblas.so failed
attempt to open /lib64/libcblas.a failed
attempt to open /usr/lib64/libcblas.so failed
attempt to open /usr/lib64/libcblas.a failed
attempt to open /usr/x86_64-redhat-linux/lib/libcblas.so failed
attempt to open /usr/x86_64-redhat-linux/lib/libcblas.a failed
attempt to open /usr/lib64/libcblas.so failed
attempt to open /usr/lib64/libcblas.a failed
attempt to open /usr/local/lib/libcblas.so failed
attempt to open /usr/local/lib/libcblas.a failed
attempt to open /lib/libcblas.so failed
attempt to open /lib/libcblas.a failed
attempt to open /usr/lib/libcblas.so failed
attempt to open /usr/lib/libcblas.a failed
ld: cannot find -lcblas
[root@parags-pc caffe]# 

The contents of /lib64/atlas/ are as shown below I am not sure though if these are the required libraries.

[root@parags-pc caffe]# ls /lib64/atlas/
libsatlas.so.3  libsatlas.so.3.10  libtatlas.so.3  libtatlas.so.3.10

Google say's to make use of -L to link command. But I don't know which command should be used, how that command is to be used and which libraries should be linked. I need help please. Thanks!

Parag
  • 655
  • 4
  • 7
  • 19
  • Hi @Parag, wondering if you found a way to resolve the issue? I'm just trying to get caffe to run but am spending my nights away to no avail :\ – JP_smasher Mar 28 '16 at 15:02
  • Hey I switched to Ubuntu 15 and that solved the errror for me. Had very less time and didn't wanted to waste it on installation errors. – Parag Apr 14 '16 at 11:12

2 Answers2

0
cd /lib64/atlas
sudo ln -s libtatlas.so /lib/libatlas.so
sudo ln -s libtatlas.so /lib/libcblas.so

The new Atlas ver3 is bundled with both atlas and cblas. Thus there is no need to include both of them separately. Either you can follow the above method or remove calling the cblas library in your makefile.

Anoop K. Prabhu
  • 5,417
  • 2
  • 26
  • 43
  • Those three lines aren't solving the issue. Btw can you tell me how to remove calling the cblas library? Sorry, I am a newbie. – Parag Dec 12 '15 at 11:37
0

I think the reason is you use make to compile, which makes caffe's python port only find libraries in this catalog. Maybe you use cmaketo compile and it could work.

$make clean
$cd caffe-master
$mkdir build
$cd build
$cmake ..
$make all -j8

I hope I could help you!