This is not a complete solution, but a cross-platform (Windows, Mac, Linux) tool for creating packages for automatic updates and their installation is available at https://github.com/mendeley/Update-Installer . This tool does not publish updates or download them.
This was written for use with a Qt-based application, but to make the update installer small, standalone and easy to build, the installer uses only standard system libraries (C ++ runtime, pthreads / libz / libbz2 on Linux / Mac, Win32 API in Windows, Cocoa on Mac, GTK with Linux backup). This makes it easy to deliver updates that include new versions of Qt and other non-system libraries that your application depends on.
Before considering this, I would suggest:
- If you build only two platforms, consider using standard and proven automatic update frameworks for these platforms - for example.
Sparkle on Mac, Google Omaha on Windows, or automatic update systems built into popular installations (e.g. InstallShield). I have not tried BitRock. - The Mac Mac App Store may be a good option. However, see https://bugreports.qt.io/browse/QTBUG-16549 .
- On Linux, consider creating a .deb package and a simple repository to host it. After users have the repository installed, system-wide software update tools will take care of checking and installing new releases. However, the steps to create a new repository are too complex for many new Ubuntu / Debian users. What we did, as well as what Dropbox and Google did, was to create a .deb package that installs the repository as part of the package installation.
A few other notes on creating the update:
- In Windows Vista / 7, if the application is installed in system-wide mode (for example, in C: \ Program Files \ $ APPNAME), your users will see a scary UAC prompt when the updater tries to get write permissions to the installation directory. This can be avoided either by installing in a directory accessible to the user (I understand that this is what Google Chrome does) or by obtaining an Authenticode certificate and using it to sign the updater binary.
- In Windows Vista / 7, an .exe or DLL application cannot be removed if it is used, but the updater can move the existing .exe / DLL from the outside to a temporary directory and designate it to be deleted the next time it reboots.
- In Ubuntu, third-party repositories are disabled after distribution updates. Google works around this, creating a cron job to re-add the repository, if necessary.
Robert Knight Sep 11 '11 at 12:03 2011-09-11 12:03
source share