binutils Newspaper
JUNE 15, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
bfd

Ignore unsupported sframe versions instead of failing.

The linker now ignores unsupported sframe versions, avoiding failures and the need for `--discard-sframe`.

Old object files assembled by binutils-2.45 with .sframe sections can cause linker failures when linked with newer binutils versions. This change modifies _bfd_elf_parse_sframe to check the sframe version and exclude unsupported versions, preventing the linker from failing and avoiding the need to manually pass --discard-sframe. The patch also adds SEC_EXCLUDE to the sframe section, and ensures memory is freed on failure paths.

In Details

The Binary File Descriptor (BFD) library provides a generic interface to manipulate object files. This commit modifies bfd/elf-sframe.c, specifically the _bfd_elf_parse_sframe function, to handle different sframe versions. Older sframe versions will now be ignored by default. The change involves checking the sframe version, setting SEC_EXCLUDE for unsupported versions, and ensuring memory is freed on failure.

For Context

The Binary File Descriptor (BFD) library is a part of binutils that allows programs to work with different object file formats in a uniform way. Object files contain compiled code and data, and they can have different versions. This commit changes how the linker handles different versions of sframe sections within object files. Now, if the linker finds an older, unsupported version of an sframe section, it will ignore it instead of failing. This prevents linking errors and makes the process smoother for users dealing with older object files.

Filed Under: bfdlinkersframecompatibility