当我在R中安装.packages(“RGtk2”)时,出现此问题:
fatal error: 'gdk/gdkx.h' file not found
#include <gdk/gdkx.h>
^
1 error generated.
make: *** [Rgtk.o] Error 1
ERROR: compilation failed for package ‘RGtk2’
* removing ‘/usr/local/lib/R/3.4/site-library/RGtk2’
* restoring previous ‘/usr/local/lib/R/3.4/site-library/RGtk2’
我在macOS Sierra 10.12.3中使用brew安装GTK
最佳答案
根据INSTALL documentation,您必须首先安装Gtk库:
我怀疑HomeBrew的Gtk可能未正确安装在您的系统上。
进一步的研究表明similar problems, as well as suggested troubleshooting可以使Gtk和RGtk2
一起工作。
关于R在install.packages中("RGtk2"): fatal error: 'gdk/gdkx.h' file not found,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/45364313/