Blog of Raivo Laanemets

Stories about web development, freelancing and personal computers.

KAM migrated to Qt 5


On some recent times I have been working on getting KAM to build with Qt 5. I made some test builds in Spring but I hope that a more recent version of Qt 5 will solve some reported crashes on Windows 8. For this to happen the code and the build scripts of KAM had to be upgraded to work with Qt 5. The main problem has not been the code but installer scripts and build environments.

The most trouble came from Mac OS X. The current build system had too old OS X version installed which was not supported by Qt 5 (too old XCode?). Apple's official policy of not allowing OS X to run on non-Mac hardware is also not making it easier. While not officially permitted it is still possible to run it on generic x86/x64 hardware thanks to the awesome OSX86 and iAtkos projects. Qt for OS X comes with the macdeployqt tool which requires no specific installer scripts to create an app bundle and a .dmg file. All dependencies are resolved and bundled automatically.

Compared to OS X, a Windows build machine is considerably easier to set up and can be run in a virtual machine (such as VirtualBox). Some tools like curl are not initially installed in Windows and do not come with Qt either. These have to be installed separatedly. PATH has to be set up. A bit of manual work.

Windows Qt comes with no tool like macdeployqt. This means that installer has to be created with some 3rd party tool. We use NSIS and NSIS is fine but requires one to learn its scripting language. There is no automatic dependency resolution. All necessary DLL files have to be found manually with the 3rd party Dependency Walker tool. Our build process on Windows is coordinated by a Batch file. Batch scripts have no sane way of detecting errors in commands unless you check for error after each command. This makes scripts either verbose or error prone.

Linux is my main system. Everything mostly just works and there are no stupid installation restrictions. Getting Qt 5 installed and code building with it was the easiest. However, dependencies still had to be collected manually. For KAM we currently just build and distribute a tarball. But once this release gets fully tested we will release a .deb package.

The release also means I will be less involved in the development of KAM in future.


No comments have been added so far.

Email is not displayed anywhere.
URLs (max 3) starting with http:// or https:// can be used. Use @Name to mention someone.