1. 参考博客编译安装gcc 6.3
对make出错解决:
错误一
error: dereferencing pointer to incomplete type 'struct ucontext'
解决方法:
In order to have make
to work you have to modify the file make_folder/libgcc/config/i386/linux_unwind.h
where make_folder
is the folder where you type the make
command.
In linux_unwind.h
you have to change struct ucontext *uc_ = context->cfa;
on line 61 to struct ucontext_t *uc_ = context->cfa;
错误二:
aggregate ‘sigaltstack handler_stack’ has incomplete type and cannot be defined
struct sigaltstack handler_stack;
根据Fix sanitizer build against latest glibc 修改对应文件后 重新编译