Choosing the version of the OS

Updated: May 06, 2022

Whether you're using the command line or the IDE, you can install multiple versions of QNX SDP and build programs for multiple versions of QNX Neutrino.

For information about how to use the IDE to choose the QNX Neutrino version for which you build programs, see the QNX Momentics IDE User's Guide.

If you are using the command line, you choose the QNX Neutrino version for which you build your programs by running or sourcing a script to set environment variables (see Environment variables below) for your command-line window.

The name of the script you run or source depends on the QNX Neutrino version for which you want to build programs. For instance, if you want to build a program for QNX Neutrino 7.1, you must run or source the script in the base directory where you installed QNX SDP 7.1 (either qnxsdp-env.bat or qnxsdp-env.sh, depending on your development host). For SDP 6.5, see QNX SDP 6.5 below.

The name of the script depends on the release and the development host:

Release Windows Linux Mac
QNX SDP 7.0 and more recent qnxsdp-env.bat qnxsdp-env.sh qnxsdp-env.sh
QNX SDP 6.6 qnx660-env.bat qnx660-env.sh Not supported
Note: In QNX SDP 6.6 or more recent, you need to set up the environment in every command-prompt window in which you want to run the tools.

QNX SDP 7.0 and more recent

Run or source the appropriate script:

where base_directory is where you installed QNX SDP.

QNX SDP 6.6

Run or source the appropriate script:

where base_directory is where you installed QNX SDP.

QNX SDP 6.5

In QNX SDP 6.5, installation is performed as an admin or root user, and a system profile sets up the QNX environment variables globally, so you only need to set environment variables if you have modified them; for example, if you changed them to build programs for another QNX Neutrino version.

To set environment variables in QNX SDP 6.5, run the qconfig utility from the QNX SDP 6.5 installation directory.

On Windows you can also use QWinCfg, a graphical front end for qconfig; for example, choose QNX Software Development Platform 6.5.0 > Configuration from the Start menu.

Environment variables

QNX Neutrino uses these environment variables to locate files on the host machine:

MAKEFLAGS
Include base_directory/target/qnx7/usr/include so that QNX Makefiles (e.g., qconfig.mk) are available.
PATH
Add QNX_HOST/usr/bin so that QNX tools are available on the command line.
QNX_CONFIGURATION_EXCLUSIVE
The location of the configuration files for the installed versions of QNX Neutrino 7.0 or later.
You need to set this variable only when the configuration files are located in a directory other than $HOME/.qnx or QNX_CONFIGURATION.
QNX_CONFIGURATION
The location of the configuration files for the installed versions of QNX Neutrino 6.6 or earlier.
QNX_HOST
The location of host-specific files.
QNX_TARGET
The location of target backends on the host machine.

Starting the IDE

To start the IDE:

You can also choose the build target if you're using the IDE; see Switching between SDKs in the Reference chapter of the IDE User's Guide.