Jøger Hansegård e2fbb431cb Deploy FFmpeg dlls with windeployqt
When we add support for dynamically linked FFmpeg, some FFmpeg libraries
will be available in the bin directory. windeployqt should then copy
these libraries to the application directory if the ffmpeg media backend
is included.

This patch extends windeployqt with support for deploying these FFmpeg
libraries.

Potential issues:

1. This patch hard codes the FFmpeg library names that we currently
   depend on, such as 'avcodec' or 'swresample'.
2. We don't take version number of the FFmpeg libs into account. This is
   done to reduce the maintenance burden when we upgrade FFmpeg, and
   should not be a problem as long as we have a single version of FFmpeg
   in the online installer.
3. Finding the library names is a bit quadratic in complexity, bound by
   the number of libraries in the bin folder, but should not be too
   slow.
4. We need to update windeployqt if we add or remove ffmpeg libraries.

An alternative would be to identify all dlls that the ffmpeg media
plugin depends on, and then deploy all files that exists in the bin
directory instead of hard-coding library names. This would, however be a
bit more fragile because we would not be able to warn if a library was
missing.

Note that this patch is a workaround. It is needed because Qt does not
properly support CMake's runtime dependency features with platform
plugins. Even if we added FFmpeg binaries to the dependencies set, they
would not be visible at install time.

Pick-to: 6.5
Change-Id: I4b23e50429d16e8487bf43ce9982ff37d02ffbe2
Reviewed-by: Artem Dyomin <artem.dyomin@qt.io>
(cherry picked from commit 138eebcc099e5e95ce04315ac7e1899f59399ca1)
2024-02-01 13:51:24 +00:00
2020-11-16 10:02:08 +02:00
2024-02-01 13:51:24 +00:00
Description
Qt Base (Core, Gui, Widgets, Network, ...)
822 MiB
Languages
C++ 84.3%
HTML 4.9%
C 3.9%
CMake 3.6%
Objective-C++ 2%
Other 0.8%