18.10 -- gdk-pixbuf/gdk-pixbuf-xlib.h:没有这样的文件或目录

18.10 -- gdk-pixbuf/gdk-pixbuf-xlib.h:没有这样的文件或目录

造成xscreensaver-5.42这个错误导致失败。

ximage-loader.c:43:12: fatal error: gdk-pixbuf/gdk-pixbuf-xlib.h: No such file or directory
#  include <gdk-pixbuf/gdk-pixbuf-xlib.h>
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

但是gdk-pixbuf已安装并且 apt 显示没有gdk-pixbuf-xlib

$ apt search libgdk-pixbuf
libg3d-plugin-gdkpixbuf/cosmic,now 0.0.8-24 amd64 [installed]
libgdk-pixbuf2.0-0/cosmic,now 2.38.0+dfsg-6 amd64 [installed]
libgdk-pixbuf2.0-bin/cosmic,now 2.38.0+dfsg-6 amd64 [installed]
libgdk-pixbuf2.0-common/cosmic,cosmic,now 2.38.0+dfsg-6 all [installed]
libgdk-pixbuf2.0-dev/cosmic,now 2.38.0+dfsg-6 amd64 [installed]
libgdk-pixbuf2.0-doc/cosmic,cosmic 2.38.0+dfsg-6 all

评论中要求:

$ dpkg -S gdk-pixbuf-xlib.h
libgdk-pixbuf2.0-dev:amd64: /usr/include/gdk-pixbuf-2.0/gdk-pixbuf-xlib/gdk-pixbuf-xlib.h

答案1

./configure解决方案是在运行之前查看上一步中收到的警告make。在我的例子中,我收到了如下警告warning: while GTK is installed, libxml-2.0 could not be found. Are all required libraries installed?

稍微apt search运行一下就会发现我需要sudo apt install libxml2-dev,然后我收到了类似的消息libglade-2.0,它是用 来安装的sudo apt libglade2-dev。重新运行./configure确认缺少的库已成功安装,然后make成功运行。

总之,您可能需要sudo apt install libxml2-dev libglave2-dev,但应该在运行之前查看脚本的警告./configure并解决它警告的问题make

相关内容