Japanese Input ibus-mozc OR uim-mozc

If you are looking for a specific 64-bit package and you can't find it in any of the 64-bit repos, please post a request for it here
Post Reply
rych
Samurai
Samurai
Posts: 196
Joined: 04 Jan 2014, 04:27
Distribution: Porteus 4.0 64 LXDE
Location: NZ

Japanese Input ibus-mozc OR uim-mozc

Post#1 by rych » 04 Jun 2021, 09:33

... for Porteus 5.0rc2 OpenBox please.

I've installed fonts, that's easy. Then tried to install scim-anthy (Ctrl+Space doesn't work, and it's old anyway) and fcitx-mozc (breaks my keyboard input, and doesn't work anyway). Instead of further investigating and spending days and weeks on this, maybe someone could help me out. And actually it seems that the modern recommendation for Japanese input on Linux is to use mozc as the IME and ibus (or uim) as the framework.

So I guess ideally, I'd like to find

Code: Select all

ibus.xzm + ibus-mozc.xzm
OR

Code: Select all

uim.xzm + uim-mozc.xzm
Each might require separate modules to work in GTK and QT apps, and an extra config app.
Thanks. I don't have much hope and so will continue trying but it's taking me days, so please help if you can

neko
DEV Team
DEV Team
Posts: 1775
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Japanese Input ibus-mozc OR uim-mozc

Post#2 by neko » 04 Jun 2021, 13:30

@rych

Maybe it is a reference.

[scim-anthy]
Japanese locale modules for Porteus (Post by neko #78259)
=== For Porteus v5.0rc2 Japanese version ===
2.Input method

[fcitx-mozc]
ArchLinux packages manager for Porteus (Post by neko #82512)
APorteus-XFCE_ja-v21.05.30-x86_64.iso
/porteus/modules/005-fcitx-mozc.xzm


Thanks.

rych
Samurai
Samurai
Posts: 196
Joined: 04 Jan 2014, 04:27
Distribution: Porteus 4.0 64 LXDE
Location: NZ

Japanese Input ibus-mozc OR uim-mozc

Post#3 by rych » 05 Jun 2021, 05:55

Thank you neko, but the 005-fcitx-mozc.xzm doesn't work. (The 009-input_ja-x86_64-6.xzm (18 M) with scim was the one which I tried before which didn't work). So I'd settle for fcitx-mozc. But even though I rebuilt it with renamed subfolders

Code: Select all

usr/lib -> usr/lib64 and home/guest -> root
it still doesn't start, doesn't register, doesn't update ENV and doesn't list mozc. In Fcitx Config window there is no mozc. Other things appear to be broken:

Code: Select all

root@porteus:~# fcitx-autostart
...
(ERROR-4157 ui.c:165) no usable user interface.
(ERROR-4157 frontend.c:565) No available frontend
(ERROR-4157 instance.c:443) Exiting.

Code: Select all

root@porteus:~# fcitx-diagnose 
# System Info:
1.  `uname -a`:

        Linux porteus.example.net 5.4.57-porteus #1 SMP Sun Aug 9 09:03:28 UTC 2020 x86_64 Intel(R) Core(TM) i5-6600 CPU @ 3.30GHz GenuineIntel GNU/Linux

2.  `lsb_release`:

    `lsb_release` not found.

3.  `/etc/lsb-release`:

    `/etc/lsb-release` not found.

4.  `/etc/os-release`:

        NAME=Porteus
        VERSION="5"
        ID=slackware
        VERSION_ID=5.0
        PRETTY_NAME="Porteus 5.0"
        ANSI_COLOR="0;34"
        CPE_NAME="cpe:/o:porteus:porteus_linux:5"
        HOME_URL="http://www.porteus.org/"
        SUPPORT_URL="http://forum.porteus.org/"
        BUG_REPORT_URL="http://forum.porteus.org/"

5.  Desktop Environment:

    Cannot determine desktop environment.

6.  Bash Version:

        BASH_VERSION='5.0.18(1)-release'

# Environment:
1.  DISPLAY:

        DISPLAY=':1'

2.  Keyboard Layout:

    1.  `setxkbmap`:

            xkb_keymap {
            	xkb_keycodes  { include "evdev+aliases(qwerty)"	};
            	xkb_types     { include "complete"	};
            	xkb_compat    { include "complete+ledscroll(group_lock)"	};
            	xkb_symbols   { include "pc+us+ru(phonetic_winkeys):2+inet(evdev)+group(switch)+group(alt_shift_toggle)+terminate(ctrl_alt_bksp)"	};
            	xkb_geometry  { include "pc(pc105)"	};
            };

    2.  `xprop`:

            _XKB_RULES_NAMES(STRING) = "evdev", "pc105", "us,ru", ",phonetic_winkeys", "grp:switch,grp:alt_shift_toggle,grp_led:scroll,terminate:ctrl_alt_bksp"

3.  Locale:

    1.  All locale:

            C
            C.utf8
            POSIX
            en_US
            en_US.utf8

    2.  Current locale:

            LANG=en_US.UTF-8
            LC_CTYPE="en_US.UTF-8"
            LC_NUMERIC="en_US.UTF-8"
            LC_TIME="en_US.UTF-8"
            LC_COLLATE=C
            LC_MONETARY="en_US.UTF-8"
            LC_MESSAGES="en_US.UTF-8"
            LC_PAPER="en_US.UTF-8"
            LC_NAME="en_US.UTF-8"
            LC_ADDRESS="en_US.UTF-8"
            LC_TELEPHONE="en_US.UTF-8"
            LC_MEASUREMENT="en_US.UTF-8"
            LC_IDENTIFICATION="en_US.UTF-8"
            LC_ALL=

4.  Directories:

    1.  Home:

            /root

    2.  `${XDG_CONFIG_HOME}`:

        Environment variable `XDG_CONFIG_HOME` is not set.

        Current value of `XDG_CONFIG_HOME` is `~/.config` (`/root/.config`).

    3.  Fcitx Settings Directory:

        Current fcitx settings directory is `~/.config/fcitx` (`/root/.config/fcitx`).

5.  Current user:

    The script is run as root (0).

    1.  `sudo` Environment Variables:

        SUDO_COMMAND is not set.

        SUDO_USER is not set.

        SUDO_UID is not set.

        SUDO_GID is not set.

    2.  Running as root:

        **You are probably logging in as `root` or using `sudo` to run this script. This either means you have security problems or the result of this script may not be accurate. See [Why is it bad to run as root](https://www.google.com/search?q=Why+is+it+bad+to+run+as+root) or [sudo environment variables](https://www.google.com/search?q=sudo+environment+variables) for more information.**

# Fcitx State:
1.  executable:

    Found fcitx at `/usr/bin/fcitx`.

2.  version:

    Fcitx version: `4.2.9.7`

3.  process:

    **Fcitx is not running.**
    **Please check the Configure link of your distribution in [Beginner's Guide](http://fcitx-im.org/wiki/Beginner%27s_Guide) for how to setup fcitx autostart.**

# Fcitx Configure UI:
1.  Config Tool Wrapper:

    Found fcitx-configtool at `/usr/bin/fcitx-configtool`.

2.  Config GUI for gtk2:

    **Config GUI for gtk2 not found.**

3.  Config GUI for gtk3:

    Found `fcitx-config-gtk3` at `/usr/bin/fcitx-config-gtk3`.

4.  Config GUI for kde:

    **`kcmshell4` not found.**

# Frontends setup:
## Xim:
1.  `${XMODIFIERS}`:

    **XMODIFIERS is not set**

    **Please set environment variable XMODIFIERS to "@im=fcitx" using the tool your distribution provides or add `export XMODIFIERS=@im=fcitx` to your `~/.xprofile`. See [Input Method Related Environment Variables: XMODIFIERS](http://fcitx-im.org/wiki/Input_method_related_environment_variables#XMODIFIERS).**
    Xim Server Name from Environment variable is fcitx.

2.  XIM_SERVERS on root window:

    **Cannot find xim_server on root window.**

## Qt:
1.  qt4 - `${QT4_IM_MODULE}`:

    **Please set environment variable QT_IM_MODULE to "fcitx" using the tool your distribution provides or add `export QT_IM_MODULE=fcitx` to your `~/.xprofile`. See [Input Method Related Environment Variables: QT_IM_MODULE](http://fcitx-im.org/wiki/Input_method_related_environment_variables#QT_IM_MODULE).**

2.  qt5 - `${QT_IM_MODULE}`:

    **Please set environment variable QT_IM_MODULE to "fcitx" using the tool your distribution provides or add `export QT_IM_MODULE=fcitx` to your `~/.xprofile`. See [Input Method Related Environment Variables: QT_IM_MODULE](http://fcitx-im.org/wiki/Input_method_related_environment_variables#QT_IM_MODULE).**

3.  Qt IM module files:

    Found fcitx qt module: `/usr/lib64/fcitx/qt/libfcitx-quickphrase-editor5.so`.
    Found fcitx im module for Qt5: `/usr/lib64/qt/plugins/platforminputcontexts/libfcitxplatforminputcontextplugin.so`.
    **Cannot find fcitx input method module for Qt4.**

## Gtk:
1.  gtk - `${GTK_IM_MODULE}`:

    **Please set environment variable GTK_IM_MODULE to "fcitx" using the tool your distribution provides or add `export GTK_IM_MODULE=fcitx` to your `~/.xprofile`. See [Input Method Related Environment Variables: GTK_IM_MODULE](http://fcitx-im.org/wiki/Input_method_related_environment_variables#GTK_IM_MODULE).**

2.  `gtk-query-immodules`:

    1.  gtk 2:

        Found `gtk-query-immodules` for gtk `2.24.32` at `/usr/bin/gtk-query-immodules-2.0`.
        Version Line:

            # Created by /usr/bin/gtk-query-immodules-2.0 from gtk+-2.24.32

        Found fcitx im modules for gtk `2.24.32`.

            "/usr/lib64/gtk-2.0/2.10.0/immodules/im-fcitx.so" 
            "fcitx" "Fcitx (Flexible Input Method Framework)" "fcitx" "/usr/share/locale" "ja:ko:zh:*" 

    2.  gtk 3:

        Found `gtk-query-immodules` for gtk `3.24.21` at `/usr/bin/gtk-query-immodules-3.0`.
        Version Line:

            # Created by /usr/bin/gtk-query-immodules-3.0 from gtk+-3.24.21

        Found fcitx im modules for gtk `3.24.21`.

            "/usr/lib64/gtk-3.0/3.0.0/immodules/im-fcitx.so" 
            "fcitx" "Fcitx (Flexible Input Method Framework)" "fcitx" "/usr/share/locale" "ja:ko:zh:*" 

3.  Gtk IM module cache:

    1.  gtk 2:

        Found immodules cache for gtk `2.24.32` at `/usr/lib64/gtk-2.0/2.10.0/immodules.cache`.
        Version Line:

            # Created by /usr/bin/gtk-query-immodules-2.0-64 from gtk+-2.24.32

        **Failed to find fcitx in immodule cache at `/usr/lib64/gtk-2.0/2.10.0/immodules.cache`**

        **Cannot find fcitx im module for gtk 2 in cache.**

    2.  gtk 3:

        Found immodules cache for gtk `3.24.21` at `/usr/lib64/gtk-3.0/3.0.0/immodules.cache`.
        Version Line:

            # Created by /usr/bin/gtk-query-immodules-3.0-64 from gtk+-3.24.21

        **Failed to find fcitx in immodule cache at `/usr/lib64/gtk-3.0/3.0.0/immodules.cache`**

        **Cannot find fcitx im module for gtk 3 in cache.**

4.  Gtk IM module files:

    1.  gtk 2:

        All found Gtk 2 immodule files exist.

    2.  gtk 3:

        All found Gtk 3 immodule files exist.

# Configuration:
## Fcitx Addons:
1.  Addon Config Dir:

    Found fcitx addon config directory: `/usr/share/fcitx/addon`.

2.  Addon List:

    1.  Found 27 enabled addons:

            fcitx-autoeng
            fcitx-chttrans
            fcitx-classic-ui
            fcitx-clipboard
            fcitx-dbus
            fcitx-freedesktop-notify
            fcitx-fullwidth-char
            fcitx-imselector
            fcitx-ipc
            fcitx-ipcportal
            fcitx-keyboard
            fcitx-kimpanel-ui
            fcitx-mozc
            fcitx-notificationitem
            fcitx-pinyin-enhance
            fcitx-pinyin
            fcitx-punc
            fcitx-quickphrase
            fcitx-remote
            fcitx-spell
            fcitx-table
            fcitx-unicode
            fcitx-vk
            fcitx-x11
            fcitx-xim
            fcitx-xkb
            fcitx-xkbdbus

    2.  Found 2 disabled addons:

            fcitx-light-ui
            fcitx-qw

3.  Addon Libraries:

    All libraries for all addons are found.

4.  User Interface:

    Found 2 enabled user interface addons:

        fcitx-classic-ui
        fcitx-kimpanel-ui

## Input Methods:
1.  Found 0 enabled input methods:

2.  Default input methods:

    **You don't have any input methods enabled.**

# Log:
1.  `date`:

        Sat Jun  5 17:42:21 Local time zone must be set--see zic manual page 2021

2.  `~/.config/fcitx/log/`:

        total 0

3.  `~/.config/fcitx/log/crash.log`:

    `~/.config/fcitx/log/crash.log` not found.


neko
DEV Team
DEV Team
Posts: 1775
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Japanese Input ibus-mozc OR uim-mozc

Post#4 by neko » 05 Jun 2021, 11:59

@rych

Porteus-OPENBOX_ja-v5.0rc2-x86_64.iso (399 M)
https://www.mediafire.com/file/xkqyjecv ... x86_64.iso
md5sum: 0436068f68db35c6ebcd7d8bf5b7e9bd Porteus-OPENBOX_ja-v5.0rc2-x86_64.iso

This ISO has 2 input methos (SCIM & FCITX).

SCIM is 009-input_ja-x86_64-6.xzm. Its running is success.

FCITX is 005-fcitx-mozc.xzm modified alittle. Its running is not success.
[Cause]
1. Modifying has some issues.
2. It has some package dependency issues (between Archlinux version & Slacksware version).
3. Initial process is lack.
4. others.

More analyzing is needed.


Thanks.

rych
Samurai
Samurai
Posts: 196
Joined: 04 Jan 2014, 04:27
Distribution: Porteus 4.0 64 LXDE
Location: NZ

Japanese Input ibus-mozc OR uim-mozc

Post#5 by rych » 05 Jun 2021, 14:36

neko, thanks, I'll try your module tomorrow.

Today I build the 4 relevant modules from (slightly older) https://slackbuilds.org/result/?search=fcitx&sv=14.2. It works except:

1. I guess I need to make a tiny fcitx-setup.xzm module that inserts a .sh and .csh files into etc/profile.d tree that will define the following for me

Code: Select all

export GTK_IM_MODULE=fcitx
export XMODIFIERS=@im=fcitx
export QT_IM_MODULE=fcitx
2. Mozc doesn't appear in the input list of fcitx-config GUI tool! A few Chinese inputs are there along with a million of Keyboard-BLA but not Mozc! Maybe after we've done 1) ubove properly or some other setting, or even that I run X-Windows as root instead of a user -- that would be a very exotic reason though. For now I can input Chinese characters, gives me candidates etc. I wonder how that happens.


Alternatively, we could try fcitx5

Code: Select all

https://wiki.archlinux.org/title/Fcitx5
and https://fedoraproject.org/wiki/I18N/Fcitx5

Also, apparently we should use the mozc-ut that has a much larger dictionary http://linuxplayers.g1.xrea.com/mozc-ut.html

rych
Samurai
Samurai
Posts: 196
Joined: 04 Jan 2014, 04:27
Distribution: Porteus 4.0 64 LXDE
Location: NZ

Japanese Input ibus-mozc OR uim-mozc

Post#6 by rych » 06 Jun 2021, 07:13

neko, your 009-input_ja-x86_64-6.xzm now works on my system. I had to cleanup every mention of fcitx in my /changes folder first, as scim was trying to load some fcitx libraries (!!), through some im-cache or somthing -- now Ctrl+Space and everything works on a clean Scim-only system.

I'm now afraid to even try your 005-fcitx-mozc.xzm so that not to pollute my system again and because as you say "Its running is not success" anyway.

I have a new request though. I can live with scim-anthy thank you. But I'd be very interested to try

Code: Select all

fcitx5-mozc / fcitx5-mozc-ut
Alternatively

Code: Select all

ibus-mozc / ibus-mozc-ut

neko
DEV Team
DEV Team
Posts: 1775
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

Japanese Input ibus-mozc OR uim-mozc

Post#7 by neko » 19 Jun 2021, 06:03

@rych

The fcitx-mozc package is contained in slackonly.
https://packages.slackonly.com/pub/pack ... slonly.txz

This is for version 14.2.
However, the current Porteus consists of older packages.
From here, I entered a maze that would be a big task.
I'm currently working on configuring Porteus with a "slackware-current" version of the package,
and it's unlikely to finish for the time being.

Thanks.

Post Reply