Closed sebastinas closed 3 months ago
Hi,
thanks for reporting this, good to know. ffmpeg 5 won't be a priority at all though, as we have very limited resources and important (other) migrations to handle first.
The above-mentioned https://github.com/bartoszek/AUR-openboard/issues/10 seems to provide a way to explicitly refer to ffmpeg4.4 in order to avoid this problem..
The above-mentioned bartoszek/AUR-openboard#10 seems to provide a way to explicitly refer to ffmpeg4.4 in order to avoid this problem..
Thanks @letsfindaway. Let me point specifically to the relevant comment here: https://github.com/bartoszek/AUR-openboard/pull/11#issuecomment-1074858168 and, for everyone not familiar with Archlinux packaging, it boils down to this patch:
https://aur.archlinux.org/cgit/aur.git/tree/ffmpeg.patch?h=openboard
Of course this only helps if your distribution is providing a legacy version of ffpmeg4 in some directory. Upstream, in OpenBoard, one could make the cmake files more flexible such that the include/lib path of ffmpeg can be specified in the cmake command line. That way it will be more straightforward for distributions/users to select ffmpeg4 without patching.
Hi @fsiegert,
I'm a fan of not including any system dependent paths in a build file such as cmake or here the qmake project files. Instead use the features of pkg-config
to determine the correct paths whenever possible.
Some distros already use a patch to use pkgconfig
for ffmpeg. See e.g. here for the patch used in the builds for openSUSE, but the same patch also appears elsewhere. It is even included in @JBBgameich's pull request https://github.com/OpenBoard-org/OpenBoard/pull/211 (already from 2019, three years old) as a single commit (https://github.com/OpenBoard-org/OpenBoard/pull/211/commits/2a93d128a0f8b79219d9436c65a70cbab8e9fd66). You see that all paths and all additional indirect dependencies of ffmpeg are gone and are replaced by a single line.
With Arch and probably others there will still be the question how to select version 4 or 5. I have checked the AUR package content for both packages. For ffmpeg5, the pkgconfig files are in the standard path /usr/lib/pkgconfig
. For ffmpeg4 they are in usr/lib/ffmpeg4.4/pkgconfig
. So you still have to tell the system where to search. You can however do that using the PKG_CONFIG_PATH
environment variable. See the manual page of pkg-config
for details.
So my proposal would be to upstream the referenced patch. @kaamui: would this work for all of your environments?
Now I see that Qt also seems to have a dependency to ffmpeg, and of course we have to use the same version when building OpenBoard. So the only solution would be to port away from the already deprecated codec
field. Some pointers how to do this might be in https://stackoverflow.com/questions/71565636/replacing-deprecated-avstream-codec-parameter-in-libav.
See also the example at https://libav.org/documentation/doxygen/master/encode_video_8c-example.html. Note that using the new API will work with both, version 4 and 5. The old API was already deprecated in version 4.
This issue is resolved with PR #610
OpenBoard is incompatible with ffmpeg 5.0. Compilation fails with: