【发布时间】:2017-03-18 20:59:30
【问题描述】:
我有 Mac OS X Sierra 10.12.3,我知道 Valgrind 可能与我的系统不兼容。我已经成功运行了 automake 和 svn,但是当我尝试运行 make 时,它显示:
priv/ir_opt.c:5930:14: error: explicitly assigning value of variable of type 'Int' (aka 'int') to itself [-Werror,-Wself-assign]
for (m = m; m < A_NENV; m++) {
有人知道这是因为与 Mac OS 兼容还是其他原因?谢谢。
【问题讨论】:
-
这不是
make,而是C编译器。删除-Werror标志的任何位置(可能在Makefile中)。 -
@Jens 感谢您的回答,尝试从 Valgrind Makefile 中删除所有
-Wall和-Werror,尝试从我的 ~/.profile 中删除所有内容,但是我注意到它可能使用 Xcode 的制作,因为它打印出/Applications/Xcode.app/Contents/Developer/usr/bin/make。 -
如果没有帮助,我建议修改源;因为
m = m什么都不做,所以可以安全地从 ir_opt.c 中删除它:for (; m < A_NEW; m++)。 -
感谢@Jens,辛苦了!