Bug 1247140 - Build failure due to bogus complaints about "Trigger fired by the same package is already defined in spec file"
Summary: Build failure due to bogus complaints about "Trigger fired by the same packag...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: rawhide
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Packaging Maintenance Team
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-27 12:26 UTC by Mattias Ellert
Modified: 2015-07-27 13:34 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2015-07-27 13:31:40 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Mattias Ellert 2015-07-27 12:26:46 UTC
Description of problem:

If a package has more than one %triggerun on the same package but with different versions the build fails with the error

Trigger fired by the same package is already defined in spec file

E.g. the openssh-server package in the openssh specfile has two %triggerun as follows:

$ grep triggerun openssh.spec 
%triggerun -n openssh-server -- openssh-server < 5.8p2-12
%triggerun -n openssh-server -- openssh-server < 5.9p1-22

A scratch build of this package in Fedora Rawhide is here:

https://koji.fedoraproject.org/koji/taskinfo?taskID=10492777

The buildlog from the buildSRPMFromSCM task of this build:

https://kojipkgs.fedoraproject.org//work/tasks/2778/10492778/build.log

says: "Trigger fired by the same package is already defined in spec file"

In the rpm git history the commit message for the following commit:

https://github.com/rpm-software-management/rpm/commit/77146f94b598079a24ab779f71e6c2ebf151cd24

reads: "Allow multiple triggers fired by the some package of different versions"

(I assume there is a typo here s/some/same/)

So there seems to have been an attept to fix this problem, but it doesn't seem to have worked since it still trips on this check and fails.


Version-Release number of selected component (if applicable):

rpm-build-4.12.90-1.fc24

How reproducible:

Always

Steps to Reproduce:
1. See above

Actual results:

Failed build

Expected results:

Successful build

Comment 1 Ľuboš Kardoš 2015-07-27 13:31:40 UTC
The problem is that given version intervals overlap, so in some cases both version conditions are fulfilled (e.g for openssh-server-5.6p1-30) but rpm always sets off only one trigger that's why build of that package is refused. Previously rpm didn't refuse to build packages with overlapping version intervals but rpm always set off only one trigger. So probably triggers in your package didn't work as you expected also in previous version of rpm. 

This is expected behavior, closing as not a bug.

Comment 2 Ľuboš Kardoš 2015-07-27 13:34:23 UTC
See also: #585384 and #702378


Note You need to log in before you can comment on or make changes to this bug.