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

Bug 910646

Summary: app-i18n/ibus-1.5.28-r1[-X] still needs x11-libs/gtk+[X] to build
Product: Gentoo Linux Reporter: Sorrow <lynx1534>
Component: Current packagesAssignee: CJK Team <cjk>
Status: RESOLVED FIXED    
Severity: normal CC: gnome
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: build log
emerge --info
build log of failure with gtk-4
build log of failure with gtk-4

Description Sorrow 2023-07-21 15:23:32 UTC
Created attachment 865889 [details]
build log

Trying to build ibus with GTK+ built without X I encountered a build failure:

keybindingmanager.c:15:10: fatal error: gdk/gdkx.h: No such file or directory

> emerge -pqv ibus ibus-anthy                
[ebuild  N    ] app-i18n/ibus-1.5.28-r1  USE="appindicator gtk3 gtk4 gui introspection libnotify nls python systemd unicode wayland -X -emoji -gtk2 -test -vala" PYTHON_TARGETS="python3_11 -python3_10" 
[ebuild  N    ] app-i18n/ibus-anthy-1.5.14  USE="nls" PYTHON_SINGLE_TARGET="python3_11 -python3_10"
Comment 1 Sorrow 2023-07-21 15:25:52 UTC
Created attachment 865890 [details]
emerge --info
Comment 2 Maciej Barć gentoo-dev 2024-01-05 09:34:13 UTC
Similar issue for me but with gtk:4.
Comment 3 Maciej Barć gentoo-dev 2024-01-05 09:35:09 UTC
Created attachment 881494 [details]
build log of failure with gtk-4
Comment 4 Maciej Barć gentoo-dev 2024-01-05 09:37:01 UTC
Created attachment 881495 [details]
build log of failure with gtk-4
Comment 5 Maciej Barć gentoo-dev 2024-01-05 09:37:59 UTC
For gtk-4 it fails on:

> ibusimcontext.c:1651:9: error: unknown type name 'Window'; did you mean 'GtkWindow'?
Comment 6 Maciej Barć gentoo-dev 2024-01-05 09:42:51 UTC
And, yes, in my case too adding X to gtk:4 will let this compile.
Comment 7 Larry the Git Cow gentoo-dev 2025-02-02 05:29:39 UTC
The bug has been closed via the following commit(s):

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

commit a0fad0f4611efabdb614a93b304cf52aab8e06cc
Author:     Eli Schwartz <eschwartz@gentoo.org>
AuthorDate: 2025-01-29 00:28:40 +0000
Commit:     Eli Schwartz <eschwartz@gentoo.org>
CommitDate: 2025-02-02 05:28:45 +0000

    app-i18n/ibus: correctly depend on gtk interfaces to wayland/X
    
    The upstream code checks whether GDK_WINDOWING_WAYLAND is defined by the
    gtk headers, and if so will compile against the wayland symbols it
    provides.
    
    We must unconditionally depend on the gdk X11 backend, since the code
    unconditionally tries to use it (even when headers themselves are
    conditional, which they aren't always).
    
    We can now solve this using a special Gentoo macro to hide these
    automagic macros to simulate building on a system with more minimal gtk
    packages.
    
    Bug: https://bugs.gentoo.org/624960
    Closes: https://bugs.gentoo.org/910646
    Closes: https://bugs.gentoo.org/921671
    Signed-off-by: Eli Schwartz <eschwartz@gentoo.org>

 app-i18n/ibus/ibus-1.5.29-r1.ebuild                | 236 +++++++++++++++++++++
 .../{ibus-1.5.30.ebuild => ibus-1.5.30-r1.ebuild}  |   9 +-
 .../{ibus-1.5.31.ebuild => ibus-1.5.31-r1.ebuild}  |   9 +-
 profiles/arch/alpha/package.use.mask               |   1 +
 profiles/features/big-endian/package.use.mask      |   3 +-
 5 files changed, 251 insertions(+), 7 deletions(-)