Why is libssp support disabled

Asked by Ben Gamari

Currently I'm trying to debug a stack smashing bug and -fstack-protector would be extremely useful. Is there a technical reason why gcc-arm-embedded is compiled with --disable-libssp? This functionality would be extremely useful on small machines where stack smashing isn't uncommon and tools for debugging are nearly non-existent.

Question information

Language:
English Edit question
Status:
Answered
For:
GNU Arm Embedded Toolchain Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Terry Guo (terry.guo) said :
#1

Hi Ben,

The reason is stated in our How-to-build-toolchain.pdf. I quote them here:

Step 4: Build new native gcc
If you don’t want to build the package running on the platform which is different from your
build machine, please skip this step.
Reconfigure and compile native gcc/g++ on Ubuntu-8.10 system. Gcc distributed along with
ubuntu-8.10 system supports ssp utility by default, which uses symbols of version
GLIBC_2.8/GLIBC_2.7, etc. in glibc, resulting in programs compiled by this gcc/g++ may not be
able to run on system with lower version glibc, like redhat5/redhat4. To provide greater
application coverage of our toolchain, we have to reconfigure and compile gcc with libssp
disabled.

Revision history for this message
chengbin (can-finner) said :
#2

Because GCC supporting libssp refers to symbol versions later than GLIBC_2.4, which does not exist on older systems like rhe4. So we disabled libssp to make sure the tool can be run on such old systems.
It's OK for you to rebuild the tool with libssp enabled by modifying build scripts.

Revision history for this message
kert (kaidokert) said :
#3

Uh, RHE4 is almost ten years old now ? stack-protector is really quite useful, it would be awesome to have them in mainline builds. I just ran into a similar problem where ssp would be indispensable, and rebuilding from scratch will be a major undertaking especially as all my dev tools are on Mac right now.

Can you help with this problem?

Provide an answer of your own, or ask Ben Gamari for more information if necessary.

To post a message you must log in.