Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

g++ cannot find cuda_runtime.h #841

Closed
kelvinxu opened this issue Aug 3, 2014 · 3 comments

Comments

Projects
None yet
3 participants
@kelvinxu
Copy link

commented Aug 3, 2014

I followed in instructions on the installation page and upon running make all I receive.


/usr/bin/g++ src/caffe/blob.cpp -pthread -fPIC -DNDEBUG -O2 -I/usr/include/python2.7 -I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/local/include -Ibuild/src -I./src -I./include -I/pkgs_local/cuda-5.5 -I/include -c -o build/src/caffe/blob.o
src/caffe/blob.cpp:3:26: fatal error: cuda_runtime.h: No such file or directory
compilation terminated.
make: *** [build/src/caffe/blob.o] Error 1


The file cuda_runtime is sitting in /pkgs_local/cuda-5.5/include, but it seems that it cannot be found.

Thanks in advance,
Kelvin

@netheril96

This comment has been minimized.

Copy link
Contributor

commented Aug 3, 2014

Apparently you didn't set the variables in Make.config right.

@kelvinxu

This comment has been minimized.

Copy link
Author

commented Aug 3, 2014

I seem to have gotten around it by adding /pkgs_local/cuda-5.5/include explicitly to the INCLUDE_DIRS variable.

Seems weird that this is necessary based on the Makefile.

@Yangqing

This comment has been minimized.

Copy link
Member

commented Aug 3, 2014

You may be using a different cuda install approach than the default one in ubuntu - the Makefile.config assumes /usr/local/cuda/, so this is causing the problem.

Glad that this issue is solved :)

@Yangqing Yangqing closed this Aug 3, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.