FS#26124 - [ibus] does not run on startup

Attached to Project: Community Packages
Opened by taylorchu (taylorchu) - Tuesday, 27 September 2011, 07:35 GMT
Last edited by Eric Belanger (Snowman) - Monday, 30 January 2012, 21:56 GMT
Task Type Bug Report
Category Packages
Status Closed
Assigned To Eric Belanger (Snowman)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 14
Private No

Details

Description:
I exported the xim and gtk input method but ibus still does not startup correctly.
If i run ibus manually, I cannot switch to ibus-chewing.

Additional info:
* ibus 1.4
* ibus-chewing 1.3.9.2


Steps to reproduce:
1. install ibus
2. export xim and gtk im
This task depends upon

Closed by  Eric Belanger (Snowman)
Monday, 30 January 2012, 21:56 GMT
Reason for closing:  Fixed
Additional comments about closing:  ibus-1.4.0-2
Comment by Ong Kuan Yang (ong) - Tuesday, 27 September 2011, 10:36 GMT
This happens to me as well. Just wish to add that not only, ibus-chewing but ibus-pinyin is not working as well. Upon switching to pinyin, nothing happens.
I am using gnome-unstable but I doubt that is related.
Comment by Ong Kuan Yang (ong) - Tuesday, 27 September 2011, 10:40 GMT
This are the errors i get from running ibus-daemon -v

/usr/lib/ibus/ibus-engine-pinyin: error while loading shared libraries: libibus.so.2: cannot open shared object file: No such file or directory
/usr/share/ibus/ui/gtk/panel.py:115: Warning: g_object_notify: object class `GtkStatusIcon' has no property named `name'
self.__status_icon.set_name('ibus-ui-gtk')
/usr/lib/ibus/ibus-engine-pinyin: error while loading shared libraries: libibus.so.2: cannot open shared object file: No such file or directory
Traceback (most recent call last):
File "/usr/share/ibus/ui/gtk/panel.py", line 496, in __im_menu_item_activate_cb
self.__focus_ic.set_engine(engine)
File "/usr/lib/python2.7/site-packages/ibus/inputcontext.py", line 287, in set_engine
return self.__context.SetEngine(engine.name)
File "/usr/lib/python2.7/site-packages/dbus/proxies.py", line 143, in __call__
**keywords)
File "/usr/lib/python2.7/site-packages/dbus/connection.py", line 630, in call_blocking
message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.Failed: Timeout was reached
Comment by Ma Jiehong (jiehong) - Tuesday, 27 September 2011, 13:30 GMT
I have the same issue under x86_64 with xfce (both pinyin and chewing aren't working).

I tried to symlink libibus.so.2 to one of the three in /usr/lib/ (-1.0.so, -1.0.so.0 and -1.0.so.0.400.0) which fix the warning message but do not fix the problem at all since another error is raised when i call ibus with chewing for example:
/usr/lib/ibus/ibus-engine-chewing: symbol lookup error: /usr/lib/ibus/ibus-engine-chewing: undefined symbol: ibus_service_get_connections

Hope it's gonna be fixed soon…
Comment by Ionut Biru (wonder) - Tuesday, 27 September 2011, 13:48 GMT
sounds like ibus-pinyin needs a rebuild
Comment by Ionut Biru (wonder) - Tuesday, 27 September 2011, 13:49 GMT
rebuild list is:

sogrep community libibus.so.2
ibus-chewing
ibus-hangul
ibus-m17n
ibus-pinyin
ibus-sunpinyin
ibus-unikey
Comment by Ong Kuan Yang (ong) - Tuesday, 27 September 2011, 13:50 GMT
There is also the problem of ibus not starting up automatically.
Comment by Hirosh Yui (hiroshiyui) - Wednesday, 28 September 2011, 02:41 GMT
An "ABS and makepkg" rebuild of ibus-sunpinyin works as expected,
but ibus-chewing & ibus-pinyin don't.

Maybe there are some functions were changed in IBus 1.4.0.
Comment by taylorchu (taylorchu) - Wednesday, 28 September 2011, 03:31 GMT
@hiroshi
if that's true, maybe we could use dev branch on github.
ibus-chewing is already 1 year old.
Comment by Ma Jiehong (jiehong) - Wednesday, 28 September 2011, 03:44 GMT
According to the changes given on the webpage of ibus:
Remove libdbus dependence, use glib gdbus instead.
Support surrounding text feature.
Add dconf config backend.
Add memory config backend.
Support replacing ibus panel on the fly.
Add asynchronous API.
Remove most blocking function call in daemon.
Improve gobject-introspection support.
Improve vala language support.
Improve unit test.
Many bug fixes.

Maybe the first one is changing something… is it ?
Comment by Isaac Lindgren (the_sad_clown) - Wednesday, 28 September 2011, 11:38 GMT
This error also occurs with ibus-hangul. I attempted to rebuild ibus-hangul via ABS. Here is the error from makepkg:
engine.c:191:42: error: too many arguments to function ‘ibus_config_get_value’
/usr/include/ibus-1.0/ibusconfig.h:140:18: note: declared here
engine.c:190:9: warning: assignment makes integer from pointer without a cast [enabled by default]
engine.c:201:42: error: too many arguments to function ‘ibus_config_get_value’
/usr/include/ibus-1.0/ibusconfig.h:140:18: note: declared here
engine.c:200:9: warning: assignment makes integer from pointer without a cast [enabled by default]

And here are the lines 190 and 200:
190 res = ibus_config_get_value (config, "engine/Hangul", "HangulKeyboard", &value);
200 res = ibus_config_get_value (config, "engine/Hangul", "HanjaKeys", &value);

And from /usr/include/ibus-1.0/ibusconfig.h:140:18
GVariant *ibus_config_get_value (IBusConfig *config,
const gchar *section,
const gchar *name);
Comment by Hirosh Yui (hiroshiyui) - Wednesday, 28 September 2011, 12:03 GMT
@Issac:

Yes, ibus_config_get_value() has been changed in IBus 1.4,
you can see the following code snippet about what I'd hacked for ibus-array
to edit your ibus-hangul source code.

---8<----------------------------------------------------------------
void
ibus_array_init (IBusBus *bus)
{
- gboolean res;
+ GVariant * res;
GValue value = { 0, };

array_context = array_create_context();
@@ -130,16 +130,16 @@ ibus_array_init (IBusBus *bus)
is_special_only = FALSE;

res = ibus_config_get_value (config, "engine/Array",
- "SpecialNotify", &value);
- if (res) {
+ "SpecialNotify");
+ if (res != NULL) {
const gchar* str = g_value_get_string(&value);
if (g_strcmp0(str, "1") == 0)
is_special_notify = TRUE;
}

res = ibus_config_get_value (config, "engine/Array",
- "SpecialOnly", &value);
- if (res) {
+ "SpecialOnly");
+ if (res != NULL) {
const gchar* str = g_value_get_string(&value);
if (g_strcmp0(str, "1") == 0)
is_special_only = TRUE;
---8<----------------------------------------------------------------
Comment by Sunjae Park (darehanl) - Wednesday, 28 September 2011, 20:46 GMT
@Hirosh Yui (hiroshiyui)

You probably also want to change a couple more lines.

---8<----------------------------------------------------------------
- const gchar* str = g_value_get_string(&value);
+ const gchar* str = g_variant_get_string (res, NULL);
---8<----------------------------------------------------------------

I've gotten ibus-hangul working with the changes to ibus_config_get_value, but not for ibus-anthy. It's being run against python3 and fails to find the "ibus" module.
Comment by Isaac Lindgren (the_sad_clown) - Thursday, 29 September 2011, 11:34 GMT
Thank you. The above worked perfectly.
Comment by Eric Belanger (Snowman) - Sunday, 02 October 2011, 03:44 GMT
The following has been fixed (updated or rebuilt):
ibus-sunpinyin
ibus-m17n
ibus-unikey

I'm checking out the rest.
Comment by Eric Belanger (Snowman) - Sunday, 02 October 2011, 08:14 GMT
I rebuilt the rest:
ibus-chewing
ibus-pinyin
ibus-hangul

I updated ibus-pinyin to 1.3.99.20110706 which is listed as unstable because the old stable 1.3.11 version wasn't building. Let us know if there are any problems with it.

Also, ibus-chewing didn't seem to work after rebuilding it but I'm not familiar with ibus so I might be doing something wrong. Try it and post if it works or not.

Comment by Auguste Pop (Auguste) - Sunday, 02 October 2011, 08:23 GMT
is ibus-table affected by this?
Comment by Hirosh Yui (hiroshiyui) - Sunday, 02 October 2011, 08:28 GMT
@Snowman:

Thanks. I have been tested ibus-chewing release version & git version, all of them aren't work, need some hacking.

@Auguste:

No, ibus-table and its based tables are work as expectd.
Comment by Ong Kuan Yang (ong) - Sunday, 02 October 2011, 08:39 GMT
I confirm that ibus-pinyin and ibus-sunpinyin is now working.
However, ibus is still not starting automatically.
This can be solved in gnome by entering gnome-session-properties and adding ibus-daemon.
IMO, this is a bug as the previous ibus does the above automatically upon installation.
Comment by Hirosh Yui (hiroshiyui) - Tuesday, 04 October 2011, 03:16 GMT
Hi all,

I have found a patch which fixes ibus-chewing:
http://pkgs.fedoraproject.org/gitweb/?p=ibus-chewing.git;a=commitdiff;h=23e400e03862f547c76f62d5335ca260e2320c1b

The attachment file is an ABS source package (that contains a PKGBUILD and a stripped patch file),
welcome to test & review it. Thanks!
Comment by Eric Belanger (Snowman) - Wednesday, 05 October 2011, 06:12 GMT
Thanks. ibus-chewing-1.3.9.2-5 should work.

As this bug report is quite messy, the only remaining problem is that ibus doesn't start automatically at startup. Is that correct?
Comment by Hirosh Yui (hiroshiyui) - Wednesday, 05 October 2011, 06:36 GMT
@Snowman

I'm not sure, but this autostart problem can be solved by put (copy or make a symbolic link) /usr/share/applications/ibus.desktop to /etc/xdg/autostart/ . Maybe put such a line in ibus's PKGBUILD or ibus.install is OK.

Loading...