[lsb-discuss] LSBCC and -fstack-protector
Mats Wichmann
mats at wichmann.us
Tue Mar 8 18:24:34 UTC 2016
On 03/08/2016 11:12 AM, Dallman, John wrote:
> I'm using an LSB 4.0 SDK, compiling with lsbcc, and trying to turn on -fstack-protector. This doesn't work: after a certain amount of thrashing around, I turned on LSBCC_VERBOSE, which revealed that lsbcc passes -fno-stack-protector to gcc at the end of the command line, overriding any earlier -fstack-protector. Is there a way to stop this? Or is lsbcc preventing me from using an inadequate implementation of -fstack-protector?
It's been too long and I can't recall the details, but I believe we need
to always disable the stack-protector option, because it changes the ABI
when enabled. The code in lsbcc includes this comment:
* Starting with gcc 4.1, gcc will emit new symbols for stack
* protection. This is a good thing, but for LSB 3.x, those new
* symbols need to be suppressed.
the change to do this is very old now.
revno: 1373.1.2
committer: Jeff Licquia <jeff at licquia.org>
branch nick: 3.2-bugfix-build_env
timestamp: Thu 2007-11-01 20:30:36 -0400
message:
Suppress gcc 4.1+ stack protection when necessary.
I'm not sure Jeff remembers either, but hopefully his memory is better
than mine!!!
More information about the lsb-discuss
mailing list