Problem Building QGC in Visual Studio using QT

We discussed this via DM and seem to have solved the issue.

Installation Instructions

The latest master was updated to Qt 5.15 very recently, and the build docs unfortunately haven’t yet been updated to match. On a fresh Windows machine, the steps I took were as follows:

  1. Downloaded and installed git
  2. Downloaded and installed Visual Studio Community 2019 64-bit
  3. Downloaded and installed the “Desktop Development with C++” compiler
  4. Downloaded and run Qt Online Installer
  5. Downloaded and installed Qt 5.15.2 MSVC 2019 64-bit, and Qt Charts (I don’t need to build for Android)
  6. Downloaded and done the “Complete” install for both gstreamer and gstreamer-devel msvc-x86_64-1.18.1 64 bit
  7. Git cloned the sources of the qgroundcontrol repo and updated the submodules
  8. Opened Qt Creator
  9. Gone to File/Open and navigated to qgroundcontrol\qgroundcontrol.pro
  10. Configured it as Qt 5.15 MSVC 2019 64-bit
  11. Pressed the green play button to build and open

Perhaps of particular note are steps 8 through 11. Visual Studio (from step 2) is ONLY used for getting the relevant compilers (step 3). Actually building QGC should be done through Qt Creator.

Old Versions

If you for some reason happen to want to build an old version (instead of working off the latest master) then the relevant changes are

  1. Downloaded and installed Visual Studio Community 2017 64-bit (requires making a free account)

  1. Downloaded and installed Qt 5.12.6 MSVC 2017 64-bit, and Qt Charts (Android ARMv7 optional)

  1. Clone the sources, but checkout the desired commit/tag/branch before updating submodules - f2d0b8c is the last commit the day before the Qt 5.15 changeover, and v4.1.4 is the last tag before it

  1. Configured it as Qt 5.12.6 MSVC 2019 64-bit
    for the old Qt 5.12.6 option)
1 Like