Building Your Own NVIDIA DRIVE CX Image

Qt Automotive Suite is built on top of the Boot to Qt software stack for embedded Linux systems. Boot to Qt for embedded Linux is built using the tools and resources from the Yocto Project, and is based on Yocto's reference distribution. You can use the same tools to build custom Boot to Qt images, and have control over which packages are included in the build and how the software stack is configured.

To build your own NVIDIA DRIVE CX image, follow the steps in this topic. For more information about building the Boot to Qt image, see Building Your Own Embedded Linux Image.

Note: Building your own NVIDIA DRIVE CX image is supported only in Linux.


You should be familiar with the Yocto tools and the concept of recipes. For more information, see Yocto Project Documentation for the Latest Release.

Your Qt Automotive Suite installation must include Yocto meta layer components. To install those, select Qt Automotive Suite > Qt for Automotive Software Stack > Components > Yocto meta layer in the Qt online installation wizard.

After a successful installation, you will find the Yocto meta layer under the path <Qt installation directory>/<Qt version>/Automotive/sources/meta-boot2qt.

Install dependencies for the Yocto tools. In Ubuntu, the following packages are required:

sudo apt-get install gawk curl git-core diffstat unzip p7zip-full texinfo \
gcc-multilib build-essential chrpath libsdl1.2-dev xterm gperf bison \

Download NVIDIA DRIVE CX Platform Development Kit (PDK) from the NVIDIA site. In order to get access to PDK, you need a valid NVIDIA license. For more information, see NVIDIA DRIVE™ CX. The required PDK version is

Setting Up Build Environment

Set up the NVIDIA DRIVE CX build environment:

  1. Extract the following packages from NVIDIA DRIVE CX PDK:
  2. For installing the documentation, run the following command in a terminal:

    After running the command, the NVIDIA DRIVE CX documentation should be started automatically.

  3. In the NVIDIA DRIVE CX documentation, open the topic System Programming > Building the Yocto Project Based Components and extract all defined prerequisite packages.
  4. Extract the following package:
    <PDK installation directory>/vibrante-t186ref-linux-
  5. Create a new directory for building the image. In our example, we use the directory name builddir.
  6. Run the following commands in a terminal:
    cd builddir
    <Qt Automotive Suite installation directory>/<Qt version>/Automotive/sources/meta-boot2qt/b2qt-init-build-env init --device tegra-t18x

    After running the commands, you should have:

    • A directory sources generated under builddir.
    • A shell script generated under builddir.
  7. Create the following symbolic links:
A symbolic link nameA source folder pathA destination folder path
nvidia-layer<PDK installation directory>/vibrante-t186ref-linux-
vibrante-t186<PDK installation directory>/vibrante-t186ref-linux-

builddir is the directory that you created for building the image.

Configuring Build Environment

Configure the build environment for NVIDIA DRIVE CX by running the following commands in a terminal:

cd builddir
export MACHINE=tegra-t18x
source ./

builddir is the directory you created for building the image.

After running, your current directory in a terminal is builddir/build-tegra-t18x. There you can build an image and/or a toolchain for NVIDIA DRIVE CX. The toolchain can be used with Qt Creator for building Qt applications.

Building Image

Build the NVIDIA DRIVE CX image by running the following commands in a terminal:

cd builddir/build-tegra-t18x
bitbake b2qt-automotive-qt5-image

You will find the built image file b2qt-automotive-qt5-image-tegra-t18x.7z under the path builddir/tmp/deploy/images/tegra-t18x.

Building Toolchain

Build the NVIDIA DRIVE CX toolchain by running the following commands in a terminal:

cd builddir/build-tegra-t18x
bitbake meta-toolchain-b2qt-automotive-qt5-sdk

After building the toolchain, you will find the shell script under the path builddir/tmp/deploy/sdk/. Install the toolchain by running the shell script.

Using Toolchain

After installing the toolchain, you can use it with or without Qt Creator.

If you are using the toolchain with Qt Creator, you need to configure Qt Creator for the toolchain. See Configuring Qt Creator. If you are using the toolchain without Qt Creator, see Using Toolchain without Qt Creator.

© 2018 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.