commit: d4cc84d23091c58cfd1bd339cdc7aa7258a6ab3e
Author: Ilya Tumaykin <itumaykin <AT> gmail <DOT> com>
AuthorDate: Sun Jul 17 21:56:37 2016 +0000
Commit: Patrice Clement <monsieurp <AT> gentoo <DOT> org>
CommitDate: Mon Jul 25 13:02:18 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d4cc84d2
media-video/mpv: warn re softvol, non-fatal ffmpeg version check in 9999
Package-Manager: portage-2.3.0
Signed-off-by: Patrice Clement <monsieurp <AT> gentoo.org>
....18.1-make-ffmpeg-version-check-non-fatal.patch | 28 ++++++++++++++++++++++
media-video/mpv/mpv-9999.ebuild | 24 ++++++++++++++++++-
2 files changed, 51 insertions(+), 1 deletion(-)
diff --git
a/media-video/mpv/files/mpv-0.18.1-make-ffmpeg-version-check-non-fatal.patch
b/media-video/mpv/files/mpv-0.18.1-make-ffmpeg-version-check-non-fatal.patch
new file mode 100644
index 0000000..fcdd4d5
--- /dev/null
+++ b/media-video/mpv/files/mpv-0.18.1-make-ffmpeg-version-check-non-fatal.patch
@@ -0,0 +1,28 @@
+player: make ffmpeg/libav version check non-fatal
+
+We already enforce mpv rebuilds when ffmpeg/libav SONAME changes.
+
+diff --git a/player/main.c b/player/main.c
+index 88b60e1..1d12679 100644
+--- a/player/main.c
++++ b/player/main.c
+@@ -421,13 +421,12 @@ int mp_initialize(struct MPContext *mpctx, char
**options)
+ if (!print_libav_versions(mp_null_log, 0)) {
+ // Using mismatched libraries can be legitimate, but even then it's
+ // a bad idea. We don't acknowledge its usefulness and stability.
+- print_libav_versions(mpctx->log, MSGL_FATAL);
+- MP_FATAL(mpctx, "\nmpv was compiled against a different version of "
+- "FFmpeg/Libav than the shared\nlibrary it is linked against.
"
+- "This is most likely a broken build and could\nresult in "
+- "misbehavior and crashes.\n\nmpv does not support this "
+- "configuration and will not run - rebuild mpv instead.\n");
+- return -1;
++ print_libav_versions(mpctx->log, MSGL_WARN);
++ MP_WARN(mpctx, "\nmpv was compiled against a different version of "
++ "FFmpeg/Libav than the shared\nlibrary it is linked against. "
++ "This is most likely a broken build and could\nresult in "
++ "misbehavior and crashes.\n\nUpstream does not support this "
++ "configuration.\nPlease rebuild mpv in case of any
problems.\n");
+ }
+
+ if (opts->dump_stats && opts->dump_stats[0]) {
diff --git a/media-video/mpv/mpv-9999.ebuild b/media-video/mpv/mpv-9999.ebuild
index ccb8073..fbbb674 100644
--- a/media-video/mpv/mpv-9999.ebuild
+++ b/media-video/mpv/mpv-9999.ebuild
@@ -9,7 +9,7 @@ PYTHON_REQ_USE='threads(+)'
WAF_PV=1.8.12
-inherit fdo-mime gnome2-utils pax-utils python-any-r1 toolchain-funcs waf-utils
+inherit fdo-mime gnome2-utils pax-utils python-any-r1 toolchain-funcs
versionator waf-utils
DESCRIPTION="Media player based on MPlayer and mplayer2"
HOMEPAGE="https://mpv.io/"
@@ -126,6 +126,8 @@ RDEPEND="${COMMON_DEPEND}
selinux? ( sec-policy/selinux-mplayer )
"
+PATCHES=( "${FILESDIR}/${PN}-0.18.1-make-ffmpeg-version-check-non-fatal.patch"
)
+
pkg_pretend() {
if [[ ${MERGE_TYPE} != "binary" ]] && ! tc-has-tls && use vaapi && use
egl; then
die "Your compiler lacks C++11 TLS support. Use GCC>=4.8.0 or
Clang>=3.3."
@@ -269,6 +271,26 @@ pkg_postinst() {
fdo-mime_desktop_database_update
gnome2_icon_cache_update
+ local softvol_0_18_1=0
+ for rv in ${REPLACING_VERSIONS}; do
+ version_compare ${rv} 0.18.1
+ [[ $? -eq 1 ]] && softvol_0_18_1=1
+ done
+
+ if [[ ${softvol_0_18_1} -eq 1 ]]; then
+ echo
+ elog "Starting from version 0.18.1 the software volume control
is"
+ elog "enabled by default, see:"
+ elog
"https://github.com/mpv-player/mpv/blob/v0.18.1/DOCS/interface-changes.rst"
+ elog "https://github.com/mpv-player/mpv/issues/3322"
+ elog
+ elog "This means that volume controls don't change the system
volume,"
+ elog "e.g. per-application volume with PulseAudio."
+ elog "If you want to restore the old behaviour, please refer to"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=588492#c4"
+ echo
+ fi
+
# bash-completion < 2.3-r1 already installs (mostly broken) mpv
completion.
if use cli && ! has_version '<app-shells/bash-completion-2.3-r1' && \
! has_version 'app-shells/mpv-bash-completion'; then