Deployment
This page describes how to back a compiled binary with all required libraries into a redistributable executable or installer.
Windows
We are using the Nullsoft Scriptable Install System (NSIS). There is a finished script in qgroundcontrol/deploy. To use it, follow these instructions:
- Install NSIS: http://nsis.sourceforge.net/Main_Page
- Please use Visual Studio to compile a redistributable to enable Google Earth support this will result in the executable being located in qgroundcontrol/release.
- Double-click qgroundcontrol.exe in the build folder to verify that you copied everything and it executes correctly
- IF YOU ENCOUNTER ERRORS: Consult the Qt 5.0 deployment guide (assuming you build for Qt 5.x and not 4.x)
- Now change with Windows Explorer the directory to qgroundcontrol\deploy
- Right-click qgroundcontrol_installer and select Compile NSIS Script from the context menu
- After some time a new exe file named qgroundcontrol-win32.exe will show up in the deploy directory. This is your installer.
More information on NSIS:
Mac
Go to qgroundcontrol/deploy and execute the packing script. Make sure that you have installed the SDL framework in /Library/Frameworks/SDL.Framework.
cd qgroundcontrol/deploy sh mac_create_dmg.sh
You will end up with a qgroundcontrol.app and a qgroundcontrol.dmg file in the deploy directory. You can either redistribute the qgroundcontrol.dmg (recommended) or ZIP the qgroundcontrol.app. The QGroundControl project file is set up to build 32bit Mac binaries which can be executed on Mac OS X Leopard 10.5 and Mac OS X Snow Leopard 10.6. 64bit is currently (as of March 2011) problematic because the Google Earth plugin only loads with a 32bit executable. This will be however resolved as soon as possible.
More information on general OS X deployment:
Typical errors:
If the framework is missing / misspelled, you don't get a “file not found” error, but this rather non-intuitive error message:
stat() failed with errno=20
If you have an outdated Mac OS X SDK, you might run into this error message. Just update your OS X SDK and it should be fine:
unknown required load command 0x80000022
Ubuntu / Debian
mkdir qgroundcontrol-version cd qgroundcontrol-version/ #create package # have installed gpg key for mail address dh_make -e "mail@qgroundcontrol.org" -c gpl --createorig #edit files in newly appeared debian folder #add all files to be installed into directory # create folders named usr/bin . put executable in there # should look like: ls -R ./usr: bin share ./usr/bin: qgroundcontrol ./usr/share: applications pixmaps ./usr/share/applications: qgroundcontrol.desktop ./usr/share/pixmaps: qgroundcontrol.png # create binary debuild -b
It would be better if the package could be build from source directly…
