Debian 错误:生成irssi需要GLib

Debian 错误:生成irssi需要GLib,debian,glib,irssi,Debian,Glib,Irssi,我是Linux(Debian)世界的新手。Irssi需要GLib,所以我安装了2.6.6版本。尝试/configureIrssi时,它会给出: ... checking pkg-config is at least version 0.7... yes checking for GLIB - version >= 2.6.0... *** 'pkg-config --modversion glib-2.0' returned 2.6.6, but GLIB (2.32.4) *** was

我是Linux(Debian)世界的新手。Irssi需要GLib,所以我安装了2.6.6版本。尝试
/configure
Irssi时,它会给出:

...
checking pkg-config is at least version 0.7... yes
checking for GLIB - version >= 2.6.0...
*** 'pkg-config --modversion glib-2.0' returned 2.6.6, but GLIB (2.32.4)
*** was found! If pkg-config was correct, then it is best
*** to remove the old version of GLib. You may also be able to fix the error
*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing
*** /etc/ld.so.conf. Make sure you have run ldconfig if that is
*** required on your system.
*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH
*** to point to the correct configuration files
no
*** trying without -lgmodule
checking for pkg-config... (cached) /usr/local/bin/pkg-config
checking pkg-config is at least version 0.7... yes
checking for GLIB - version >= 2.6.0...
*** 'pkg-config --modversion glib-2.0' returned 2.6.6, but GLIB (2.32.4)
*** was found! If pkg-config was correct, then it is best
*** to remove the old version of GLib. You may also be able to fix the error
*** by modifying your LD_LIBRARY_PATH enviroment variable, or by editing
*** /etc/ld.so.conf. Make sure you have run ldconfig if that is
*** required on your system.
*** If pkg-config was wrong, set the environment variable PKG_CONFIG_PATH
*** to point to the correct configuration files
no

*** If you don't have GLIB, you can get it from ftp://ftp.gtk.org/pub/glib/
*** We recommend you get the latest stable GLIB 2 version.
*** Compile and install it, and make sure pkg-config finds it,
*** by adding the path where the .pc file is located to PKG_CONFIG_PATH

configure: error: GLIB is required to build irssi.

有人能告诉我怎么回事吗

库的包至少分为两个包——一个用于共享库本身,这是运行使用库的软件所需的,另一个用于编译依赖于该库的软件所需的额外内容。在Debian中,这些包的名称是
libglib-2.0
libglib-2.0-dev

您已经安装了
libglib-2.0
的2.32.2版,但是为了编译像irssi这样的软件,您需要
libglib-2.0-dev
。正确的做法是安装该软件包:

sudo apt-get install libglib-2.0-dev
不幸的是,像您这样安装一个古老版本的glib(2.6.6于2005-08-01发布)可能会严重破坏您的系统,因为其他软件可能依赖于更新版本的glib。如果您没有将任何参数传递给
/configure
,则它可能已安装到
/usr/local
,这将是一件好事,因为它可能没有覆盖
/usr
中所需的任何内容(打包版本就是在这里安装的)。因此,您可以进入编译2.6.6的目录并运行:

sudo make uninstall
您可能还需要从Debian重新安装软件包:

sudo apt-get install --reinstall libglib-2.0
我不知道您想用irssi做什么,但是您可能不想从tarball安装它,而只想使用Debian软件包:

sudo apt-get install irssi

除非您真的在修改代码,否则您几乎永远都不想从tarballs(或者git)安装。我建议您查找您安装的任何图形软件包管理器——该软件包的内容取决于Debian的版本以及您选择的桌面环境,但可能的选择是GNOME软件中心或Synaptic。

您是否从源tarball安装了glib 2.6.6版???非常棒且详细的答案!谢谢你抽出时间。我设法安装了它。