Fix find-debuginfo.sh behavior on cross-directory hardlinks (RhBug:618426)

- The find-debuginfo.sh script makes hard links of .debug files to
  correspond to hard links between install binaries.  It can fail to
  create one of these .debug hard links if it's in a directory that
  didn't exist at that point in the script run. How this happens
  depends on things like the order "find" lists files, so it can
  be hard to reproduce off hand.
This commit is contained in:
Roland McGrath 2010-08-09 15:27:03 +03:00 committed by Panu Matilainen
parent 9570a7f6af
commit c72fc6adba
1 changed files with 1 additions and 1 deletions

View File

@ -191,7 +191,7 @@ while read nlinks inum f; do
link=$debugfn
get_debugfn "$linked"
echo "hard linked $link to $debugfn"
ln -nf "$debugfn" "$link"
mkdir -p "$(dirname "$link")" && ln -nf "$debugfn" "$link"
continue
else
eval linked_$inum=\$f