These days I am focusing on compling caffe in Ubuntu14.04
And I met some problems and fixed them in the end.
Now is the list about problems:
here is 2 parts of the setup-files and I followed them.
http://download.csdn.net/detail/znmax1217/9475850
http://download.csdn.net/detail/znmax1217/9475852
1. about add PATH problems
it said like this:
$ sudo gedit /etc/bash.bashrc
在结尾处添加内容:
export PATH=/usr/local/cuda-7.5/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/cuda-7.5/lib64:${LD_LIBRARY_PATH}
but fails when we check PATH like this:
echo $PATH
so we edit the file without "export" at the end of "bash.bashrc"
PATH=/usr/local/cuda-7.5/bin:$PATH
LD_LIBRARY_PATH=/usr/local/cuda-7.5/lib64:${LD_LIBRARY_PATH}
then we update, re-edit the file and delete the last 2 lines:
$ source /etc/bash.bashrc
2. setup samples:
We need to setup the samples in /usr/local/cuda/
actually just find the .sh file:
$ cuda-install-samples-7.5.sh <dir>
3. facing the problem about gpu-version
how to check if gpu fit:
cd /usr/local/cuda/samples/bin/x86_64/linx/release
sudo ./deviceQuery
sudo dpkg --list | grep nvidia-*
if it said "FAILED" with "is insuffiencient"
then maybe the cuda version is not fit nvidia version:cuda 6.5 ->nvidia-340
cuda 7.5 ->nvidia-352
so coded like this:
sudo apt-get --purge remove nvidia-*
and then we find nvidia-352 in "software & update"
4. "Unknown Mex ..." ... ERROR 255 ... "-o"
when we :
sudo make matcaffe -j8
so 2 steps:
A. check gcc version & g++
gcc -v
if it is 4.8.* or even better, then we download 4.7 version and overlap them
B. still cannot
then
re-edit Makefile like this:
http://download.csdn.net/detail/znmax1217/9475853
change CXXLIBS="\$$CXXLIBS $(LDFLAGS)" -o $@
to CXXLIBS="\$$CXXLIBS $(STATIC_NAME) $(LDFLAGS)" -output $@