[PATCH 2/2] ld-pe: Add support for -undefined, -include directives
Project / Subsystem
binutils / ld-pe
Date
2026-09-30
Proposer
Luca Bacci <luca.bacci@outlook.com>
Source type
public_inbox
Consensus
Proposed
Sentiment
—/10
Technical tradeoffs
- • Increases complexity of the PE linker's parsing logic.
All attributes
- project
- binutils
- subsystem
- ld-pe
- patch_id
- —
- discussion_id
- AS4PR02MB79022E31710C9D4F0BC23868838B2@AS4PR02MB7902.eurprd02.prod.outlook.com
- source_type
- public_inbox
- title
- [PATCH 2/2] ld-pe: Add support for -undefined, -include directives
- headline
- ld-pe: Add support for -undefined, -include directives
- tldr
- Extends PE linker support for undefined symbol directives and DEF module-definition files.
- proposer
- Luca Bacci <luca.bacci@outlook.com>
- consensus
- Proposed
- outcome
- proposed
- sentiment_score
- —
- technical_tradeoffs
-
- • Increases complexity of the PE linker's parsing logic.
- series_id
- binutils:ld-pe: add support for -undefined, -include directives
- series_role
- reply
- series_parts
- []
- tags
-
- • linker
- • pe
- • coff
- • symbols
- bugzilla_url
- —
- date
- 2026-09-30T00:00:00.000Z
[PATCH 2/2] ld-pe: Add support for -undefined, -include directives
This patch enhances the PE (Portable Executable) linker’s capabilities by adding support for specifying undefined symbol names. This can now be done through linker directives within COFF object files’ .drectve section or as statements in DEF module-definition files. This functionality is crucial for retaining symbols with the used attribute, preventing them from being discarded by the compiler or linker, similar to ELF’s retain attribute.