From Fedora Project Wiki
(Add trackers)
 
(13 intermediate revisions by 2 users not shown)
Line 25: Line 25:
Note that motivation for the change should be in the Benefit to Fedora section below, and this part should answer the question "What?" rather than "Why?". -->
Note that motivation for the change should be in the Benefit to Fedora section below, and this part should answer the question "What?" rather than "Why?". -->


This change will update all spec files in Fedora that use make and replace the make invocations with either the %make_build or %make_install macros.
This change will increase the use of the %make_build and %make_install macros in spec files.


== Owner ==
== Owner ==
Line 44: Line 44:


== Current status ==
== Current status ==
[[Category:ChangeAnnounced]]
[[Category:ChangeAcceptedF33]]
<!-- When your change proposal page is completed and ready for review and announcement -->
<!-- When your change proposal page is completed and ready for review and announcement -->
<!-- remove Category:ChangePageIncomplete and change it to Category:ChangeReadyForWrangler -->
<!-- remove Category:ChangePageIncomplete and change it to Category:ChangeReadyForWrangler -->
Line 63: Line 63:
CLOSED as NEXTRELEASE -> change is completed and verified and will be delivered in next release under development
CLOSED as NEXTRELEASE -> change is completed and verified and will be delivered in next release under development
-->
-->
* FESCo issue: <will be assigned by the Wrangler>
* FESCo issue: [https://pagure.io/fesco/issue/2420 #2420]
* Tracker bug: <will be assigned by the Wrangler>
* Tracker bug: [https://bugzilla.redhat.com/show_bug.cgi?id=1858398 #1858398]
* Release notes tracker: <will be assigned by the Wrangler>
* Release notes tracker: [https://pagure.io/fedora-docs/release-notes/issue/536 #536]


== Detailed Description ==
== Detailed Description ==
Line 71: Line 71:
<!-- Expand on the summary, if appropriate.  A couple sentences suffices to explain the goal, but the more details you can provide the better. -->
<!-- Expand on the summary, if appropriate.  A couple sentences suffices to explain the goal, but the more details you can provide the better. -->


The goal of this change is to standardize the usage of make in Fedora.  All make invocations in spec files that don't use the install target will be modified to use the %make_build macro, and all make invocations that use the install target will be updated to use the %make_install macro.  Any additional arguments to make that are not included in either the %make_build and %make_install will be preserved.
The goal of this change is to standardize the usage of make in Fedora.  All make invocations in spec files that use the %{_smp_mflags} macro will be modified to use the %make_build macro, and all make invocations that use the install target will be updated to use the %make_install macro.  Any additional arguments to make that are not included in either the %make_build and %make_install will be preserved.
 
The %make_build macro enables parallel make builds using the -j option.  In case a package does not build correctly with parallel make, then the -j1 flag will be added after the %make_build macro:
 
  %make_build -j1


All changes will be submitted to dist-git repositories via pull requests.  Pull requests will be merged after 1 week if there are no objections or earlier if approved by the package maintainers.
All changes will be submitted to dist-git repositories via pull requests.  Pull requests will be merged after 1 week if there are no objections or earlier if approved by the package maintainers.
Line 91: Line 87:
Feedback from thread on devel list:
Feedback from thread on devel list:


* I've updated the proposal due to a suggestion to disable parallel builds for only the specific make command that fails to build, rather than using
* There are concerns that replacing all make invocations with %make_build, even in cases where there may not be any benefit e.g. for `make html` may cause build failures or make the spec file less readable.  An alternative to replacing all make invocations would be only to replace make in `make $BUILD_TARGET`, `make check`, and `make install` with %make_{build,install}.
 
  %global _smp_mflags -j1


Which would disable parallel builds globally for the entire spec file.  The rationale is that if e.g. `make check` fails to build with parallel make, we don't need to disable parallel make in the %build section.
As a result of this feedback, the change proposal has been updated to only update `make %{_smp_mflags} ...` and `make install` with the macros.
 
* There are concerns that replacing all make invocations with %make_build, even in cases where there may not be any benefit e.g. for `make html` may cause build failures or make the spec file less readable. An alternative to replacing all make invocations would be only to replace make in `make $BUILD_TARGET`, `make check`, and `make install` with %make_{build,install}.


== Benefit to Fedora ==
== Benefit to Fedora ==
Line 128: Line 120:
     https://fedoraproject.org/wiki/Changes/perl5.26 (major upgrade to a popular software stack, visible to users of that stack)
     https://fedoraproject.org/wiki/Changes/perl5.26 (major upgrade to a popular software stack, visible to users of that stack)
-->
-->
* Reduced build times: Using the %make_build macros enables parallel make builds which will reduce build times for Fedora packages.
* Standardized spec files.


* This will make it easier to enforce consistent build flag usage across all of Fedora.
* This will make it easier to enforce consistent build flag usage across all of Fedora.
Line 143: Line 135:
The issue is required to be filed prior to feature submission, to ensure that someone is on board to do any process development work and testing, and that all changes make it into the pipeline; a bullet point in a change is not sufficient communication -->
The issue is required to be filed prior to feature submission, to ensure that someone is on board to do any process development work and testing, and that all changes make it into the pipeline; a bullet point in a change is not sufficient communication -->


* Policies and guidelines: Package guidelines already specify that packages should use these macros when possible.  Documentation will be updated to clarify that %make_build should be used for all make invocations (besides make install), and also with instructions for packages that fail to build with parallel make. <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
* Policies and guidelines: Package guidelines already specify that packages should use these macros when possible.  <!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
<!-- Do the packaging guidelines or other documents need to be updated for this feature?  If so, does it need to happen before or after the implementation is done?  If a FPC ticket exists, add a link here. -->
<!-- Do the packaging guidelines or other documents need to be updated for this feature?  If so, does it need to happen before or after the implementation is done?  If a FPC ticket exists, add a link here. -->


Line 206: Line 198:


<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
<!-- REQUIRED FOR SYSTEM WIDE CHANGES -->
The packaging guidelines will be updated as described in the Scope Section.
There will be no documentation updates, since this change is bringing spec files up-to-date with the current packaging guidelines.


== Release Notes ==
== Release Notes ==

Latest revision as of 19:56, 17 July 2020


Use %make_build and %make_install macros

Summary

This change will increase the use of the %make_build and %make_install macros in spec files.

Owner

Current status

Detailed Description

The goal of this change is to standardize the usage of make in Fedora. All make invocations in spec files that use the  %{_smp_mflags} macro will be modified to use the %make_build macro, and all make invocations that use the install target will be updated to use the %make_install macro. Any additional arguments to make that are not included in either the %make_build and %make_install will be preserved.

All changes will be submitted to dist-git repositories via pull requests. Pull requests will be merged after 1 week if there are no objections or earlier if approved by the package maintainers.

A script will be used to apply the necessary changes to the spec files, and the result will be manually inspected before being merged.

All packages updated by this change request will be rebuilt after the spec file changes are merged.

Some packages already use the %make_build and %make_install macros. These packages will be left unchanged.

Feedback

Feedback from thread on devel list:

  • There are concerns that replacing all make invocations with %make_build, even in cases where there may not be any benefit e.g. for make html may cause build failures or make the spec file less readable. An alternative to replacing all make invocations would be only to replace make in make $BUILD_TARGET, make check, and make install with %make_{build,install}.

As a result of this feedback, the change proposal has been updated to only update make %{_smp_mflags} ... and make install with the macros.

Benefit to Fedora

  • Standardized spec files.
  • This will make it easier to enforce consistent build flag usage across all of Fedora.

Scope

  • Proposal owners: Update spec files and submit pull requests and do new package builds. Optional: Merge pull requests (Proposal Owner would need to request to be added to provenpackagers group)
  • Other developers: Package owners may merge pull requests and submit new builds if they want, but this is not required for them. A member of the provenpackagers group will be needed to merge pull requests.
  • Release engineering: #9533 (a check of an impact with Release Engineering is needed)
  • Policies and guidelines: Package guidelines already specify that packages should use these macros when possible.
  • Trademark approval: N/A (not needed for this Change)

Upgrade/compatibility impact

No impact.

How To Test

Updated packages will be build tested using the koji-simple-ci test that is automatically run when a new pull request is created.

User Experience

End-users will not notice any changes.

Dependencies

No real dependencies, each package can be updated independently.

Contingency Plan

  • Contingency mechanism: None. If not all packages are updated in time, then the work can continue into the next release.
  • Contingency deadline: All work will be done in the rawhide branch, and will not be backported into the f33 branch once it is created, so whatever gets done before the branch date will make it into the release.
  • Blocks release? No
  • Blocks product? No

Documentation

There will be no documentation updates, since this change is bringing spec files up-to-date with the current packaging guidelines.

Release Notes