Skip to content

Commit

Permalink
Mock release v5.3
Browse files Browse the repository at this point in the history
Created with the help of commands:
$ tito tag --use-version=5.3
$ ./releng/generate-release-notes --use-version 5.3

Closes: rpm-software-management#1265
  • Loading branch information
praiskup committed Dec 13, 2023
1 parent bdfeb38 commit 8a3411e
Show file tree
Hide file tree
Showing 11 changed files with 111 additions and 61 deletions.
2 changes: 1 addition & 1 deletion .tito/packages/mock
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.2-1 mock/
5.3-1 mock/
97 changes: 97 additions & 0 deletions docs/Release-Notes-5.3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
---
layout: default
title: Release Notes - Mock v5.3
---

Released on 2023-12-13.

### Mock 5.3 new features

- A new plugin to pre-process spec files with rpmautospec [has been
implemented][PR#1253].

If this plugin is enabled, mock pre-processes spec files that use rpmautospec
features (for automatic release numbering and changelog generation) before
building a source RPM.

- Only run the `%prep` section once when running `%generate_buildrequires`
multiple times.
Previously Mock run `%prep` repeatedly before each `%generate_buildrequires`
round except for the last one. This was inconsistent and unnecessary
slow/wasteful.

When the original support for `%generate_buildrequires` landed into Mock,
the intention was to only call `%prep` once.
However when Mock added support for multiple rounds of
`%generate_buildrequires`, `%prep` ended up only being skipped in the final
`rpmbuild` call. This was an oversight. `%prep` is now only called once, as
originally intended.

Some RPM packages might be affected by the change, especially if a dirty
working directory after running `%generate_buildrequires` affects the results
of subsequent rounds of `%generate_buildrequires`. However, such behavior was
undefined and quite buggy even previously, due to the lack of the `%prep`
section in the final `rpmbuild` call.

Packages that need to run commands before every round of
`%generate_buildrequires` should place those commands in the
`%generate_buildrequires` section itself rather than `%prep`.

- The automatic killing feature for orphan processes within the chroot environment
[was][PR#1255] [improved][PR#1268] to also provide the user with information
about the command-line arguments of the terminated process:

`WARNING: Leftover process 1331205 is being killed with signal 15: daemon --with-arg`

- The info about package management tooling used to install the target buildroot
has been updated to provide the info earlier, before the buildroot
installation happens. Mock newly informs also about dnf5 presence.


### Bugfixes

- The Bash completion bug in Mock for options accepting multiple arguments,
tracked in the [long-standing issue][issue#746], has been resolved through [PR#1262].

- If DNF 5 sees an "interactive" TTY on stdout, it will try to draw progress bars
and cause the Mock logs to [be garbled](https://github.com/fedora-copr/copr/issues/3040).
This release brings a fix that simply sets the output of DNF5 to a pipe instead
of a PTY.

- When Mock completes the installation of all the requirements generated
by `%generate_buildrequries`, it calls `rpmbuild -ba` to perform a final build
of the package.

During the final build, `%generate_buildrequries` runs again in order to
generate a list of `BuildRequires` to be added to the built SRPM metadata.
An arbitrary `%generate_buildrequries` section may generate different
requirements that may not have been installed.

Previously, the `rpmbuild -ba` call used the `--nodeps` option,
hence it was [possible to successfully build a package with
unsatisfiable BuildRequires in the built SRPM metadata][issue#1246].

When a bootstrap chroot is used, the `--nodeps` option is
[no longer used][PR#1249] in the final `rpmbuild -ba` call.
If `%generate_buildrequries` attempts to generate new unsatisfied requirements
during the final build, the build will fail.
When a bootstrap chroot is not used, the `--nodeps` option remains because
Mock cannot know if the RPM in chroot can read the RPM database.

**Following contributors contributed to this release:**

* Evan Goode
* Jakub Kadlcik
* Miro Hrončok
* Orion Poplawski
* Stephen Gallagh

Thank you!

[issue#746]: https://github.com/rpm-software-management/mock/issues/746
[PR#1268]: https://github.com/rpm-software-management/mock/pull/1268
[issue#1246]: https://github.com/rpm-software-management/mock/issues/1246
[PR#1255]: https://github.com/rpm-software-management/mock/pull/1255
[PR#1262]: https://github.com/rpm-software-management/mock/pull/1262
[PR#1249]: https://github.com/rpm-software-management/mock/pull/1249
[PR#1253]: https://github.com/rpm-software-management/mock/pull/1253
1 change: 1 addition & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ Versions in Linux distributions:


## Release Notes
* [5.3](Release-Notes-5.3) (2023-12-13) - New "rpmautospec" plugin added, `%generate_buildrequries` fixes landed.
* [Configs 39.3](Release-Notes-Configs-39.3) - Fedora 40+ configuration uses DNF5, Fedora ELN and OpenMandriva fixes.
* [Configs 39.2](Release-Notes-39.2) - Fedora ELN and openSUSE fixes.
* [5.2](Release-Notes-5.2) (2023-09-27) - Compatibility fix with EPEL 8, logging fixes, `--copyout` files with tilde in name.
Expand Down
13 changes: 12 additions & 1 deletion mock/mock.spec
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

Summary: Builds packages inside chroots
Name: mock
Version: 5.2.post1
Version: 5.3
Release: 1%{?dist}
License: GPL-2.0-or-later
# Source is created by
Expand Down Expand Up @@ -289,6 +289,17 @@ pylint-3 py/mockbuild/ py/*.py py/mockbuild/plugins/* || :
%dir %{_datadir}/cheat

%changelog
* Wed Dec 13 2023 Pavel Raiskup <[email protected]> 5.3-1
- orphanskill: log command line arguments of the terminated process
- docs: migrate the community from IRC to Matrix
- dnf5: don't output to a PTY ([email protected])
- new rpmautospec plugin ([email protected], [email protected])
- fix bash completion with multiple file arguments ([email protected])
- only %%prep once when running %%generate_buildrequires multiple times ([email protected])
- Dynamic BuildRequires: Prevent generation of unsatisfied dependency ([email protected])
- Identify buildroot package management earlier ([email protected])
- Dump also dnf5 info into logs

* Wed Sep 27 2023 Pavel Raiskup <[email protected]> 5.2-1
- Fix '~' user source expansion for --copyout
- Compatibility fix with EL 8
Expand Down

This file was deleted.

5 changes: 0 additions & 5 deletions releng/release-notes-next/better-orphankill-report.feature

This file was deleted.

4 changes: 0 additions & 4 deletions releng/release-notes-next/dnf5-logs-with-no-pty.bugfix

This file was deleted.

19 changes: 0 additions & 19 deletions releng/release-notes-next/generate_buildrequires.bug

This file was deleted.

22 changes: 0 additions & 22 deletions releng/release-notes-next/generate_buildrequires_prep.feature

This file was deleted.

3 changes: 0 additions & 3 deletions releng/release-notes-next/package-management-logging.feature

This file was deleted.

4 changes: 0 additions & 4 deletions releng/release-notes-next/rpmautospec-plugin.feature

This file was deleted.

0 comments on commit 8a3411e

Please sign in to comment.