2016-04-25 74 views
-1

沒有重新出口$ LD_LIBRARY_PATH,並沒有在.bashrc中的變量做任何事情,

echo $LD_LIBRARY_PATH 

回報

/usr/local/cuda/lib64 

然而,

$LD_LIBRARY_PATH 

回報

-bash: /usr/local/cuda/lib64:: No such file or dictionary 

然而,路徑確實存在。

什麼可能會出錯?

------ ----- EDIT

ls -ld /usr/local{,/cuda{,/*}} 

返回

drwxr-xr-x 16 root root 4096 Apr 10 17:07 /usr/local 
lrwxrwxrwx 1 root root 19 Sep 16 2015 /usr/local/cuda -> /usr/local/cuda-7.5 
drwxr-xr-x 3 root root 4096 Sep 16 2015 /usr/local/cuda/bin 
drwxr-xr-x 5 root root 4096 Sep 16 2015 /usr/local/cuda/doc 
drwxr-xr-x 4 root root 4096 Sep 16 2015 /usr/local/cuda/extras 
drwxr-xr-x 5 root root 4096 Sep 16 2015 /usr/local/cuda/include 
drwxr-xr-x 5 root root 4096 Sep 16 2015 /usr/local/cuda/jre 
drwxr-xr-x 2 root root 4096 Sep 16 2015 /usr/local/cuda/lib 
drwxr-xr-x 3 root root 4096 Sep 16 2015 /usr/local/cuda/lib64 
drwxr-xr-x 8 root root 4096 Sep 16 2015 /usr/local/cuda/libnsight 
drwxr-xr-x 7 root root 4096 Sep 16 2015 /usr/local/cuda/libnvvp 
drwxr-xr-x 7 root root 4096 Sep 16 2015 /usr/local/cuda/nvvm 
drwxr-xr-x 2 root root 4096 Sep 16 2015 /usr/local/cuda/pkgconfig 
drwxr-xr-x 11 root root 4096 Sep 16 2015 /usr/local/cuda/samples 
drwxr-xr-x 3 root root 4096 Sep 16 2015 /usr/local/cuda/share 
drwxr-xr-x 2 root root 4096 Sep 16 2015 /usr/local/cuda/src 
drwxr-xr-x 2 root root 4096 Sep 16 2015 /usr/local/cuda/tools 
-rw-r--r-- 1 root root 20 Sep 16 2015 /usr/local/cuda/version.txt 
+1

這與CUDA無關,所以我刪除了標籤 – talonmies

+2

如果您只需輸入'$ LD_LIBRARY_PATH',它將展開該變量,然後bash將嘗試運行它。你究竟在做什麼? –

+0

@JonathonReinhart我在跑咖啡時遇到了一個路徑問題,所以我想我可能會考慮它。在caffe上運行make runtest返回libcudart.so.6.0未找到 – ytrewq

回答

0

這個問題是通過修改Makefile.config如下解決:

/usr/local/cuda 

/usr/local/cuda-7.5