Author dpward
Recipients dpward, dstufft, eric.araujo
Date 2015-09-20.02:12:33
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1442715156.03.0.0265256317041.issue25187@psf.upfronthosting.co.za>
In-reply-to
Content
bdist_rpm wrongly assumes a hard-coded format for the filename of the non-source RPM which is generated when it calls rpmbuild, specifically:
"%{arch}/%{name}-%{version}-%{release}.%{arch}.rpm"

The format used by rpmbuild is actually specified by the RPM macro %{_rpmfilename}. With the /usr/lib/rpm/macros file that is shipped with official releases of RPM (at http://rpm.org), %{_rpmfilename} evaluates to the value above. However this value cannot be assumed: the directory "%{arch}/" is dropped under the Mock chroot environment (https://fedoraproject.org/wiki/Mock). Mock is used to build all official Fedora Project packages (by Koji) as well as unofficial packages (by Copr). These two build systems also target Extra Packages for Enterprise Linux (EPEL) in addition to Fedora releases.

As a result, bdist_rpm fails when trying to move the non-source RPM to the 'dist' folder after it is built by rpmbuild.

The attached patch causes bdist_rpm to evaluate "%{_rpmfilename}" instead of relying on the hard-coded value.
History
Date User Action Args
2015-09-20 02:12:36dpwardsetrecipients: + dpward, eric.araujo, dstufft
2015-09-20 02:12:36dpwardsetmessageid: <1442715156.03.0.0265256317041.issue25187@psf.upfronthosting.co.za>
2015-09-20 02:12:35dpwardlinkissue25187 messages
2015-09-20 02:12:34dpwardcreate