Use readlink -e to canonicalize chrootdir

This commit is contained in:
Jan Steffens 2011-03-13 17:57:28 +01:00
parent ba7cc139c4
commit f72297a639
1 changed files with 3 additions and 2 deletions

View File

@ -67,8 +67,9 @@ while getopts 'hcudr:I:l:' arg; do
esac
done
#Get rid of trailing / in chrootdir
[ "$chrootdir" != "/" ] && chrootdir=$(echo $chrootdir | sed 's#/$##')
# Canonicalize chrootdir, getting rid of trailing /
chrootdir=$(readlink -e "$chrootdir")
copydir="$chrootdir/$COPY"
# Pass all arguments after -- right to makepkg