![警告:在库中找不到宏“AM_GLIB_GNU_GETTEXT”](https://linux22.com/image/136941/%E8%AD%A6%E5%91%8A%EF%BC%9A%E5%9C%A8%E5%BA%93%E4%B8%AD%E6%89%BE%E4%B8%8D%E5%88%B0%E5%AE%8F%E2%80%9CAM_GLIB_GNU_GETTEXT%E2%80%9D.png)
我正在尝试安装声音转换器通过 git。这就是我在终端中所做的:
$ sudo apt-get update && sudo apt-get upgrade && sudo apt-get install git
$ git clone https://github.com/kassoulet/soundconverter.git
$ cd soundconverter
$ ./autogen.sh
这是运行的输出/home/USERNAME/soundconverter/autogen.sh
*** WARNING: I am going to run 'configure' with no arguments.
*** If you wish to pass any to it, please specify them on the
*** './autogen.sh' command line.
configure.ac:22: warning: macro 'AM_GLIB_GNU_GETTEXT' not found in library
aclocal: installing 'm4/intltool.m4' from '/usr/share/aclocal/intltool.m4'
aclocal: installing 'm4/nls.m4' from '/usr/share/aclocal/nls.m4'
./autogen.sh: 27: ./autogen.sh: glib-gettextize: not found
答案1
研究丢失的包裹
正如您所注意到的,这是您的问题:
configure.ac:22: warning: macro 'AM_GLIB_GNU_GETTEXT' not found in library
aclocal: installing 'm4/intltool.m4' from '/usr/share/aclocal/intltool.m4'
aclocal: installing 'm4/nls.m4' from '/usr/share/aclocal/nls.m4'
./autogen.sh: 27: ./autogen.sh: glib-gettextize: not found
此消息告诉您您缺少一个库。该库的内部逻辑名称是:AM_GLIB_GNU_GETTEXT
。
搜索它会引导您找到许多像这样的线程:
易于
在我们开始查找之前,让我们确保我们的apt-file
缓存已更新:
$ sudo apt-file update
现在让我们看看 APT 是什么:
$ apt-file search glib-gettextize
libglib2.0-dev: /usr/bin/glib-gettextize
libglib2.0-dev: /usr/share/man/man1/glib-gettextize.1.gz
libglib2.0-doc: /usr/share/doc/libglib2.0-doc/glib/glib-gettextize.html
很好,所以包的名称是libglib2.0-dev
。这与我们之前的谷歌搜索返回的结果一致。
我们可以查看这个包,看看它是否包含.m4
我们似乎丢失的文件:
$ apt-file list libglib2.0-dev | grep '.m4$'
libglib2.0-dev: /usr/share/aclocal/glib-2.0.m4
libglib2.0-dev: /usr/share/aclocal/glib-gettext.m4
libglib2.0-dev: /usr/share/aclocal/gsettings.m4
很好,所以有一个正在寻找的.m4
宏文件。configure
那么让我们安装它:
$ sudo apt-get install -y libglib2.0-dev
笔记:安装完成后,您可以使用以下命令查询已安装的软件包dpkg
:
$ dpkg-query -L libglib2.0-dev | grep m4
/usr/share/aclocal/glib-2.0.m4
/usr/share/aclocal/gsettings.m4
/usr/share/aclocal/glib-gettext.m4