SHA256
1
0
forked from jengelh/ffmpeg-4

Rework soversion.patch based on outcome of mailing list interactions

OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4?expand=0&rev=127
This commit is contained in:
Jan Engelhardt 2020-07-06 11:34:00 +00:00 committed by Git OBS Bridge
parent 44525cb3bf
commit 75e1631983
4 changed files with 108 additions and 115 deletions

View File

@ -1,9 +1,9 @@
libavcodec58suse0
libavdevice58suse0
libavfilter7suse0
libavformat58suse0
libavresample4suse0
libavutil56suse0
libpostproc55suse0
libswresample3suse0
libswscale5suse0
libavcodec58_91
libavdevice58_10
libavfilter7_85
libavformat58_45
libavresample4_0
libavutil56_51
libpostproc55_7
libswresample3_7
libswscale5_7

View File

@ -1,7 +1,7 @@
-------------------------------------------------------------------
Sat Jul 4 22:09:51 UTC 2020 - Jan Engelhardt <jengelh@inai.de>
- Add soversion.patch to workaround upstream ABI breakage.
- Add soversion.patch to workaround ELF ABI breakage.
-------------------------------------------------------------------
Wed Jun 17 16:32:04 UTC 2020 - Jan Engelhardt <jengelh@inai.de>

View File

@ -199,7 +199,7 @@ BuildRequires: pkgconfig(xcb-shm)
BuildRequires: pkgconfig(xcb-xfixes)
BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(xfixes)
%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150200
%if 0%{?suse_version} >= 1550 || 0%{?sle_vxersion} >= 150200
%ifarch x86_64
BuildRequires: pkgconfig(libmfx)
%endif
@ -237,15 +237,15 @@ Provides: ffmpeg-tools = %version
Obsoletes: ffmpeg-tools < %version
Provides: ffmpeg = %version
Obsoletes: ffmpeg < %version
Requires: libavcodec58suse0 = %version-%release
Requires: libavdevice58suse0 = %version-%release
Requires: libavfilter7suse0 = %version-%release
Requires: libavformat58suse0 = %version-%release
Requires: libavresample4suse0 = %version-%release
Requires: libavutil56suse0 = %version-%release
Requires: libpostproc55suse0 = %version-%release
Requires: libswresample3suse0 = %version-%release
Requires: libswscale5suse0 = %version-%release
Requires: libavcodec58_91 = %version-%release
Requires: libavdevice58_10 = %version-%release
Requires: libavfilter7_85 = %version-%release
Requires: libavformat58_45 = %version-%release
Requires: libavresample4_0 = %version-%release
Requires: libavutil56_51 = %version-%release
Requires: libpostproc55_7 = %version-%release
Requires: libswresample3_7 = %version-%release
Requires: libswscale5_7 = %version-%release
%description
FFmpeg is a multimedia framework, able to decode, encode,
@ -256,20 +256,21 @@ that humans and machines have created.
This build of ffmpeg is limited in the number of codecs supported.
%endif
%package -n libavcodec58suse0
%package -n libavcodec58_91
Summary: FFmpeg codec library
# For mozillas
Group: System/Libraries
Requires: libavutil56suse0 = %version-%release
Requires: libswresample3suse0 = %version-%release
Provides: libavcodec = %version-%release
Requires: libavutil56_51 = %version-%release
Requires: libswresample3_7 = %version-%release
%if 0%{?BUILD_ORIG}
Provides: libavcodec-full = %version-%release
# This can be required by packages likes vlc-codecs - following the shlib name to not get random lib providers
Provides: libavcodec58(unrestricted)
# This can be (and is) required by packages like vlc-codecs -
# do follow the shlib name to not get random lib providers
Provides: libavcodec58_91(unrestricted)
%endif
# For mozillas
Provides: libavcodec = %version-%release
%description -n libavcodec58suse0
%description -n libavcodec58_91
The libavcodec library provides a generic encoding/decoding framework
and contains multiple decoders and encoders for audio, video and
subtitle streams, and several bitstream filters.
@ -285,7 +286,7 @@ Provides: libavcodec-devel = %version-%release
Obsoletes: libavcodec-devel < %version-%release
Requires: %name-libavresample-devel = %version-%release
Requires: %name-libavutil-devel = %version-%release
Requires: libavcodec58suse0 = %version-%release
Requires: libavcodec58_91 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -296,15 +297,15 @@ subtitle streams, and several bitstream filters.
This subpackage contains the headers for FFmpeg libavcodec.
%package -n libavdevice58suse0
%package -n libavdevice58_10
Summary: FFmpeg device library
Group: System/Libraries
Requires: libavcodec58suse0 = %version-%release
Requires: libavfilter7suse0 = %version-%release
Requires: libavformat58suse0 = %version-%release
Requires: libavutil56suse0 = %version-%release
Requires: libavcodec58_91 = %version-%release
Requires: libavfilter7_85 = %version-%release
Requires: libavformat58_45 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libavdevice58suse0
%description -n libavdevice58_10
The libavdevice library provides a generic framework for grabbing from
and rendering to many common multimedia input/output devices, and
supports several input and output devices, including Video4Linux2, VfW,
@ -325,7 +326,7 @@ Requires: %name-libavutil-devel = %version-%release
Requires: %name-libpostproc-devel = %version-%release
Requires: %name-libswresample-devel = %version-%release
Requires: %name-libswscale-devel = %version-%release
Requires: libavdevice58suse0 = %version-%release
Requires: libavdevice58_10 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -337,18 +338,18 @@ DShow, and ALSA.
This subpackage contains the headers for FFmpeg libavcodec.
%package -n libavfilter7suse0
%package -n libavfilter7_85
Summary: FFmpeg audio and video filtering library
Group: System/Libraries
Requires: libavcodec58suse0 = %version-%release
Requires: libavformat58suse0 = %version-%release
Requires: libavresample4suse0 = %version-%release
Requires: libavutil56suse0 = %version-%release
Requires: libpostproc55suse0 = %version-%release
Requires: libswresample3suse0 = %version-%release
Requires: libswscale5suse0 = %version-%release
Requires: libavcodec58_91 = %version-%release
Requires: libavformat58_10 = %version-%release
Requires: libavresample4_0 = %version-%release
Requires: libavutil56_51 = %version-%release
Requires: libpostproc55_7 = %version-%release
Requires: libswresample3_7 = %version-%release
Requires: libswscale5_7 = %version-%release
%description -n libavfilter7suse0
%description -n libavfilter7_85
The libavfilter library provides a generic audio/video filtering
framework containing several filters, sources and sinks.
@ -364,7 +365,7 @@ Requires: %name-libavutil-devel = %version-%release
Requires: %name-libpostproc-devel = %version-%release
Requires: %name-libswresample-devel = %version-%release
Requires: %name-libswscale-devel = %version-%release
Requires: libavfilter7suse0 = %version-%release
Requires: libavfilter7_85 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -374,13 +375,13 @@ framework containing several filters, sources and sinks.
This subpackage contains the headers for FFmpeg libavfilter.
%package -n libavformat58suse0
%package -n libavformat58_45
Summary: FFmpeg's stream format library
Group: System/Libraries
Requires: libavcodec58suse0 = %version-%release
Requires: libavutil56suse0 = %version-%release
Requires: libavcodec58_91 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libavformat58suse0
%description -n libavformat58_45
The libavformat library provides a generic framework for multiplexing
and demultiplexing (muxing and demuxing) audio, video and subtitle
streams. It encompasses multiple muxers and demuxers for multimedia
@ -398,7 +399,7 @@ Obsoletes: libavformat-devel < %version-%release
Requires: %name-libavcodec-devel = %version-%release
Requires: %name-libavutil-devel = %version-%release
Requires: %name-libswresample-devel = %version-%release
Requires: libavformat58suse0 = %version-%release
Requires: libavformat58_45 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -410,12 +411,12 @@ container formats.
This subpackage contains the headers for FFmpeg libavformat.
%package -n libavresample4suse0
%package -n libavresample4_0
Summary: FFmpeg alternate audio resampling library
Group: System/Libraries
Requires: libavutil56suse0 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libavresample4suse0
%description -n libavresample4_0
An audio resampling library that is being provided for drop-in
compatibility with libav.
@ -427,7 +428,7 @@ Group: Development/Libraries/C and C++
Provides: libavresample-devel = %version-%release
Obsoletes: libavresample-devel < %version-%release
Requires: %name-libavutil-devel = %version-%release
Requires: libavresample4suse0 = %version-%release
Requires: libavresample4_0 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -439,11 +440,11 @@ It is advised to use libswresample for new code.
This subpackage contains the headers for FFmpeg's copy of libavresample.
%package -n libavutil56suse0
%package -n libavutil56_51
Summary: FFmpeg's utility library
Group: System/Libraries
%description -n libavutil56suse0
%description -n libavutil56_51
The libavutil library is a utility library to aid portable multimedia
programming. It contains safe portable string functions, random
number generators, data structures, additional mathematics functions,
@ -455,7 +456,7 @@ Summary: Development files for FFmpeg's utility library
Group: Development/Libraries/C and C++
Provides: libavutil-devel = %version-%release
Obsoletes: libavutil-devel < %version-%release
Requires: libavutil56suse0 = %version-%release
Requires: libavutil56_51 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -468,12 +469,12 @@ for pixel and sample formats).
This subpackage contains the headers for FFmpeg libavutil.
%package -n libpostproc55suse0
%package -n libpostproc55_7
Summary: FFmpeg post-processing library
Group: System/Libraries
Requires: libavutil56suse0 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libpostproc55suse0
%description -n libpostproc55_7
A library with video postprocessing filters, such as deblocking and
deringing filters, noise reduction, automatic contrast and brightness
correction, linear/cubic interpolating deinterlacing.
@ -484,7 +485,7 @@ Group: Development/Libraries/C and C++
Provides: libpostproc-devel = %version-%release
Obsoletes: libpostproc-devel < %version-%release
Requires: %name-libavutil-devel = %version-%release
Requires: libpostproc55suse0 = %version-%release
Requires: libpostproc55_7 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -495,12 +496,12 @@ correction, linear/cubic interpolating deinterlacing.
This subpackage contains the headers for FFmpeg libpostproc.
%package -n libswresample3suse0
%package -n libswresample3_7
Summary: FFmpeg software resampling library
Group: System/Libraries
Requires: libavutil56suse0 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libswresample3suse0
%description -n libswresample3_7
The libswresample library performs audio conversion between different
sample rates, channel layout and channel formats.
@ -510,7 +511,7 @@ Group: Development/Libraries/C and C++
Provides: libswresample-devel = %version-%release
Obsoletes: libswresample-devel < %version-%release
Requires: %name-libavutil-devel = %version-%release
Requires: libswresample3suse0 = %version-%release
Requires: libswresample3_7 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -520,12 +521,12 @@ sample rates, channel layout and channel formats.
This subpackage contains the headers for FFmpeg libswresample.
%package -n libswscale5suse0
%package -n libswscale5_7
Summary: FFmpeg image scaling and colorspace/pixel conversion library
Group: System/Libraries
Requires: libavutil56suse0 = %version-%release
Requires: libavutil56_51 = %version-%release
%description -n libswscale5suse0
%description -n libswscale5_7
The libswscale library performs image scaling and colorspace and
pixel format conversion operations.
@ -535,7 +536,7 @@ Group: Development/Libraries/C and C++
Provides: libswscale-devel = %version-%release
Conflicts: libswscale-devel
Requires: %name-libavutil-devel = %version-%release
Requires: libswscale5suse0 = %version-%release
Requires: libswscale5_7 = %version-%release
%devel_conflicts -c < -v %_major_version
%devel_conflicts -c >= -v %_major_expected
@ -676,7 +677,7 @@ LDFLAGS="%_lto_cflags" \
%if %{with lv2}
--enable-lv2 \
%endif
%if 0%{?suse_version} >= 1550 || 0%{?sle_version} >= 150200
%if 0%{?suse_version} >= 1550 || 0%{?sle_vxersion} >= 150200
%ifarch x86_64
--enable-libmfx \
%endif
@ -747,24 +748,24 @@ for i in libavformat/options_table.h libavformat/os_support.h \
cp -a $i "$b/%_includedir/ffmpeg/private/$i"
done
%post -n libavcodec58suse0 -p /sbin/ldconfig
%postun -n libavcodec58suse0 -p /sbin/ldconfig
%post -n libavdevice58suse0 -p /sbin/ldconfig
%postun -n libavdevice58suse0 -p /sbin/ldconfig
%post -n libavfilter7suse0 -p /sbin/ldconfig
%postun -n libavfilter7suse0 -p /sbin/ldconfig
%post -n libavformat58suse0 -p /sbin/ldconfig
%postun -n libavformat58suse0 -p /sbin/ldconfig
%post -n libavresample4suse0 -p /sbin/ldconfig
%postun -n libavresample4suse0 -p /sbin/ldconfig
%post -n libavutil56suse0 -p /sbin/ldconfig
%postun -n libavutil56suse0 -p /sbin/ldconfig
%post -n libpostproc55suse0 -p /sbin/ldconfig
%postun -n libpostproc55suse0 -p /sbin/ldconfig
%post -n libswresample3suse0 -p /sbin/ldconfig
%postun -n libswresample3suse0 -p /sbin/ldconfig
%post -n libswscale5suse0 -p /sbin/ldconfig
%postun -n libswscale5suse0 -p /sbin/ldconfig
%post -n libavcodec58_91 -p /sbin/ldconfig
%postun -n libavcodec58_91 -p /sbin/ldconfig
%post -n libavdevice58_10 -p /sbin/ldconfig
%postun -n libavdevice58_10 -p /sbin/ldconfig
%post -n libavfilter7_85 -p /sbin/ldconfig
%postun -n libavfilter7_85 -p /sbin/ldconfig
%post -n libavformat58_45 -p /sbin/ldconfig
%postun -n libavformat58_45 -p /sbin/ldconfig
%post -n libavresample4_0 -p /sbin/ldconfig
%postun -n libavresample4_0 -p /sbin/ldconfig
%post -n libavutil56_51 -p /sbin/ldconfig
%postun -n libavutil56_51 -p /sbin/ldconfig
%post -n libpostproc55_7 -p /sbin/ldconfig
%postun -n libpostproc55_7 -p /sbin/ldconfig
%post -n libswresample3_7 -p /sbin/ldconfig
%postun -n libswresample3_7 -p /sbin/ldconfig
%post -n libswscale5_7 -p /sbin/ldconfig
%postun -n libswscale5_7 -p /sbin/ldconfig
%files
%doc Changelog CREDITS README.md
@ -772,39 +773,39 @@ done
%_mandir/man1/ff*.1*
%_datadir/ffmpeg/
%files -n libavcodec58suse0
%files -n libavcodec58_91
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavcodec.so.*
%files -n libavdevice58suse0
%files -n libavdevice58_10
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavdevice.so.*
%files -n libavfilter7suse0
%files -n libavfilter7_85
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavfilter.so.*
%files -n libavformat58suse0
%files -n libavformat58_45
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavformat.so.*
%files -n libavresample4suse0
%files -n libavresample4_0
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavresample.so.*
%files -n libavutil56suse0
%files -n libavutil56_51
%license COPYING.GPLv2 LICENSE.md
%_libdir/libavutil.so.*
%files -n libpostproc55suse0
%files -n libpostproc55_7
%license COPYING.GPLv2 LICENSE.md
%_libdir/libpostproc.so.*
%files -n libswresample3suse0
%files -n libswresample3_7
%license COPYING.GPLv2 LICENSE.md
%_libdir/libswresample.so.*
%files -n libswscale5suse0
%files -n libswscale5_7
%license COPYING.GPLv2 LICENSE.md
%_libdir/libswscale.so.*

View File

@ -4,23 +4,15 @@ Date: 2020-07-04 23:56:54.411950316 +0200
User frispete wrote on 2020-6-26 22:13+0000 at
https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4#comment-1257440
: """Unfortunately, this version is binary incompatible to 4.2.3 in some
aspects. Chromium crashes when accessing some sites, e.g.
https://www.xometry.com/ and push the quote button. Blender cannot export PNG
files anymore"""
aspects. [...]"""
And indeed:
$ abidiff b42/usr/lib/debug/usr/lib64/libavcodec.so.58.54.100-4.2.3-1.1.x86_64.debug \
b43/usr/lib/debug/usr/lib64/libavcodec.so.58.91.100-4.3-136.2.x86_64.debug
[...] in pointed to type 'struct AVCodecContext' at avcodec.h:526:1:
type size changed from 8448 to 8576 (in bits)
[...]
underlying type 'struct AVDCT' at avdct.h:29:1 changed:
type size changed from 896 to 960 (in bits)
As this struct is made public by way of presenting it in /usr/include,
I conclude: bad upstream, bad upstream!
Further discussion on the mailing list explored this topic, and
revealed that ELF symbol versioning is lacklusterly implemented in
ffmpeg, which can cause inadvertent mixing of library versions on
openSUSE, and precompiled Linux distributions in general. It is
unclear when upstream will have implemented a solution. Until then,
we will need to tighten the requirements between packages, to which
end we stretch the SOVERSION to include MINOR.
---
configure | 2 +-
@ -35,7 +27,7 @@ Index: ffmpeg-4.3/configure
SLIBNAME='$(SLIBPREF)$(FULLNAME)$(SLIBSUF)'
SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBVERSION)'
-SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'
+SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)suse0'
+SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR).$(LIBMINOR)'
LIB_INSTALL_EXTRA_CMD='$$(RANLIB) "$(LIBDIR)/$(LIBNAME)"'
SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)'
SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR) $(SLIBNAME)'