Fix triggers for the installation and removal of gcc-plugin-annobin.
Resolves: #2167713
This commit is contained in:
parent
f14ea70dac
commit
fb76cc62ed
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
Summary: Red Hat specific rpm configuration files
|
Summary: Red Hat specific rpm configuration files
|
||||||
Name: redhat-rpm-config
|
Name: redhat-rpm-config
|
||||||
Version: 197
|
Version: 198
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
# No version specified.
|
# No version specified.
|
||||||
License: GPL+
|
License: GPL+
|
||||||
@ -169,16 +169,49 @@ install -p -m 644 -t %{buildroot}%{_rpmluadir}/fedora/srpm forge.lua
|
|||||||
|
|
||||||
# This trigger is used to decide which version of the annobin plugin for gcc
|
# This trigger is used to decide which version of the annobin plugin for gcc
|
||||||
# should be used. See comments in the script for full details.
|
# should be used. See comments in the script for full details.
|
||||||
|
#
|
||||||
|
# Note: for RHEL the rpm containing the annobin built plugin is called
|
||||||
|
# "annobin", whereas in Fedora it is called "annobin-plugin-gcc". This is
|
||||||
|
# for historical reasons and will change with the introduction of RHEL-10.
|
||||||
|
#
|
||||||
|
# Note - whilst "gcc-plugin-annobin" requires "gcc" and hence in theory we
|
||||||
|
# do not need to trigger on "gcc", the redhat-annobin-plugin-select.sh
|
||||||
|
# script invokes gcc to determine the version of the gcc plugin, and this
|
||||||
|
# can be significant.
|
||||||
|
#
|
||||||
|
# For example, suppose that version N of gcc is installed and that annobin
|
||||||
|
# version A (built by gcc version N) is also installed. Then a new version
|
||||||
|
# of gcc is released. If the rpms are updated in this order:
|
||||||
|
# gcc-plugin-annobin
|
||||||
|
# gcc
|
||||||
|
# then when the trigger for gcc-plugin-annobin is run, the script will see
|
||||||
|
# (the not yet updated) gcc is currently version N, which matches the current
|
||||||
|
# annobin plugin A, so no changes are necessary. Then gcc is updated and,
|
||||||
|
# if the trigger below did not include "gcc", the script would not run again
|
||||||
|
# and so now you would have an out of date version of the annobin plugin.
|
||||||
|
#
|
||||||
|
# Alternatively imagine installing gcc and annobin for the first time.
|
||||||
|
# If the installation order is:
|
||||||
|
# gcc
|
||||||
|
# annobin-plugin-gcc
|
||||||
|
# gcc-plugin-annobin
|
||||||
|
# then the installation of gcc will not cause the gcc-plugin-annobin to be
|
||||||
|
# selected, since it does not exist yet. Then annobin-plugin-gcc is installed
|
||||||
|
# and since it is the only plugin, it will be selected. Then
|
||||||
|
# gcc-plugin-annobin is installed, and if the trigger below was not set to
|
||||||
|
# run on gcc-plugin-annobin, it would pass unnoticed.
|
||||||
|
#
|
||||||
|
# Hence it is necessary to trigger on both gcc and gcc-plugin-annobin.
|
||||||
|
|
||||||
%triggerin -- annobin gcc-plugin-annobin
|
%triggerin -- annobin gcc-plugin-annobin gcc
|
||||||
%{rrcdir}/redhat-annobin-plugin-select.sh
|
%{rrcdir}/redhat-annobin-plugin-select.sh
|
||||||
%end
|
%end
|
||||||
|
|
||||||
# We also trigger when annobin is uninstalled. This allows us to switch
|
# We also trigger when an annobin plugin is uninstalled. This allows us to switch
|
||||||
# over to the gcc generated version of the plugin. It does not matter if
|
# over to the other version of the plugin. It does not matter if
|
||||||
# gcc is uninstalled, since if that happens the plugin cannot be used.
|
# gcc is uninstalled, since if that happens the plugin cannot be used.
|
||||||
|
|
||||||
%triggerpostun -- annobin
|
%triggerpostun -- annobin gcc-plugin-annobin
|
||||||
%{rrcdir}/redhat-annobin-plugin-select.sh
|
%{rrcdir}/redhat-annobin-plugin-select.sh
|
||||||
%end
|
%end
|
||||||
|
|
||||||
@ -216,6 +249,9 @@ install -p -m 644 -t %{buildroot}%{_rpmluadir}/fedora/srpm forge.lua
|
|||||||
%doc buildflags.md
|
%doc buildflags.md
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Feb 07 2023 Nick Clifton <nickc@redhat.com> - 198-1
|
||||||
|
- Fix triggers for the installation and removal of gcc-plugin-annobin. (#2167713)
|
||||||
|
|
||||||
* Wed Sep 21 2022 Timm Bäder <tbaeder@redhat.com> - 197-1
|
* Wed Sep 21 2022 Timm Bäder <tbaeder@redhat.com> - 197-1
|
||||||
- Ship brp-llvm-compile-lto-elf script
|
- Ship brp-llvm-compile-lto-elf script
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user