Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

All you're saying is that FOSS developers targeting Linux might[0] be able to lean on the generosity and hard work of Linux distro package maintainers.

That's great, but if you're a FOSS (or free as in beer) app developer targeting Qt on macOS or Windows you're choice is basically between shipping a bleeding edge version of Qt 6.x that will almost certainly cause regressions for your users, or ship a version of Qt 5.15 that almost certainly has known security vulnerabilities.

As an app developer bumping minor Qt versions on my users isn't something I want to do every other month, since doing so requires a lot of regression testing and user feedback. Most of the time I just want to roll in critical bug fixes (security issues, crashers, etc).

[0] In reality shipping Qt apps for Linux is really horrible. As you noted every distro is using a different version, so the users of your app don't all get the same experience unless you go to a herculean effort to bundle your own Qt build.



I guess we have a different definition of herculean, I just have a script that builds KDE's 5.15 branch statically and run find_package(Qt5) in my cmake


1. Static linking is legally troublesome if you're distributing binaries because under the terms of the LGPL you have to allow for re-linking of your application. See ringworld's sibling comment on the Zoom app.

2. Even if you static link, you still need to build Qt for every single distro you want to ship your app on. On Linux the Qt GUI library alone has over 40 shared library dependencies. There are also ABI issues. Things like AppImage can help but are pretty nasty.

3. It's a lot easier on Windows and macOS, where there are fewer system dependencies and Qt Company themselves provide bundling tools (windeployqt, macdeployqt) to bundle libraries with your application.


Regarding 2. that is false, I build everything on a CentOS 7 docker and my appimage just works on every distro from that era onwards (~2015). Hy do you say that it's pretty nasty ? It's the same packaging mechanism than on Mac and Windows, the app ships everything except libc.

There's a linuxdeployqt tool for appimaged - I've never used it but saw a fair amount of apps using it I guess it works ?


> unless you go to a herculean effort to bundle your own Qt build

Zoom ships their own copy of Qt in the Linux packages as an example, lives in /opt/zoom next to their code.


And this is a perfect example to show the complexity.

On Arch Linux:

- /usr/bin/zoom is a symlink to /opt/zoom/ZoomLauncher which does not link against Qt. Presumably this just sets LD_LIBRARY_PATH and spawns /opt/zoom/zoom

- /opt/zoom/zoom is the main zoom binary and when run under 'ldd' actually tries to load /usr/lib/libQt* (Qt 5.15 on my system). Running this binary directly doesn't work (Error: "opt/zoom/zoom: symbol lookup error: /opt/zoom/imageformats/libqsvg.so: undefined symbol: _ZdlPvm, version Qt_5")




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: