Why does '.el7' get duplicated while building the rpm file using spec in Red Hat Enterprise Linux 7?
Issue
- Trying to build a custom
rpmfile, whereReleaseis defined as follows inspecfile.
Release: 3%{?dist}
- Everything works as expected.
%{dist}becomes part of the produced file name, eg,foo-1.2-3.el7.noarch.rpmetc. And, if the following is used:
Release: %{?release}
- It gets a name sans
%{dist}, eg,foo-1.2-3.noarch.rpm. - However, if the following is used, the
.el7gets duplicated. That is,foo-1.2-3.el7.el7.noarch.rpm, why?
Release: %{?release}%{?dist}
- What is wrong? How can one get a parameterized
releasenumber with just one instance of the%{dist}?
Environment
- Red Hat Enterprise Linux 7.0
rpmbuild
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.