所以我想安装这用于 gimp 的 DDS 插件。我以前做过,但在全新安装的 Ubuntu 上却失败了。
我提取了存档,然后输入 make。结果如下:
joel@Zetes:~/gimp-dds-3.0.1$ make
Package gtk+-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gtk+-2.0' found
Package gimp-2.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gimp-2.0.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gimp-2.0' found
[CC] dds.c
dds.c:27:21: fatal error: gtk/gtk.h: No such file or directory
#include <gtk/gtk.h>
^
compilation terminated.
make: *** [dds.o] Error 1
joel@Zetes:~/gimp-dds-3.0.1$
所以我缺少软件包 gtk+-2.0。我在软件中心或 Synaptic 中都找不到它。
答案1
答案就在错误消息中
gtk+-2.0
也许你应该将包含“gtk+-2.0.pc”的目录添加到 PKG_CONFIG_PATH 环境变量中,未找到包“gtk+-2.0”
所以
sudo apt-get install libgtk2.0-dev
为什么?
% apt-file search gtk+-2.0.pc libgtk2.0-dev: /usr/lib/x86_64-linux-gnu/pkgconfig/gtk+-2.0.pc % apt-cache search libgtk2 | grep dev libgtk2.0-cil-dev - CLI binding for the GTK+ toolkit 2.12 libgtk2.0-dev - development files for the GTK+ library % apt-file search --regex gtk/gtk.h$ libgtk-3-dev: /usr/include/gtk-3.0/gtk/gtk.h libgtk2.0-dev: /usr/include/gtk-2.0/gtk/gtk.h
gimp-2.0
在 pkg-config 搜索路径中未找到软件包 gimp-2.0。也许您应该添加包含“gimp-2.0.pc”的目录
所以
sudo apt-get install libgimp2.0-dev
为什么?
% apt-file search gimp-2.0.pc libgimp2.0-dev: /usr/lib/pkgconfig/gimp-2.0.pc % apt-cache search libgimp | grep dev libgimp2.0-dev - Headers and other files for compiling plugins for GIMP