刘荣星的博客

  • 留言
  • About
一个关注Linux/BSD运维等相关知识的博客
  1. 首页
  2. FreeBSD
  3. 正文

解决 FreeBSD10.0 Fctix 无法调出五笔输入法问题

2014-09-13 18118点热度 0人点赞 3条评论

困扰我大半年的输入法问题今天终于解决了。

至从安装了FreeBSD10,心中最不快的事情就是只能使用Fcitx的拼音输入法(安装了五笔,但是调不出来),因为本人从小就使用五笔输入法。

期间不下三次在虚拟机中试验安装Fctix,但一直没有找到解决方法,这次花了两天多的时间从安装系统、安装 xfce4 桌面、到安装 Fctix 输入法。希望满满,但装好后还是调不出五笔输入法。

无意间打开着 Treminal 在调试 Fctix,发现 Treminal 中出现下面的语句。

(ERROR-59066 /usr/ports/chinese/fcitx/work/fcitx-4.2.6.1/src/lib/fcitx/ime.c:280) 输入法: 打开/usr/local/lib/fcitx/fcitx-table.so 失败 /usr/local/lib/fcitx/fcitx-table.so: Undefined symbol "TableMetaDataRemove"

明显是有关table,也就是和调不出五笔等其它输入法有关。

在论坛里只有一位老兄发贴讨论了这个问题,地址如下:
https://www.freebsdchina.org/forum/topic_63954.html
他在里面说到最后的解决方法是

从 FTP 上下了 zh-fcitx 包,解出fcitx-table.so替代了系统中的,就可以了!

Gehaowu 说 “据说。。。用gcc编译的是没这个问题的”,但是他只打拼音,没深究。

试着在Google中打 zh-fcitx 的包,找了几个替换 /usr/local/lib/fcitx/fcitx-table.so 这个都不行,最后想到 FreeBSD 10.0 开始才不使用 gcc 编译,那可以找 FreeBSD 9.0的包来试试。

在这个地址下载到了 FreeBSD 9.0 的 zh-fcitx-4.2.6.1_4.txz
http://pkg.dicrurus.com/info?arch=freebsd:9:x86:64&pkg=zh-fcitx
http://pkg.freebsd.org/freebsd:9:x86:64/latest/All/zh-fcitx-4.2.6.1_4.txz

鉴于现在这个包已经在网上很难找着了,我把这个包放上传放在博客里,下载地址如下:

https://www.liurongxing.com/wp-content/uploads/src/zh-fcitx-4.2.6.1_4.txz

解压、单独替换系统中的 /usr/local/lib/fcitx/fcitx-table.so 这个库文件,重启 Fcitx,没有出现 /usr/local/lib/fcitx/fcitx-table.so: Undefined symbol "TableMetaDataRemove" 这样的问题了。
查看右上角的输入法,现在已经出现其它安装的输入法了。如图:

FreeBSD Fcitx 五笔输入法

FreeBSD Fcitx 五笔输入法

=================================================================

cd /usr/ports/chinese/fcitx
make install clean

Installing zh-fcitx-4.2.8.6_1...
************************************************************************

Remember to set the environment variable XMODIFIERS:

        csh/tcsh:       setenv XMODIFIERS @im=fcitx
        sh/bash:        export XMODIFIERS='@im=fcitx'

For GTK+ programs, you may want to set:

                        export GTK3_IM_MODULE=fcitx

For Qt4 programs, we recommend you to use

        qtconfig-qt4: /usr/ports/misc/qt4-qtconfig

instead of to manually set QT4_IM_MODULE.

To start fcitx with your desktop, just

        cp /usr/local/share/applications/fcitx.desktop \
            ~/.config/autostart/

************************************************************************

===> SECURITY REPORT: 
      This port has installed the following files which may act as network
      servers and may therefore pose a remote security risk to the system.
/usr/local/lib/fcitx/fcitx-remote-module.so

      If there are vulnerabilities in these programs there may be a security
      risk to the system. FreeBSD makes no guarantee about the security of
      ports included in the Ports Collection. Please type 'make deinstall'
      to deinstall the port if this is a concern.

      For more information, and contact details about the security
      status of this software, see the following webpage: 
https://fcitx-im.org/wiki/Fcitx
===>  Cleaning for zh-fcitx-4.2.8.6_1

cd /usr/ports/chinese/fcitx-configtool
make install clean
cd /usr/ports/chinese/fcitx-table-extra
make install clean

cd /usr/ports/chinese/fcitx-ui-light
make install clean

Installing zh-fcitx-ui-light-0.1.3_1...
************************************************************************

Replace your `fcitx` command with
	fcitx -u fcitx-light-ui
to start Fcitx with this lightweight UI.

************************************************************************

fcitx 进入桌面自动启动 我是在 ~/.profile 这个文件里加上 fcitx& 就实现了启动。

cat .profile 
setenv XMODIFIERS @im=fcitx
setenv XIM fcitx
setenv XIM_PROGRAM fcitx
setenv GTK_IM_MODULE fcitx
setenv QT_IM_MODULE fcitx

fcitx&
cat .profile

Fcitx输入法

本来是写X的,但是fcitx和X还是有点关系的,使用startx和使用gdm登录的fcitx的配置方法是不一样的,这里对使用gdm的配置方法做一下说明。

  • 首先,你要安装:
# cd /usr/ports/chinese/fcitx/
# make install clean
  • 然后,你需要配置环境变量:

配置环境变量的方法并不唯一,在这里通过profile来实现,把下述内容下如.profile,

LC_CTYPE=zh_CN.UTF-8; export LC_CTYPE
XMODIFIERS=@im=fcitx; export XMODIFIERS
fcitx&

前面两行是配置fcitx运行时需要的环境变量,最后一行是告诉系统开机自动运行fcitx。按照上述配置完以后,fcitx会在进入gnome桌面环境以后自动运行,激活的命令是Ctrl+Space,如果你觉得fcitx默认的外观比较难看的话,你可以修改你home下面的.fcitx/config中的参数文件来调整fcitx的外观。

配置fcitx的关键是环境变量,使用gdm和使用startx对环境变量的处理是不一样的。使用其他的XDM时,主要注意的问题也是环境变量,就是说你所使用的XDM如何处理对待环境变量。在上面的配置中我使用UFT-8编码方案,其具体含义可参考locale环境变量的资料,此处不做详细介绍。

另一种方法: 在~/.xinitrc加入

export XMODIFIERS=@im=fcitx
fcitx -d &
标签: Fcitx FreeBSD 五笔输入法
最后更新:2015-11-15

JavasBoy

这个人很懒,什么都没留下

点赞
< 上一篇
下一篇 >

文章评论

  • bienilz

    您好,我也是为这输入法头疼,您给的地址的包已经全部换成zh-fcitx-4.2.6.1_5.txz了,和我系统上的一样,能否麻烦给我一份你然fcitx-table.so ,谢谢。bienilz.w@qq.com

    2014-12-06
    回复
    • JavasBoy

      @bienilz Hi bienilz:
      我刚才也只找到了低一个版本的不知道可不可以,你先试下。
      晚点我传系统上的给你。
      http://pkg.freebsd.org/freebsd:9:x86:64/release_3/All/zh-fcitx-4.2.6.1_3.txz

      2014-12-12
  • 琉璃瓦

    装好后还是调不出五笔输入法

    2014-12-17
    回复
  • razz evil exclaim smile redface biggrin eek confused idea lol mad twisted rolleyes wink cool arrow neutral cry mrgreen drooling persevering
    取消回复

    最新 热点 随机
    最新 热点 随机
    CentOS7 python2 安装 elasticsearch 模块 在VMWare Workstation虚拟机里使用 yubikey Gentoo Gnome 登陆界面开启触摸板轻击 python3去除emoji表情符号 记录几个内网广播包 Linux Mint 20 gnome-terminal 使用等距更纱黑体 SC字体
    Autodesk Custom Red Hat Enterprise Linux Client 5.3 x86_64 DVD Debian6 编译安装vim 7.4 我的一点点回忆 记录 Linux Iptables 防火墙 Dropped Packets 日志 eMule电骡使用OpenVPN获取HighID配置教程 FreeBSD查看带宽占用情况,CPU,硬盘IO 虚拟内存等命令
    分类
    • After Effects / 20篇
    • Apple / 5篇
    • Archlinux / 4篇
    • Bash / 2篇
    • Cinema 4D / 1篇
    • Docker / 1篇
    • eMule / 2篇
    • FreeBSD / 9篇
    • Gentoo / 1篇
    • Go / 2篇
    • gpg / 1篇
    • Graphics / 15篇
    • Haproxy / 1篇
    • ingress / 1篇
    • IntelliJ_IDEA / 1篇
    • java / 2篇
    • kafka / 1篇
    • Linux / 24篇
    • MySQL / 3篇
    • network / 3篇
    • Network / 4篇
    • Nginx / 5篇
    • Perl / 4篇
    • Python / 9篇
    • Python 操作符 / 1篇
    • Python 正则 / 2篇
    • rose / 1篇
    • Script / 4篇
    • Tornado / 1篇
    • Vim / 5篇
    • 学习 / 24篇
    • 电脑 / 29篇
    • 那不勒斯 / 1篇
    • 随笔 / 45篇
    标签聚合
    MAC python AE After Effects 双系统 Linux FreeBSD Graphics

    COPYRIGHT © 2025 刘荣星的博客. ALL RIGHTS RESERVED.

    Theme Kratos Made By Seaton Jiang