使用 make 安装软件时出错

使用 make 安装软件时出错

我对 Linux 和从源代码编译软件还很陌生。我不确定输出告诉我什么以及在哪里可以找到我的问题的解决方案。

我正在尝试安装莫斯科 ML:http://www.itu.dk/~sestoft/mosml.html

按照文档中的说明,我导航到解压目录并输入

make world

完整输出在这里:http://pastebin.com/UqNfsCnf

输出的最后一部分是:

gcc -O -DNDEBUG -o mosmlyac closure.o error.o lalr.o lr0.o main.o mkpar.o output.o reader.o skeleton.o symtab.o verbose.o warshall.o
strip mosmlyac
make[1]: Leaving directory `/home/user/Downloads/ml/mosml/src/mosmlyac'
cd mosmllib; make all
make[1]: Entering directory `/home/user/Downloads/ml/mosml/src/mosmllib'
/lib/cpp -P -traditional -Dunix -Umsdos Array.mlp > Array.sml
../camlrunm ../mosmlcmp -stdlib ../mosmllib -P none -imptypes Vector.sig
../camlrunm ../mosmlcmp -stdlib ../mosmllib -P none -imptypes Array.sig
../camlrunm ../mosmlcmp -stdlib ../mosmllib -P none -imptypes List.sig
../camlrunm ../mosmlcmp -stdlib ../mosmllib -P none -imptypes Array.sml
*** glibc detected *** ../camlrunm: free(): invalid pointer: 0x00000000012e6000 ***
======= Backtrace: =========
/lib64/libc.so.6[0x33af07da76]
../camlrunm(alloc_shr+0x3d6)[0x40a336]
../camlrunm[0x409b3c]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409bb5]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm[0x409b8f]
../camlrunm(minor_collection+0x80)[0x409cc0]
../camlrunm(interprete+0x21bd)[0x407d7d]
../camlrunm(main+0x2eb)[0x40599b]
/lib64/libc.so.6(__libc_start_main+0xed)[0x33af02169d]
../camlrunm[0x405b01]

接下来是内存映射和

make[1]: *** [Array.uo] Aborted (core dumped)
make[1]: Leaving directory `/home/matthew/Downloads/ml/mosml/src/mosmllib'
make: *** [world] Error 2

有什么想法可以让我做到这一点吗?谢谢!

答案1

gc_ctrl.c.1我刚刚遇到了同样的问题。目录中有一个名为的文件runtime。备份gc_ctrl.c该目录中的现有文件,然后将此文件复制到该文件上。完成此操作后,我的构建成功了。MosML 网站上有关于此问题的说明,但它们链接到了错误的替换文件。

# From src/ directory

# Make backup and move new file into place
cp runtime/gc_ctrl.c runtime/gc_ctrl.c.bak
cp runtime/gc_ctrl.c.1 runtime/gc_ctrl.c

# Cleanup previous compiled files and rebuild.
make clean 
make world

# If previous was successful and you want to install it
sudo make install 

相关内容