我尝试在Fedora28中安装gcc6.4.0,但发生了以下错误。
In file included from ../.././libgcc/unwind-dw2.c:401:0:
./md-unwind-support.h: In function ‘x86_64_fallback_frame_state’:
./md-unwind-support.h:65:47: error: dereferencing pointer to incomplete type ‘struct ucontex_t’
sc = (struct sigcontext *) (void *) &uc_->uc_mcontext;
^~
最后,消息在这里:
make[3]: *** [../.././libgcc/shared-object.mk:14: unwind-dw2.o] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory '/home/rx/program/gcc-6.4.0/x86_64-pc-linux-gnu/libgcc'
make[2]: *** [Makefile:17378: all-stage1-target-libgcc] Error 2
make[2]: Leaving directory '/home/rx/program/gcc-6.4.0'
make[1]: *** [Makefile:23677: stage1-bubble] Error 2
make[1]: Leaving directory '/home/rx/program/gcc-6.4.0'
make: *** [Makefile:914: all] Error 2
我尝试了the previous solution,但还是失败了。
我想念什么吗?谢谢!
答案 0 :(得分:1)
这是由于最新版本的glibc发生了变化,需要更改GCC来源。 GCC 6.4.0在这些更改发生之前就已发布,因此您需要自己修补代码。需要的解决方法是 https://gcc.gnu.org/viewcvs/gcc/trunk/libgcc/config/i386/linux-unwind.h?r1=249731&r2=249730&pathrev=249731
我已经尝试了以前的解决方案,但是仍然失败。
那是不可能的。您确定不仅在第61行还进行了两者更改建议吗?