error: unrecognized command line option '-fstack-protector-strong'解决办法

今天编译kernel 的时候,报error: unrecognized command line option '-fstack-protector-strong'的错误!

这是这么fstack-protector-strong,搜了一圈也不大明白什么意思,不过最后是解决了。

解决办法:

在kernel目录下:

make menuconfig   

在 General setup——

Optimize very unlikely/likely branches   把该项在编译该项中去掉。如下图:

或者把子选项Stack Protector buffer overflow detection 设置为None。

  

上面解决我的问题,估计其他人的问题未必就能解决。

下边记录一下网上找到的一些有用的解决办法:

1、Turns out that the ‘-fstack-protector-strong’ option was not added to the GCC compiler until version 4.9.  Upgraded my GCC to the latest available fixed the issue.

2、http://www.gossamer-threads.com/lists/gentoo/user/292834


关于-fstack-protector-strong详细说明的英文网站:

https://securityblog.redhat.com/tag/stack-protector/

http://outflux.net/blog/archives/2014/01/27/fstack-protector-strong/

  • 2
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 2
    评论
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值