Writing the app descriptor file

After your project is set up, you can package the Qt app in a BAR file so it can be deployed onto a QNX Apps and Media target. The package must contain an app descriptor file, which is an XML file specifying various configuration and application settings.

Note: These instructions show how to define an app descriptor file using Qt Creator but you can manually write this file using whatever editing tool you want.
To write an app descriptor file in Qt Creator:
  1. Click the Edit icon on the left side, right-click the QtApp folder in the Projects view, then choose Add New...
  2. In the New File dialog, select General in the Files and Classes list, then Text file in the list of file types (shown in the middle), then click Choose...
  3. In the Location page of the New Text file dialog, name the file bar-descriptor.xml, then click Next.
  4. In the Summary page, click Finish.

    The bar-descriptor.xml file is opened for editing.

  5. Copy and paste the following content into the new file:
    <?xml version='1.0' encoding='UTF-8' standalone='no'?>
    <qnx xmlns="http://www.qnx.com/schemas/application/1.0">
        <name>Qt App</name>
        <description>The Hello World Qt demo app.</description>
        <author>My Company Inc.</author>
        <permission system="true">run_native</permission>
        <env var="QQNX_PHYSICAL_SCREEN_SIZE" value="150,90"/>
        <asset type="Qnx/Elf" path="QtApp" entry="true">QtApp</asset> 

    The app-descriptor file defines the app name, description, icon file, and other fields that contain authoring information and settings for the initial window. It also sets the QQNX_PHYSICAL_SCREEN_SIZE environment variable, which defines the height and width of the app's display area. Finally, the app descriptor file also provides asset information, including the binary file path and format.