Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 769464 - media-libs/libcanberra-0.30-r5 drop optional gtk2 support
Summary: media-libs/libcanberra-0.30-r5 drop optional gtk2 support
Status: IN_PROGRESS
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords: PullRequest
Depends on: 774918
Blocks: gtk2-removal
  Show dependency tree
 
Reported: 2021-02-08 09:08 UTC by charles17
Modified: 2024-11-04 18:39 UTC (History)
3 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 charles17 2021-02-08 09:08:06 UTC
emerge -pvc x11-libs/gtk+:2

Calculating dependencies... done!
  x11-libs/gtk+-2.24.32-r1 pulled in by:
    media-libs/libcanberra-0.30-r5 requires >=x11-libs/gtk+-2.20.0:2[abi_x86_64(-)]
Comment 1 Andreas Sturmlechner gentoo-dev 2021-03-08 22:40:52 UTC
Seems like there is only this single blocker.
Comment 2 Larry the Git Cow gentoo-dev 2022-04-12 03:15:52 UTC
The bug has been referenced in the following commit(s):

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

commit 045488f09d792adcd03ddb91e391c94ae2c6d225
Author:     Matt Turner <mattst88@gentoo.org>
AuthorDate: 2022-04-12 03:10:52 +0000
Commit:     Matt Turner <mattst88@gentoo.org>
CommitDate: 2022-04-12 03:15:44 +0000

    media-libs/libcanberra: Change IUSE=+gtk to IUSE=gtk2
    
    Bug: https://bugs.gentoo.org/769464
    Bug: https://bugs.gentoo.org/834685
    Closes: https://bugs.gentoo.org/811531
    Signed-off-by: Matt Turner <mattst88@gentoo.org>

 .../{libcanberra-0.30-r5.ebuild => libcanberra-0.30-r6.ebuild}    | 8 ++++----
 media-libs/libcanberra/metadata.xml                               | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)
Comment 3 Andreas Sturmlechner gentoo-dev 2022-04-12 08:14:45 UTC
So, does that mean GNOME proj changed its USE flag policy?

https://wiki.gentoo.org/wiki/Project:GNOME/Gnome_Team_Ebuild_Policies#GTK.2B_USE-flag_and_slots_usage
Comment 4 Matt Turner gentoo-dev 2022-04-13 00:37:22 UTC
(In reply to Andreas Sturmlechner from comment #3)
> So, does that mean GNOME proj changed its USE flag policy?
> 
> https://wiki.gentoo.org/wiki/Project:GNOME/Gnome_Team_Ebuild_Policies#GTK.
> 2B_USE-flag_and_slots_usage

I don't know specifically, but I asked leio before I made this change:

<mattst88> libcanberra has IUSE="+gtk +gtk3". many reverse dependencies of libcanberra[gtk3], but only claws-mail is a revdep of libcanberra[gtk]
<mattst88> I think we should probably change IUSE=+gtk to IUSE=gtk2 -- seems okay?
<    leio> probably
<mattst88> thanks, will do that then
Comment 5 Mart Raudsepp gentoo-dev 2022-12-01 17:05:56 UTC
(In reply to Andreas Sturmlechner from comment #3)
> So, does that mean GNOME proj changed its USE flag policy?
> 
> https://wiki.gentoo.org/wiki/Project:GNOME/Gnome_Team_Ebuild_Policies#GTK.
> 2B_USE-flag_and_slots_usage

There's not really a policy change there, other than that documentation not having been revised since gtk3 was very new for the small case where it was about a library providing optional gtk2, gtk3 (or not gtk4) support. Back then we had been living with just gtk2 for a long time and then gtk3 appeared. Instead of going back and changing all USE=gtk to USE=gtk2 in library cases, we just kept it used for gtk2 then. But as some of these (like libcanberra, or avahi and such in the past) had to keep its gtk2 support around for a long time, it naturally got moved over to USE=gtk2 as people were starting to be able to have a legacy-free without gtk2 system otherwise with just USE=gtk. And then gtk4 happened too.

So the spirit of that policy is really the same - if the library gtk support can be a separate package with reasonable maintenance cost, it should be separate. If not, then only for cases of optional library support or gtk modules shipping for a specific gtk version it has been OK as a workaround for the too high maintenance cost. In all other cases it's USE=gtk in general, no matter the version, but this is for cases where it doesn't matter - not cases where you could have both support built at once (shipping differently API versioned libraries) and then other packages also depend on one of them.

I expect we'll need USE=gtk4 for a few things in the future, but a bunch of this kind of specific packages just don't have gtk4 support yet or are pretty dead things like libcanberra here. One example that comes to mind is evolution-data-server, but for now we just hard require both gtk versions there.
Comment 6 Andreas Sturmlechner gentoo-dev 2024-09-17 21:40:45 UTC
The linked PR is proposing to split off media-libs/libcanberra-gtk (GTK3-only) as an elegant way to get rid of a default enabled GTK dep (meanwhile media-video/pipewire[X] and various KDE packages have become revdeps of libcanberra).
Comment 7 Larry the Git Cow gentoo-dev 2024-11-04 18:39:51 UTC
The bug has been referenced in the following commit(s):

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

commit dcd56bc818bfeefc763f53b89355161a2f466f61
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2024-09-17 20:56:48 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2024-11-04 18:38:28 +0000

    media-libs/libcanberra-gtk3: new package, add 0.30
    
    GTK3 part split out of media-libs/libcanberra
    
    Bug: https://bugs.gentoo.org/769464
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 media-libs/libcanberra-gtk3/Manifest               |  1 +
 .../files/libcanberra-0.30-wayland.patch           | 64 ++++++++++++++++
 .../files/libcanberra-gtk-module.sh                | 16 ++++
 .../libcanberra-gtk3/libcanberra-gtk3-0.30.ebuild  | 88 ++++++++++++++++++++++
 media-libs/libcanberra-gtk3/metadata.xml           | 12 +++
 5 files changed, 181 insertions(+)

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

commit 9f7b42f18c432793351933d75539cb80b644d82b
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2024-09-17 20:08:31 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2024-11-04 18:38:28 +0000

    media-libs/libcanberra: update EAPI 7 -> 8, drop IUSE gtk2, gtk3
    
    Package is also used by non-GTK centric packages. This is a way to get
    around a default enabled USE=gtk.
    
    Drop IUSE sound, hard-depend on x11-themes/sound-theme-freedesktop instead.
    
    Dead upstream so no downside to maintenance.
    
    Remove all parts colliding with subsequent media-libs/libcanberra-gtk3.
    
    Bug: https://bugs.gentoo.org/769464
    Bug: https://bugs.gentoo.org/941986
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 media-libs/libcanberra/libcanberra-0.30-r8.ebuild | 72 +++++++++++++++++++++++
 1 file changed, 72 insertions(+)