stow_funcs.sh: check for rw perms in {dest,master}dir.
--HG-- extra : convert_revision : fa9d0464480adef1ffd1e14c5a53cd1b96b5acd8
This commit is contained in:
parent
cf4103ec73
commit
b80643802a
@ -35,6 +35,10 @@ stow_pkg()
|
||||
|
||||
[ -z "$pkg" ] && return 2
|
||||
|
||||
if [ ! -w $destdir -o ! -w $XBPS_MASTERDIR ]; then
|
||||
msg_error "cannot stow $pkg! (permission denied)"
|
||||
fi
|
||||
|
||||
if [ "$build_style" = "meta-template" ]; then
|
||||
[ ! -d $destdir ] && mkdir -p $destdir
|
||||
fi
|
||||
@ -86,6 +90,10 @@ unstow_pkg()
|
||||
|
||||
[ -z $pkg ] && msg_error "template wasn't specified?"
|
||||
|
||||
if [ ! -w $XBPS_MASTERDIR ]; then
|
||||
msg_error "cannot unstow $pkg! (permission denied)"
|
||||
fi
|
||||
|
||||
if [ "$pkgname" != "$pkg" ]; then
|
||||
. $XBPS_TEMPLATESDIR/$pkg.tmpl
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user