redhat-rpm-config/redhat-rpm-config-9.1.0-python-hardlink-spaces-in-filenames.patch
Toshio Kuratomi 94fba4eae8 Add patch from https://bugzilla.redhat.com/show_bug.cgi?id=783433
to fix spaces in files and directories that are fed to the
  brp-python-hardlink script
2012-10-03 10:17:07 -07:00

16 lines
681 B
Diff

diff --git a/brp-python-hardlink b/brp-python-hardlink
index a937529..210d69c 100755
--- a/brp-python-hardlink
+++ b/brp-python-hardlink
@@ -10,8 +10,8 @@ fi
find "$RPM_BUILD_ROOT" -type f -name "*.pyc" | while read pyc ; do
pyo="$(echo $pyc | sed -e 's/.pyc$/.pyo/')"
if [ -f "$pyo" ] ; then
- csha="$(sha1sum -b $pyc | cut -d' ' -f 1)" && \
- osha="$(sha1sum -b $pyo | cut -d' ' -f 1)" && \
+ csha="$(sha1sum -b "$pyc" | cut -d' ' -f 1)" && \
+ osha="$(sha1sum -b "$pyo" | cut -d' ' -f 1)" && \
if [ "$csha" = "$osha" ] ; then
ln -f "$pyc" "$pyo"
fi