Bug 783433

Summary: brp-python-hardlink fails on files that include spaces
Product: [Fedora] Fedora Reporter: Tadej Janež <tadej.j>
Component: redhat-rpm-configAssignee: Panu Matilainen <pmatilai>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: a.badger, jonathan, loganjerry, pmatilai
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-11-09 11:50:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch that fixes the issue none

Description Tadej Janež 2012-01-20 11:57:05 UTC
Description of problem:

I tried to package a python module and I encountered the following errors:
(except from build.log)
+ /usr/lib/rpm/redhat/brp-python-hardlink
sha1sum: /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize: Is a directory
sha1sum: Qt/OWDistributionsQt.pyc: No such file or directory
sha1sum: /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize: Is a directory
sha1sum: Qt/OWDistributionsQt.pyo: No such file or directory
sha1sum: /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize: Is a directory
sha1sum: Qt/OWRadvizQt.pyc: No such file or directory
...

The first file is /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize Qt/OWDistributionsQt.pyc
The second file is /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize Qt/OWDistributionsQt.pyo
The third file is /home/makerpm/rpmbuild/BUILDROOT/orange-2.5-0.1.20120119svn.fc15.x86_64/usr/lib64/python2.7/site-packages/orange/OrangeWidgets/Visualize Qt/OWRadvizQt.pyc

All the files that are causing errors contain a space, which brp-python-hardling erroneously interprets as a separator between different file names.

Version-Release number of selected component (if applicable):
redhat-rpm-config-9.1.0-13.fc15.noarch

How reproducible:
Always.

Comment 1 Tadej Janež 2012-01-20 12:34:40 UTC
Created attachment 556511 [details]
Patch that fixes the issue

Comment 2 Jerry James 2012-02-26 04:31:52 UTC
brp-java-repack-jars has a similar problem, but I don't see a similarly simple solution.

Comment 3 Tadej Janež 2012-05-18 08:52:33 UTC
Panu, can you please apply my patch from comment #1?

This is still an issue in the current rawhide package: redhat-rpm-config-9.1.0-28.fc18

Comment 4 Toshio Kuratomi 2012-09-25 16:55:01 UTC
I took a look at the patch.  Looks good to me.  It's just quoting the variables that hold the filenames so that they are always a single argument to sha1sum.

Comment 5 Fedora Update System 2012-10-04 01:06:36 UTC
redhat-rpm-config-9.1.0-34.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/redhat-rpm-config-9.1.0-34.fc18

Comment 6 Fedora Update System 2012-10-04 17:48:17 UTC
Package redhat-rpm-config-9.1.0-34.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing redhat-rpm-config-9.1.0-34.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-15361/redhat-rpm-config-9.1.0-34.fc18
then log in and leave karma (feedback).

Comment 7 Toshio Ernie Kuratomi 2012-11-09 11:50:55 UTC
This has been pushed to F18 stable.

Comment 8 Tadej Janež 2012-11-09 12:46:59 UTC
(In reply to comment #7)
> This has been pushed to F18 stable.

When will this change be applied to the Fedora Build System (koji)?

Comment 9 Toshio Ernie Kuratomi 2012-11-09 18:02:12 UTC
It should be there now and for the past while (it actually pushed to stable a while ago but bodhi has a bug that prevents it from closing bugzilla bugs when that happens).

I checked by looking at the root.log of a random F18 build from today: http://kojipkgs.fedoraproject.org//packages/telepathy-gabble/0.16.4/1.fc18/data/logs/i686/root.log

It has redhat-rpm-config-9.1.0-34.fc18  which should have this patch applied.

Comment 10 Tadej Janež 2012-11-10 11:27:57 UTC
(In reply to comment #9)
> 
> It has redhat-rpm-config-9.1.0-34.fc18  which should have this patch applied.

Perfect!

Thanks for the info.