ubuntu 安装最新版本的meld


因为ubuntu 16.04 版本系统自带的meld版本较低,不支持中文(中文乱码)

  1. 官方网站 下载最新 稳定版 并解压

    $ wget https://download.gnome.org/sources/meld/3.16/meld-3.16.4.tar.xz
    $ xz -d meld-3.16.4.tar.xz
    $ tar -xvf meld-3.16.4.tar
  2. 查看README,安装 依赖包

    Requirements
    ------------
    
    * Python 2.7
    * GTK+ 3.14
    * GLib 2.36
    * PyGObject 3.8
    * GtkSourceView 3.14
    
    
Build requirements
------------------

* intltool
* itstool
```
安装 **依赖包**

```bash
$ sudo apt-get install intltool itstool
$ sudo apt install libgtk-3-dev
$ sudo apt install libgtksourceview-3.0-dev
$ sudo apt install libxml2-utils
```
  1. 执行setup.py 进行安装

    $ cd meld-3.16.4
    $ python setup.py install --prefix=/usr
  2. 查看版本, 查看是否安装成功

    $ meld --version
    meld 3.16.4

meld-3.16.4 $ python setup.py install
  ...
copying and adjusting bin/meld -> build/scripts-2.7
changing mode of build/scripts-2.7/meld from 664 to 775
running build_i18n
intltool-update -p -g meld
unable to execute 'intltool-update': No such file or directory
error: command 'intltool-update' failed with exit status 1
  • intltool 未安装也会报错, 使用 sudo apt-get install gtk-doc-tools intltool itstool 命令安装即可.
meld-3.16.4 $ python setup.py install
  ...
xmllint --noout --noent --path build/help/el --xinclude build/help/el/keyboard-shortcuts.page
unable to execute 'xmllint': No such file or directory
error: command 'xmllint' failed with exit status 1
  • xmllint 包未找到, 使用 sudo apt install libxml2-utils^1 安装即可.

参考文档


Author: Itaken
Reprint policy: All articles in this blog are used except for special statements CC BY 4.0 reprint polocy. If reproduced, please indicate source Itaken !
  TOC目录