Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 934214

Summary: vlc wants ffmpeg =media-video/ffmpeg-4.4.4-r9 but media-gfx/blender-4.1.1::gentoo[ffmpeg] is reported instead
Product: Portage Development Reporter: jlm <WoLibertygentoo>
Component: Core - DependenciesAssignee: Portage team <dev-portage>
Status: UNCONFIRMED ---    
Severity: normal CC: cyrilmaley, esigra, joakim.tjernlund, WoLibertygentoo, zmedico
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://bugs.gentoo.org/show_bug.cgi?id=748456
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 376695    
Attachments: emerge --info output

Description jlm 2024-06-13 19:08:40 UTC
Created attachment 895771 [details]
emerge --info output

Hi,
I have a strange issue....
on my system, I have media-video/ffmpeg-6.1.1-r6 installed
when I want to upgrade world I have the following message 


The following USE changes are necessary to proceed:
 (see "package.use" in the portage(5) man page for more details)
# required by media-gfx/blender-4.1.1::gentoo[ffmpeg]
# required by @selected
# required by @world (argument)
=media-video/ffmpeg-4.4.4-r9 vpx theora

but if I do so, I can't world upgrade because of a slot conflict, some package wants the ffmpeg-6.1.1 and "blender" (see later why I put it into quotes) wants ffmpeg-4.4.4

so first thought was "ok, blender is the culpit"

BUT BUT.....

emerge -1 --nodep media-gfx/blender ..... OK!!!!
so blender compile fine with ffmpeg-6.1.1.... 

tried also emerge -1 media-gfx/blender .... OK !!! so blender itself don't trig the  ffmpeg-4.4.4 requirement....

looked into blender ebuild... no trace of ffmpeg version

so I begun to recompile one by one the packages depending on ffmpeg... and.... 
emerge -1 media-video/vlc
TADA! 
The following USE changes are necessary to proceed:
 (see "package.use" in the portage(5) man page for more details)
# required by media-gfx/blender-4.1.1::gentoo[ffmpeg]
# required by @selected
# required by @world (argument)
=media-video/ffmpeg-4.4.4-r9 vpx theora

so in fact it should be
 (see "package.use" in the portage(5) man page for more details)
# required by media-video/vlc-3.0.20-r11l::gentoo[ffmpeg]
# required by @selected
# required by @world (argument)
=media-video/ffmpeg-4.4.4-r9 vpx theora!


after looking into vlc ebuild it seems that the issue is 
	vaapi? (
		<media-video/ffmpeg-5
		media-libs/libva:=[drm(+),wayland?,X?]
	)
if vaapi is enabled then it force using old ffmpeg

trying to build vlc with vaapi enabled ignoring deps does fail with ffmpeg-6 fails at configure phase
configure: error: libva is present but libavcodec/vaapi.h is missing


workaround : disable vaapi use flag in vlc allow vlc to build and don't rise conflict (if vaapi is active in ffmpeg, vlc should fall back on it)

HOWEVER this is not normal that blender is reported to force ffmpeg version while it's vlc that does!!!!
Comment 1 Mike Gilbert gentoo-dev 2024-06-14 00:09:22 UTC
Could be a Portage bug.
Comment 2 Joakim Tjernlund 2024-06-14 08:15:42 UTC
If you want to use ffmpeg-6 and vlc you need to use vlc-9999
However upstream vlc is QT6 only now, add
EGIT_OVERRIDE_COMMIT_VIDEOLAN_VLC=bb5723b728fd6f4395ef1a08ed1f1d53b640abb4
to use an QT5 compat vlc
Comment 3 cyrillic 2024-06-15 16:31:07 UTC
This is where reading the message carefully is key:

>  The following USE changes are necessary to proceed:

While vlc is the package requiring an old version of ffmpeg, blender is the one requiring +vpx +theora for whatever version of ffmpeg you have installed.
Comment 4 jlm 2024-06-16 07:57:54 UTC
(In reply to Joakim Tjernlund from comment #2)
> If you want to use ffmpeg-6 and vlc you need to use vlc-9999
> However upstream vlc is QT6 only now, add
> EGIT_OVERRIDE_COMMIT_VIDEOLAN_VLC=bb5723b728fd6f4395ef1a08ed1f1d53b640abb4
> to use an QT5 compat vlc

well... the media-video/vlc-3.0.20-r11l::gentoo[ffmpeg] built with media-video/ffmpeg-6.1.1-r6 works perfectly fine with at least h264 and h265 videos.

I'm sure, at least for h265 that the ffmepg is used since no linkage to any lib that could provide h265 decoding....

so, as long as you don't activate vaapi use flag on vlc, vlc build with a recent version of ffmpeg and runs fine. no need to use the experimental version 9999
Comment 5 jlm 2024-06-16 08:23:10 UTC
(In reply to cyrillic from comment #3)
> This is where reading the message carefully is key:
> 
> >  The following USE changes are necessary to proceed:
> 
> While vlc is the package requiring an old version of ffmpeg, blender is the
> one requiring +vpx +theora for whatever version of ffmpeg you have installed.


for me the requirement chain is not complete, because it make the user search what is wrong with blender, and it has no clue that the culpit is vlc.... because, the culpit is vlc, it's vlc that require ffmpeg-4.4.4-r9 not blender, even if blender add the vpx and theora requirements

at least it should be
# while processing requirements of media-video/vlc-3.0.20-r11l::gentoo[ffmpeg]
# also required by media-gfx/blender-4.1.1::gentoo[ffmpeg useflag [vpx] [theora]]
media-video/ffmpeg vpx theora
# required by media-video/vlc-3.0.20-r11l::gentoo[ffmpeg]
=media-video/ffmpeg-4.4.4-r9
# required by @selected
# required by @world (argument)
=media-video/ffmpeg-4.4.4-r9 vpx theora

and by the way, we read from top to bottom so the following version is more readable 
# required by @world (argument)
# required by @selected
# required by media-video/vlc-3.0.20-r11l::gentoo[ffmpeg][vaapi]
# <media-video/ffmpeg-5
# required by media-gfx/blender-4.1.1::gentoo[ffmpeg]
# media-video/ffmpeg vpx theora
# requirements results :
=media-video/ffmpeg-4.4.4-r9 vpx theora

best regards... I spent a week (because I have also a life beside) recompiling each atom requiring ffmpeg to find the world listed package that cause the conflict... and asking myself "who is downgrading the ffmpeg, since blender don't require the old version...."
Comment 6 cyrillic 2024-06-16 13:36:49 UTC
Another trick you can use if you don't want to downgrade ffmpeg is to put this in your package.mask:

<media-video/ffmpeg-6

Then portage will let you know that vlc is unhappy about that.