WIP: CMake: Better handle -fstack-protector flag support#2781
WIP: CMake: Better handle -fstack-protector flag support#2781
Conversation
|
|
||
| check_cxx_compiler_flag(-fstack-protector-strong stack_protector_support) | ||
| if (stack_protector_support) | ||
| add_compile_options(-fstack-protector-strong) |
There was a problem hiding this comment.
This new way doesn't pass the -fstack-protector option anymore as it was the case before. According to gcc it seems that -strong implies the basic one too. Is that correct?
There was a problem hiding this comment.
More / less yes. The -strong one is stronger. The strongest is -all. I think this only selects what function to protect...
We are skipping an exotic case where a compiler supports -fstack-protector but not -fstack-protector-strong. I can leave with this. This does not affect solidity releases.
There was a problem hiding this comment.
Yes. And we will. I've found that GCC 4.8 has only the basic flag.
|
So does this PR need to be fixed or can it be merged? |
|
To be fixed. |
|
Fixed. Works for GCC 4.8: https://travis-ci.org/ethereum/solidity/jobs/267922031#L1261-L1264. |
No description provided.