fatal error: driver_types.h: No such file or directory

Greetings, I am having trouble with this error when I compile “make all” inside CAFFE<caffe. PLEASE let me know on what to do or what direction I should take. Thank you! I am installing Caffe on the Jetson Tx1 with CUDA 9.0.

I get this error:
CXX src/caffe/util/cudnn.cpp
In file included from ./include/caffe/util/cudnn.hpp:5:0,
from src/caffe/util/cudnn.cpp:2:
/usr/include/cudnn.h:63:26: fatal error: driver_types.h: No such file or directory
compilation terminated.
Makefile:581: recipe for target ‘.build_release/src/caffe/util/cudnn.o’ failed
make: *** [.build_release/src/caffe/util/cudnn.o] Error 1


This error is caused by cuDNN package installation.
Could you check if you have well-installed our cuDNN package first?
cuDNN package can be installed via JetPack directly.


Hello thanks for your response

How can I check that cuDNN was installed correctly?

Thanks for your help again


First, please check if you have cuDNN installed in the ‘/usr/lib/aarch64-linux-gnu’ folder.

ll /usr/lib/aarch64-linux-gnu/libcudnn*

lrwxrwxrwx 1 root root 29 Jul 23 09:27 /usr/lib/aarch64-linux-gnu/libcudnn.so -> /etc/alternatives/libcudnn_so
lrwxrwxrwx 1 root root 17 Nov 17 2017 /usr/lib/aarch64-linux-gnu/libcudnn.so.7 -> libcudnn.so.7.0.5
-rw-r–r-- 1 root root 246459256 Nov 17 2017 /usr/lib/aarch64-linux-gnu/libcudnn.so.7.0.5
lrwxrwxrwx 1 root root 32 Jul 23 09:27 /usr/lib/aarch64-linux-gnu/libcudnn_static.a -> /etc/alternatives/libcudnn_stlib
-rw-r–r-- 1 root root 249273640 Nov 17 2017 /usr/lib/aarch64-linux-gnu/libcudnn_static_v7.a

Then you can check cuDNN functionality with our official sample.

$ cp -r /usr/src/cudnn_samples_v7/ .
$ cd cudnn_samples_v7/mnistCUDNN/
$ make

cudnnGetVersion() : 7005 , CUDNN_VERSION from cudnn.h : 7005 (7.0.5)
Host compiler version : GCC 5.4.0
… …
Test passed!


I meet the the same problem when I try to install onnx-tensorrt:

/usr/include/cudnn.h:63:10: fatal error: driver_types.h: No such file or directory
 #include "driver_types.h"

test cudnn funtion, it show “Test passed”.

$ cp -r /usr/src/cudnn_samples_v7/ .
$ cd cudnn_samples_v7/mnistCUDNN/
$ make

Any idea?


Getting the same error as zjh.2008.09 when trying to compile onnx-tensorrt

I’m using this image

Terveisin, Markus


Problem probably solved, see

So there must be explicit include dirs…:

cmake … -DTENSORRT_ROOT=/usr/src/tensorrt -DGPU_ARCHS=“53” -DCUDA_INCLUDE_DIRS=/usr/local/cuda-10.0/include

terveisin, Markus

Good to know this.
Thanks for the update.