(Created page with "<!-- Self Contained or System Wide Change Proposal? Use this guide to determine to which category your proposed change belongs to. Self Contained Changes are: * changes to is...") |
|||
(7 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
= Remove Excessive Linking = | |||
= Remove Excessive Linking | |||
== Summary == | == Summary == | ||
< | Pass <code>--as-needed</code> flag the linker through default system-wide LDFLAGS. | ||
== Owner == | == Owner == | ||
* Name: [[User:ignatenkobrain|Igor Gnatenko]], [[User:ngompa|Neal Gompa]] | |||
* Email: ignatenkobrain@fedoraproject.org, ngompa13@gmail.com | |||
* Name: [[User:ignatenkobrain|Igor Gnatenko]] | |||
* Email: ignatenkobrain@fedoraproject.org | |||
* Release notes owner: <!--- To be assigned by docs team [[User:FASAccountName| Release notes owner name]] <email address> --> | * Release notes owner: <!--- To be assigned by docs team [[User:FASAccountName| Release notes owner name]] <email address> --> | ||
== Current status == | == Current status == | ||
* Targeted release: [[Releases/ | * Targeted release: [[Releases/30|Fedora 30]] | ||
* Last updated: | * Last updated: {{REVISIONYEAR}}-{{REVISIONMONTH}}-{{REVISIONDAY2}} | ||
* Tracker bug: [https://bugzilla.redhat.com/show_bug.cgi?id=1625771 #1625771] | |||
* Release Notes tracking: [https://pagure.io/fedora-docs/release-notes/issue/213 #213] | |||
== Detailed Description == | == Detailed Description == | ||
The flag (<code>--as-needed</code>) tells the linker to link in the produced binary only the libraries containing symbols actually used by the binary itself. This binary can be either a final executable or another library. | |||
< | The use of the <code>--as-needed</code> flag allows the linker to avoid linking extra libraries in a binary. This not only improves startup times (as the loader does not have to load all the libraries for every step) but might avoid the full initialization of big frameworks. | ||
== Benefit to Fedora == | == Benefit to Fedora == | ||
No real tests on Fedora has been made, so no real numbers in this section. But theoretically, | |||
* Better startup times (since loader doesn't have to load all the libraries) | |||
* Smaller metadata (since less dependencies are recorded in final binaries) | |||
== Scope == | == Scope == | ||
* Proposal owners: | * Proposal owners: Add <code>-Wl,--as-needed</code> into RPM_LD_FLAGS (in redhat-rpm-config). | ||
< | * Other developers: Nothing should break, but immediate work-around would be to disable this flag (will be provided in redhat-rpm-config) and fix real issue later. | ||
* Release engineering: [https://pagure.io/releng/issue/7604 #7604] (mass rebuild is desired after this change). | |||
* Other developers: | |||
* Release engineering: [https://pagure.io/releng/ | |||
** [[Fedora_Program_Management/ReleaseBlocking/Fedora{{FedoraVersionNumber|next}}|List of deliverables]]: N/A (not a System Wide Change) <!-- REQUIRED FOR SYSTEM WIDE CHANGES --> | ** [[Fedora_Program_Management/ReleaseBlocking/Fedora{{FedoraVersionNumber|next}}|List of deliverables]]: N/A (not a System Wide Change) <!-- REQUIRED FOR SYSTEM WIDE CHANGES --> | ||
* Policies and guidelines: Add information how to turn it off (TODO link to FPC ticket). | * Policies and guidelines: Add information how to turn it off (TODO link to FPC ticket). | ||
* Trademark approval: N/A (not needed for this Change) | * Trademark approval: N/A (not needed for this Change) | ||
== Upgrade/compatibility impact == | == Upgrade/compatibility impact == | ||
None for end-users. Developers which build their own packages might notice and should be guided how to fix / workaround issue. | None for end-users. Developers which build their own packages might notice and should be guided how to fix / workaround issue. | ||
== How To Test == | == How To Test == | ||
Install newest redhat-rpm-config package and build your package. | |||
== User Experience == | == User Experience == | ||
See Benefit to Fedora section. | |||
== Dependencies == | == Dependencies == | ||
None. | |||
== Contingency Plan == | == Contingency Plan == | ||
* Contingency mechanism: Owners will revert change in redhat-rpm-config and make it opt-in rather than opt-out. | |||
* Contingency deadline: Beta freeze. | |||
* Contingency mechanism: | * Blocks release? No | ||
* Blocks product? Everything | |||
* Contingency deadline: | |||
* Blocks release? | |||
* Blocks product? | |||
== Documentation == | == Documentation == | ||
Only Packaging Guidelines needs to be updated. | |||
== Release Notes == | == Release Notes == | ||
Line 140: | Line 61: | ||
--> | --> | ||
[[Category: | [[Category:ChangeAcceptedF30]] | ||
[[Category:SystemWideChange]] | [[Category:SystemWideChange]] |
Latest revision as of 17:40, 31 October 2020
Remove Excessive Linking
Summary
Pass --as-needed
flag the linker through default system-wide LDFLAGS.
Owner
- Name: Igor Gnatenko, Neal Gompa
- Email: ignatenkobrain@fedoraproject.org, ngompa13@gmail.com
- Release notes owner:
Current status
- Targeted release: Fedora 30
- Last updated: 2020-10-31
- Tracker bug: #1625771
- Release Notes tracking: #213
Detailed Description
The flag (--as-needed
) tells the linker to link in the produced binary only the libraries containing symbols actually used by the binary itself. This binary can be either a final executable or another library.
The use of the --as-needed
flag allows the linker to avoid linking extra libraries in a binary. This not only improves startup times (as the loader does not have to load all the libraries for every step) but might avoid the full initialization of big frameworks.
Benefit to Fedora
No real tests on Fedora has been made, so no real numbers in this section. But theoretically,
- Better startup times (since loader doesn't have to load all the libraries)
- Smaller metadata (since less dependencies are recorded in final binaries)
Scope
- Proposal owners: Add
-Wl,--as-needed
into RPM_LD_FLAGS (in redhat-rpm-config). - Other developers: Nothing should break, but immediate work-around would be to disable this flag (will be provided in redhat-rpm-config) and fix real issue later.
- Release engineering: #7604 (mass rebuild is desired after this change).
- List of deliverables: N/A (not a System Wide Change)
- Policies and guidelines: Add information how to turn it off (TODO link to FPC ticket).
- Trademark approval: N/A (not needed for this Change)
Upgrade/compatibility impact
None for end-users. Developers which build their own packages might notice and should be guided how to fix / workaround issue.
How To Test
Install newest redhat-rpm-config package and build your package.
User Experience
See Benefit to Fedora section.
Dependencies
None.
Contingency Plan
- Contingency mechanism: Owners will revert change in redhat-rpm-config and make it opt-in rather than opt-out.
- Contingency deadline: Beta freeze.
- Blocks release? No
- Blocks product? Everything
Documentation
Only Packaging Guidelines needs to be updated.