有谁知道如何在Ubuntu上编译Megahal?

时间:2015-07-10 21:38:42

标签: python ubuntu

我一直试图将megahal编译几个小时,而我似乎无处可去。有人有这个成功吗? http://megahal.alioth.debian.org/

我不断收到错误消息:

inlined from ‘load_personality.constprop’ at megahal.c:3283:8,
inlined from ‘change_personality.constprop’ at megahal.c:3332:5:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:293:2: warning: call to      ‘__fread_chk_warn’ declared with attribute warning: fread called with bigger size * nmemb than length of destination buffer
return __fread_chk_warn (__ptr, __bos0 (__ptr), __size, __n, __stream);
 ^
cc1: some warnings being treated as errors
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
Makefile:44: recipe for target 'pythonmodule' failed
make: *** [pythonmodule] Error 1

我已经通过sudo apt-get安装了python,并且我已经遍历了每个讨论“'x86_64-linux-gnu-gcc'的线程,但我找不到解决方案

2 个答案:

答案 0 :(得分:0)

您只是因为没有安装python开发头而得到这些错误。您可以使用以下命令

安装它

sudo apt-get install python-dev(for python 2.x)

sudo apt-get install python3-dev(for python 3)

答案 1 :(得分:-1)

你需要python开发者模块" python-dev"。这会帮助你

error: command 'gcc' failed with exit status 1 while installing eventlet

在ubuntu上升级到生动的15.04后,我再也无法编译模块,所以我尝试了其他的东西。因为在主文件夹中有一个名为Megahal的目录,其中有一个Makefile,我试着从那里编译。首先,您需要转到该目录。

cd /home/user/Downloads/megahal-9.1.1/Megahal/

你需要去解压缩档案的地方,在那里你可以阅读README文件并开始编译。

perl Makefile.PL

我将我能找到的丢失文件复制到该文件夹​​中,然后从那里

make
make test

但这对我来说并不适用

make install

我不得不做

sudo make install

就是这样。不幸的是,我觉得perl有问题。 我一直从模块中得到这个错误" PL_thr_key"把它装到eggdrop后。除模块外,eggdrop正常工作。没有模块,没有人工智能,没有乐趣:(