Fatal error: cuda_runtime_api.h: No such file or directory

Please provide the following info (check/uncheck the boxes after creating this topic):
Software Version
DRIVE OS Linux 5.2.6
DRIVE OS Linux 5.2.0
DRIVE OS Linux 5.2.0 and DriveWorks 3.5
NVIDIA DRIVE™ Software 10.0 (Linux)
NVIDIA DRIVE™ Software 9.0 (Linux)
other DRIVE OS version

Target Operating System

Hardware Platform
NVIDIA DRIVE™ AGX Xavier DevKit (E3550)
NVIDIA DRIVE™ AGX Pegasus DevKit (E3550)

SDK Manager Version

Host Machine Version
native Ubuntu 18.04

When trying to do a cross compilation to compile TensorRT sample to run on target (AGX DRIVE). I have the following error :

Dear @mohammed.el-yaagoubi,
Have you checked cross compilation instructions at https://docs.nvidia.com/drive/drive-os- ?
Also, please find path of cuda_runtime_api.h on your host for confirmation.

Here is the path of cuda_runtime_api.h on my host machine :

Hi @mohammed.el-yaagoubi,

Did you compile on the host with the host components of DRIVE OS 5.2.0 installed (via SDK Manager)?

Yes and when running make TARGET=aarch64 I have the following error :

Does your /usr/local/cuda link to correct cuda toolkit path?

$ ls -l /usr/local/cuda
lrwxrwxrwx 1 root root 9 Sep 8 05:17 /usr/local/cuda → cuda-10.2

Didn’t you already clarify a similar problem in Hello World Application on DRIVE AGX?

I don’t have this file

For that problem I installed cuda once again properly and it worked but now for the cross compilation I have the same error

You don’t need to install cuda manually. All necessary components were installed in SDK Manager.

Please see if setting the environment variable CUDA_INSTALL_DIR (mentioned in TensorRT Installation Instructions :: DRIVE Platform Installation Guide with NVIDIA SDK Manager) will help.

Or I would suggest you run through the host component installation of DRIVE OS 5.2.0 in SDK Manager (target isn’t needed) again.