Home
Support

Knowledge Base

BSPs and drivers
Community resources
Product documentation
Questions?
Contact us

Importing CMake projects in Momentics IDE
 
________________________________________________________________________

Applicable Environment
________________________________________________________________________
  • Topic: Importing CMake projects in Momentics IDE
  • SDP: 7.0.0, 7.1.0
  • Host/Target: Supported Linux host
________________________________________________________________________

Issue
________________________________________________________________________

CMake is not officially supported by the QNX SDP toolchain, but we do support importing makefiles.

If you want to import CMake projects into Momentics IDE, the following instructions work on Linux-based Host OS, i.e. Ubuntu.

________________________________________________________________________

Recommendation
________________________________________________________________________

You can use the attached script (qnx.nto.toolchain.cmake) to generate the appropriate CMake files (i.e. Makefile, etc).

$ cd /your-path/work-dir-with-source-files
$ cmake -DCMAKE_TOOLCHAIN_FILE=/your-path/qnx.nto.toolchain.cmake

Afterward, you can import "/your-path/work-dir-with-source-files" into QNX Momentics IDE (Linux-based Host OS).

  1. Switch to C/C++ perspective view
  2. Click "File" -> "Import..."
  3. Select "Existing Code as Makefile Project" -> click "Next >"
    • In "Project Name", enter preferred name
    • In "Existing Code Location", click "Browse..." -> locate "/your-path/work-dir-with-source-files" -> click OK
    • In "Toolchain for Indexer Settings", select "<none>"
    • Click Finish button
  4. In the Project Explorer (Momentics IDE left side pane), you should be able to see your imported project
  5. Right click project name -> "Build Project"
    • ** Sometimes "Build Project" is disabled/grayed out. Please restart your Momentics IDE so that it becomes enabled.

________________________________________________________________________
NOTE: This entry has been validated against the SDP version listed above. Use caution when considering this advice for any other SDP version. For supported releases, please reach out to QNX Technical Support if you have any questions/concerns.
________________________________________________________________________


Related Attachments
 Attachment Name Size Last Modified
 qnx.nto.toolchain.cmake 4KB 12/2/2020 2:14 PM





Please contact us with your questions or concerns.