2

I went through the doc and what I could find, but there is an inherent issue to distribute Qt5 application.

Static linking is not a solution in my case, as it contains several binaries it would take much space.

The problem arise if the user has different Qt5 libraries on its system, it makes impossible to distribute Qt5 lib on libraries folder without taking the risk of breaking existing Qt5 software that may run on another version.

The solution is to deploy the lib on a specific folder "/usr/lib/software" and compile the software with rpath directive, but once again, the problem arise with the dependencies of the Qt lib themselves which weren't compiled with rpath.

A quick and dirty solution would be to have a startup script setting the LD_LIBRARY_PATH to the "/usr/lib/software" but it doesn't look very clean.

Another solution perhaps is to recompile the whole Qt library with the rpath.

Is there another solution to this problem ?

Damien
  • 1,492
  • 10
  • 32
  • Assuming you're talking about desktop Linux, these days you have the option of using Flatpak or Snap packages (similar to an app bundle on Mac OS) where the package includes your executable as well as all required dynamic libraries. This technology is still new, but I believe Flatpak has wider support across distros at the moment. – MrEricSir Aug 31 '17 at 03:38
  • @MrEricSir it looks neat but require additional software that might not be available on clients. – Damien Aug 31 '17 at 05:21
  • For the ones interested so far the solution was a shell script setting LD_LIBRARY_PATH and using a app.desktop files as starting point for the user. – Damien Sep 05 '17 at 09:56

0 Answers0