Ubuntu 16.04下安装sogou 拼音输入法的错误问题

原创 2016年07月13日 22:06:50

引言: sogou输入法是市场上最为好用和流行的输入法,最为良心的是还有Linux版本,这让我等Linux人士欢呼雀跃。在新出的Ubuntu 16.04上安装sogou输入法的时候,碰到了一些问题,主要还是依赖包没有正确安装,我们一起来看如何来解决这个问题。

1.  环境介绍

   Ubuntu 16.04,   sogou输入法: sogoupinyin_2.0.0.0078_amd64

2.  问题表现

     sudo dpkg -i sogoupinyin_2.0.0.0078_amd64.deb
   错误信息如下:
sogoupinyin : Depends: libopencc2 but it is not installable or
libopencc1 but it is not going to be installed
Depends: fcitx-libs (>= 4.2.7) but it is not going to be installed
Depends: fcitx-libs-qt (>= 4.2.7) but it is not going to be installed
Recommends: fonts-droid-fallback but it is not going to be installed or
fonts-droid but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

一看就知道是依赖包存在问题

3.  问题分析

   之前在Ubuntu 15.10的版本之时,使用同样的sogou版本,不存在此类的问题。 但是在Ubuntu 16.04中,却存在此类问题,说明Ubuntu升级之后,sogou输入法并未做相应的系统兼容性测试, 故起最高的Ubuntu支持版本时15.10.

    虽然我们知道了问题,但是该如何解决呢?

    基于错误信息,我们发现起依赖包有以下几个: libopencc1 libopencc2,  fcitx-libs, fcitx-libs-qt  font-droid-fallback.  

4.  试错分析

     试错1:

bladestone@bladestone-laptop:~$ sudo apt install fcitx-libs
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 sogoupinyin : Depends: libopencc2 but it is not installable or
                        libopencc1 but it is not going to be installed
               Depends: fcitx-libs-qt (>= 4.2.7) but it is not going to be installed
               Recommends: fonts-droid-fallback but it is not going to be installed or
                           fonts-droid but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
   试错2:    
bladestone@bladestone-laptop:~$ sudo apt install fcitx-libs-qt
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 sogoupinyin : Depends: libopencc2 but it is not installable or
                        libopencc1 but it is not going to be installed
               Depends: fcitx-libs (>= 4.2.7) but it is not going to be installed
               Recommends: fonts-droid-fallback but it is not going to be installed or
                           fonts-droid but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
   试错3:
bladestone@bladestone-laptop:~$ sudo apt install fcitx-libs-qt fcitx-libs
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 sogoupinyin : Depends: libopencc2 but it is not installable or
                        libopencc1 but it is not going to be installed
               Recommends: fonts-droid-fallback but it is not going to be installed or
                           fonts-droid but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
  试错4:

bladestone@bladestone-laptop:~$ sudo apt install fonts-droid-fallback
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 sogoupinyin : Depends: libopencc2 but it is not installable or
                        libopencc1 but it is not going to be installed
               Depends: fcitx-libs (>= 4.2.7) but it is not going to be installed
               Depends: fcitx-libs-qt (>= 4.2.7) but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
  试错5:
bladestone@bladestone-laptop:~$ sudo apt install libopencc1
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 sogoupinyin : Depends: fcitx-libs (>= 4.2.7) but it is not going to be installed
               Depends: fcitx-libs-qt (>= 4.2.7) but it is not going to be installed
               Recommends: fonts-droid-fallback but it is not going to be installed or
                           fonts-droid but it is not installable
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
 分析: 经过各种尝试,发现依然无法正常解决问题,类库包之间的依赖关系还是非常复杂的。

5. 问题解决

   5.1 移除sogou输入法, 由于其安装不完整

 sudo apt remove sogoupinyin
  执行过程:
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages will be REMOVED:
  sogoupinyin
0 upgraded, 0 newly installed, 1 to remove and 43 not upgraded.
1 not fully installed or removed.
After this operation, 42.6 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 214444 files and directories currently installed.)
Removing sogoupinyin (2.0.0.0078) ...
Processing triggers for libglib2.0-0:amd64 (2.48.1-1~ubuntu16.04.1) ...
Processing triggers for hicolor-icon-theme (0.15-0ubuntu1) ...
Processing triggers for shared-mime-info (1.5-2ubuntu0.1) ...
Processing triggers for bamfdaemon (0.5.3~bzr0+16.04.20160523-0ubuntu1) ...
Rebuilding /usr/share/applications/bamf-2.index...
Processing triggers for gnome-menus (3.13.3-6ubuntu3) ...
Processing triggers for desktop-file-utils (0.22-1ubuntu5) ...
Processing triggers for mime-support (3.59ubuntu1) ...
  5.2 正确的包安装姿势

sudo apt install libopencc1 fcitx-libs fcitx-libs-qt fonts-droid-fallback
  5.3 重新安装sogou输入法
sudo dpkg -i sogoupinyin_2.0.0.0078_amd64.deb
  结果 一切顺利,没有报类似的错误信息

6. 总结

    安装依赖需要一次安装完成,切勿单个安装,主要是由于包之间彼此会有一定的依赖关系,这个是你无法准确定位的,故在 一次安装动作中做完。

  另外, sogou输入法的Linux版本目前只兼容到Ubunut 15.10, 请大家彼此周知该情况。

版权声明:本文为博主原创文章,未经博主允许不得转载。

相关文章推荐

【Ubuntu下安装配置】右键终端、google-chrome安装、sogou拼音安装

sudo apt-get install nautilus-open-terminal sudo dpkg -i sogoupinyin_1.2.0.0056_amd64.deb Package f...

Linux入门(1)——Ubuntu16.04安装搜狗拼音

在网址下载搜狗deb包:http://pinyin.sogou.com/linux/ 将下载的sogoupinyin_2.1.0.0082_amd64.deb放在根目录下。 安装搜狗拼音: ...

apt-get 依赖版本过高(Depends: g++-4.6(>= 4.6.3-1)but it is not going)

在文章的开头,首先要声明,各个版本的Ubuntu的更新源是不同的,请大家使用自己相对应的源进行更新,不然会发生很多依赖问题!      昨天在装edb,发现总是报错误,具体错误的信息不大...

Ubuntu 16.04下安装搜狗拼音输入法的错误问题

引言: sogou输入法是市场上最为好用和流行的输入法,最为良心的是还有Linux版本,这让我等Linux人士欢呼雀跃。在新出的Ubuntu 16.04上安装sogou输入法的时候,碰到了一些问题,主...

ubuntu 下安装搜狗输入法报错

ubuntu 下安装搜狗输入法报错

Ubuntu 16.04 LTS安装sogou输入法详解

最近开始学习linux 在安装输入法中遇到的一些问题,最终成功安装,也得益于网络上的前辈写的文章,现在将全部安装步骤以及遇到的一些问题总结如下:   基本上分三步走 1,添加fcitx的键盘输入...

在英语环境下的 Ubuntu14.04中安装 Sogou搜狗拼音输入法

在英语环境下的 Ubuntu14.04中安装 Sogou搜狗拼音输入法 添加UbuntuKylin的源 a. 打开software & update–>other software–>点击add–>...

Ubuntu 16.04安装sogou 拼音输入法

安装完Ubuntu 16.04后,要更换为国内的软件源:           sudo gedit /etc/apt/sources.list   #用文本编辑器打开源列表 在文件开头添加下面的阿...
  • ljheee
  • ljheee
  • 2016-10-29 20:36
  • 9336

Ubuntu 13.10 14.04 用sogou拼音输入法替换ibus

Ubuntu 13.10 用sogou拼音输入法替换ibus Ubuntu 13.10的ibus输入法有点问题,怎么也不能在emacs 24.3中输入中文。最后决定切换到fcitx,发现这个...

ubuntu14.04 安装搜狗拼音输入法及异常问题解决

去搜狗拼音官网:http://pinyin.sogou.com/linux/?r=pinyin 下载安装包:sogoupinyin_2.0.0.0068_amd64.deb 双击通过 软件管理器安...
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:深度学习:神经网络中的前向传播和反向传播算法推导
举报原因:
原因补充:

(最多只允许输入30个字)