Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 958961 - media-libs/opencv-4.11.0: features2d USE flag is not default anymore but it is required by other stable packages like media-plugins/frei0r-plugins
Summary: media-libs/opencv-4.11.0: features2d USE flag is not default anymore but it i...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Profiles (show other bugs)
Hardware: AMD64 Linux
: Normal minor
Assignee: Gentoo KDE team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-06-23 16:37 UTC by ngg
Modified: 2025-06-25 15:30 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ngg 2025-06-23 16:37:11 UTC
The stable `media-plugins/frei0r-plugins-1.8.0` package's default USE flag combination depends on `>=media-libs/opencv-2.3.0:=[features2d]`, and this `features2d` USE flag was set by default in the previous OpenCV version. Since the update to 4.11.0, this does not work with the default USE flags of OpenCV.

I'm not sure if this is considered to be a bug, but annoying. Either the `features2d` USE flag should be default for OpenCV, or it should not be needed by default by other packages.

Reproducible: Always

Steps to Reproduce:
1. Run `emerge media-plugins/frei0r-plugins`
Actual Results:  
It either tries to downgrade opencv to 4.10.0 or shows an error about the missing USE flag.
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-06-23 16:39:39 UTC
This is just the nature of USE dependencies. Not every package can have its USE satisfied enabled by default.

A bunch of the USE flags in opencv stopped being enabled by default because they added significantly to the build time and most reverse dependencies didn't need them on.
Comment 2 Eli Schwartz gentoo-dev 2025-06-23 17:18:37 UTC
Profile bug IMO.

In profiles/targets/desktop/plasma/package.use:

# Required by kde-apps/kdenlive
media-libs/mlt ffmpeg frei0r rubberband

# Required by media-gfx/digikam
media-libs/opencv contrib contribdnn



mlt has:

frei0r? ( media-plugins/frei0r-plugins )


frei0r-plugins has:

IUSE="doc +facedetect +scale0tilt"


        facedetect? ( >=media-libs/opencv-2.3.0:=[contrib,contribdnn,features2d,${MULTILIB_USEDEP}] )




So, installing kdenlive on KDE requires features2d, and the kde meta packages are broken by default. Shouldn't we add this to p.use on the plasma profile?
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-06-25 07:38:46 UTC
(In reply to Eli Schwartz from comment #2)
> So, installing kdenlive on KDE requires features2d, and the kde meta
> packages are broken by default. Shouldn't we add this to p.use on the plasma
> profile?


Yes, I think we probably should given the entry is there for the benefit of digikam already. It's a shame given part of the rationale for reduced USE defaults on opencv was for plasma->spectacle->opencv, though.

But it makes sense for us to fix it here at least for now, even if we change stuff more later (like perhaps disabling facedetect by default in frei0r-plugins, I don't know).
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2025-06-25 07:39:06 UTC
.. and we already make such changes for kdenlive.
Comment 5 Larry the Git Cow gentoo-dev 2025-06-25 07:41:55 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f0c86e5db0ba4327c9d815d078b4afc567a55e59

commit f0c86e5db0ba4327c9d815d078b4afc567a55e59
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2025-06-25 07:40:08 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2025-06-25 07:41:17 +0000

    profiles/targets/desktop/plasma: enable opencv[features2d]
    
    kdenlive->frei0r-plugins needs this, so enable it by default, at least
    for now. It's a bit of a shame given slimmed-down opencv was partly
    done for the benefit of Spectacle, but we can revisit later.
    
    Right now, this achieves consistency given we set things for the benefit
    of kdenlive and digikam.
    
    Closes: https://bugs.gentoo.org/958961
    Signed-off-by: Sam James <sam@gentoo.org>

 profiles/targets/desktop/plasma/package.use | 1 +
 1 file changed, 1 insertion(+)
Comment 6 Larry the Git Cow gentoo-dev 2025-06-25 15:30:37 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/binhost.git/commit/?id=5ae55dc92410e7773db492bd60bb9be64bf21a28

commit 5ae55dc92410e7773db492bd60bb9be64bf21a28
Author:     Eli Schwartz <eschwartz@gentoo.org>
AuthorDate: 2025-06-25 15:22:10 +0000
Commit:     Eli Schwartz <eschwartz@gentoo.org>
CommitDate: 2025-06-25 15:27:02 +0000

    milou: openrc: adapt to required opencv USE for kde profile
    
    kdenlive->frei0r-plugins needs this, and we build it for the openrc
    builds as well... but it runs on a gnome profile, and ::gentoo only sets
    this for kde.
    
    We already have package.use for kde-required setting when building this
    binhost profile; extend it a little further.
    
    Bug: https://bugs.gentoo.org/958961
    Signed-off-by: Eli Schwartz <eschwartz@gentoo.org>

 builders/milou/openrc-23/portage/package.use/kde    | 9 +++++++--
 builders/milou/openrc-v3-23/portage/package.use/kde | 9 +++++++--
 2 files changed, 14 insertions(+), 4 deletions(-)