« RSA/DSA authentication on SSH | 首 页 | Internet and Intranet »

2005 年 10 月 13 日

GTK + GNOME + Xft + GIMP 的安装配置

| 分类: 服务器日志 Server Log |

这次配置花了我两天时间,不过触及到了很多东西,还是挺有收获的。
主要目的是想在Miracle Linux下进行截屏,所以需要安装 GIMP ,由此引出了一系列的问题。

Miracle Linux 2.1 版本其实是一个很老的近似于 RedHat 6.x or 7.x 的 Linux 系统,但是结合了对 Oracle 的支持,所以由此得名。安装 GIMP 需要更高版本的 GTK, 而这需要一些 dependent 的 packages。
这次配置主要卡在了 Xft 的安装上面。原因主要还是对于 ld-config 的运用以及 /usr/local/lib 的设置没有熟练而造成的。特别是以下的问题。另外,对于像Miracle Linux 这样老掉牙的版本,我们在选择package 的时候,不能一味的追求高版本,有时候适当的选择相应的低版本会比较顺手。


  • Quote: http://mail.gnome.org/archives/gtk-list/2005-June/msg00112.html
  • RE: GTK Errors: Xft Pango backend is required for x11 target

    --------------------------------------------------------------------------------
    From: Xu Qiang
    To: Maximus , gtk-list gnome org
    Cc:
    Subject: RE: GTK Errors: Xft Pango backend is required for x11 target
    Date: Wed, 15 Jun 2005 09:57:03 +0800
    --------------------------------------------------------------------------------

    gtk-list-bounces gnome org wrote:
    > My GTK is getting Xft Pango backend is required for x11 target error.

    To let Pango compiles this backend, the correct compile/install order is Xft -> Pango -> Gtk.
    Note that Pango can't be compiled before Xft, otherwise the Xft backend will not be there.

    Regards,
    Xu Qiang

    GTK configure error

    checking Pango flags... -DXTHREADS -I/usr/local/include/pango-1.0 -I/usr/local/include -I/usr/include/freetype2 -I/usr/X11R6/i
    nclude -I/usr/local/include/freetype2 -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -L/usr/local/lib -lpan
    goxft-1.0 -lpangoft2-1.0 -lpangox-1.0 -lpango-1.0 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0
    configure: error:
    *** Can't link to Pango. Pango is required to build
    *** GTK+. For more information see http://www.pango.org

    检查了一下,/usr/local/include/pango-1.0 的确存在。所以,可能需要重新注意这个 include 目录而编译一下 pango,或者使用最新版本 1.10.1

  • 我安装或者更新的packages:

  • atk-1.10.1
    fontconfig-2.2.3
    gimp-2.2.8
    gtk+-2.5.6
    expat-1.95.8
    freetype-2.1.10
    glib-2.8.3
    pango-1.10.1
    pkg-config-0.19
    libart-2.3.17
    libXrender-0.8.4
    libXft-2.1.4

  • 最终解决问题的方法:

  • 配置以上的包时,使用以下命令配置
    ./configure --libdir=/usr/local/lib
    修改Makefile
    FREETYPE_CONFIG=/usr/local/bin/freetype-config

  • 有用的Links

  • http://gimp.org/source/#source 关于 GIMP 的 source 和 dependence
    http://fontconfig.org/wiki/
    http://xlibs.freedesktop.org/release/ (Download for XFT)
    http://www.gnome.org/
    http://www.gtk.org/
    http://www.fontconfig.org/
    http://www.freedesktop.org/
    http://www.xfree86.org/current/Xft.3.html 关于 Xft 的介绍。
    http://cvs.fontconfig.org/wiki/Software_2fXft

  • Download Xft via CVS

  • http://www.xfree86.org/cvs/
    CVS_RSH=ssh
    CVSROOT=anoncvs@anoncvs.xfree86.org:/cvs
    export CVS_RSH CVSROOT

    #cvs -d :pserver:anoncvs@anoncvs.xfree86.org:/cvs login
    Password : anoncvs

    # cvs checkout xc
    cvs checkout: Updating xc
    U xc/BUILD.txt
    U xc/Imakefile
    U xc/Install.txt
    U xc/LICENSE.txt

  • pkg-config 用途:
  • # pkg-config --list-all
    gmodule-export-2.0 GModule - Dynamic module loader for GLib
    gmodule-2.0 GModule - Dynamic module loader for GLib
    freetype2 FreeType 2 - A free, high-quality, and portable font engine.
    fontconfig Fontconfig - Font configuration and customization library
    glib-2.0 GLib - C Utility Library
    gobject-2.0 GObject - GLib Type, Object, Parameter and Signal Library
    gthread-2.0 GThread - Thread support for GLib
    pangoft2 Pango FT2 - Freetype 2.0 font support for Pango
    gmodule-no-export-2.0 GModule - Dynamic module loader for GLib
    pangox Pango X - X Window System font support for Pango
    pango Pango - Internationalized text handling
    atk Atk - Accessibility Toolkit
    但是可惜没有找到 xft Xft - X FreeType library

    安装后的 pkg-config --list

    # pkg-config --list-all
    gmodule-export-2.0 GModule - Dynamic module loader for GLib
    gmodule-2.0 GModule - Dynamic module loader for GLib
    freetype2 FreeType 2 - A free, high-quality, and portable font engine.
    fontconfig Fontconfig - Font configuration and customization library
    glib-2.0 GLib - C Utility Library
    gobject-2.0 GObject - GLib Type, Object, Parameter and Signal Library
    gthread-2.0 GThread - Thread support for GLib
    pangoft2 Pango FT2 - Freetype 2.0 font support for Pango
    gmodule-no-export-2.0 GModule - Dynamic module loader for GLib
    pangox Pango X - X Window System font support for Pango
    randr RandR - RandR extension headers
    pangoxft Pango Xft - Xft font support for Pango
    render Render - Render extension headers
    xft Xft - X FreeType library
    pango Pango - Internationalized text handling
    xrender Xrender - X Render Library
    atk Atk - Accessibility Toolkit

  • Dependency:

  • gtk+-2.4.14
    Package requirements
    pkg-config >= 0.9.0
    glib-2.0 >= 2.4.5
    atk >= 1.0.1
    pango >= 1.4.0
    gtk+-2.6.10
    Package requirements
    pkg-config >= 0.9.0
    glib-2.0 >= 2.6.0
    atk >= 1.0.1
    pango >= 1.8.0
    FreeType >= 2.0.1

    ftp://ftp.gtk.org/pub/gtk/ 下各个版本中都有相关package dependency 的整理分类。

    (END)

    发表评论

    (如果您还为在此成功留言,也许是因为需要管理员逐一审核留言内容后放可看到您的评论。请稍后并感谢您的耐心等待。)

    阅览更多文章请访问 首页过去的存档