caffe icon indicating copy to clipboard operation
caffe copied to clipboard

Library not loaded: @rpath/libcudart.6.5.dylib

Open DenisTome opened this issue 12 years ago • 6 comments

when i execute make runtest on Mac OS X 10.9, this is the error that i get:

dyld: Library not loaded: @rpath/libcudart.6.5.dylib Referenced from: /Users/denntom/Dropbox/DeepLearning/caffe - master/.build_release/test/test_all.testbin Reason: image not found make: *** [runtest] Trace/BPT trap: 5

I've reinstalled Cuda and checked that the library was there, but the error is the same.

DenisTome avatar Oct 14 '14 10:10 DenisTome

hi, @DenisTome, i've also met the similar output error when executing the matcaffe_demo.mat: ( OS X 10.9, Matlab 2014a) Invalid MEX-file '/path/to/caffe/matlab/caffe/caffe.mexmaci64': dlopen(/path/to/caffe/matlab/caffe/caffe.mexmaci64,6): Library not loaded: @rpath/libcurand.6.5.dylib Referenced from: /path/to/caffe/matlab/caffe/caffe.mexmaci64 Reason: image not found

the libcurand.6.5.dylib is in the cuda library files, at first look, i thought the $LID_LIBRARY_PATH, or $LD_PRELOAD dose not include cuda library, but double check, it was there.

the "make matcaffe" step runs successfully.

also, there's a tip in the matcaffe_demo.mat file: % You may need to do the following before you start matlab: % $ export LD_LIBRARY_PATH=/opt/intel/mkl/lib/intel64:/usr/local/cuda-5.5/lib64 % $ export LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libstdc++.so.6 % Or the equivalent based on where things are installed on your system

i am not sure as to the corresponding path in OS.

anybody's solution??? thanks

hli2020 avatar Oct 14 '14 15:10 hli2020

Set your DYLD_FALLBACK_LIBRARY_PATH with the library dirs needed by Caffe.

On Tuesday, October 14, 2014, Hongyang Li [email protected] wrote:

hi, @DenisTome https://github.com/DenisTome, i've also met the similar output error when executing the matcaffe_demo.mat: ( OS X 10.9, Matlab 2014a) Invalid MEX-file '/path/to/caffe/matlab/caffe/caffe.mexmaci64': dlopen(/path/to/caffe/matlab/caffe/caffe.mexmaci64,6): Library not loaded: @rpath/libcurand.6.5.dylib Referenced from: /path/to/caffe/matlab/caffe/caffe.mexmaci64 Reason: image not found

the libcurand.6.5.dylib is in the cuda library files, at first look, i thought the $LID_LIBRARY_PATH, or $LD_PRELOAD dose not include cuda library, but double check, it was there.

the "make matcaffe" step runs successfully.

also, there's a tip in the matcaffe_demo.mat file: % You may need to do the following before you start matlab: % $ export LD_LIBRARY_PATH=/opt/intel/mkl/lib/intel64:/usr/local/cuda-5.5/lib64 % $ export LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libstdc++.so.6 % Or the equivalent based on where things are installed on your system

i am not sure as to the corresponding path in OS.

anybody's solution??? thanks

— Reply to this email directly or view it on GitHub https://github.com/BVLC/caffe/issues/1273#issuecomment-59067842.

Evan Shelhamer

shelhamer avatar Oct 14 '14 16:10 shelhamer

@shelhamer, did i miss something? export DYLD_FALLBACK_LIBRARY_PATH=/path/to/anaconda/lib:/usr/local/lib:/usr/lib:/Developer/NVIDIA/CUDA-6.5/lib:$DYLD_FALLBACK_LIBRARY_PATH

thanks

hli2020 avatar Oct 14 '14 16:10 hli2020

Double check your environment variables, make clean, and then make && make test && make runtest again.

Please ask about installation on the caffe-users mailing list. Issues are for development discussion. Thanks!

shelhamer avatar Oct 15 '14 05:10 shelhamer

@DenisTome Sorry for opening this issue, but couldn't find answer in google group. I am having the same problem. make runtest results- .build_release/tools/caffe dyld: Library not loaded: @rpath/libcudart.7.0.dylib Referenced from: /Users/deepsamal/Desktop/Research/caffe/.build_release/tools/caffe Reason: image not found make: *** [runtest] Trace/BPT trap: 5

I think I have loaded all variables- echo $DYLD_FALLBACK_LIBRARY_PATH /Users/deepsamal/anaconda/lib:/usr/local/lib:/usr/lib:/usr/local/cuda/lib/:/Users/deepsamal/Desktop/Research/cudnn-6.5-osx-v2/:/opt/intel/composer_xe_2015.2.132/mkl/lib/:

deepsamal avatar Apr 16 '15 00:04 deepsamal

If I remove 'sudo' that prefixes 'make', the error disappears...but I have no idea why.

cntswj avatar Aug 09 '15 00:08 cntswj