Summary: | [objcopy] add support for setting SHF_EXCLUDE flag for sections | ||
---|---|---|---|
Product: | binutils | Reporter: | dsn1234 |
Component: | binutils | Assignee: | Not yet assigned to anyone <unassigned> |
Status: | RESOLVED FIXED | ||
Severity: | enhancement | CC: | i, nickc |
Priority: | P2 | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Host: | Target: | ||
Build: | Last reconfirmed: | 2020-01-11 00:00:00 |
Description
dsn1234
2020-01-11 02:16:13 UTC
Currently, --set-section-flags preserves SHF_EXCLUDE. We can add 1. "+exclude" to add SHF_EXCLUDE. 2. "-exclude" to remove SHF_EXCLUDE. Looks good to me. We don't have precedent for +flag or -flag. Isn't it an overkill to invent the +- prefix and use +exclude and -exclude? Other than .debug_*.dwo and an LLVM extension .linker-options, I can't think of any use cases of SHF_EXCLUDE. Nobody will --set-section-flags on .debug_*.dwo . I'd prefer treating 'exclude' like other flags such as 'alloc','readonly','data'... I can send a patch for this. https://sourceware.org/ml/binutils/2020-01/msg00186.html in the spirit of a previous patch by HJ. Lu that makes SHF_EXCLUDE generic rather than processor-specific. The patch has now been applied. (Commit: 3a5d12fbb4f) |