xbps_remove_pkg(): continue even if $destdir is not there.

Binary packages won't provide $destdir anyway.

--HG--
extra : convert_revision : b803c58c359e7e0f321d5855faa7ac2377b05364
This commit is contained in:
Juan RP 2008-12-29 16:47:57 +01:00
parent 3bb459b493
commit d8e8d3f6ab

View file

@ -156,13 +156,9 @@ remove_pkg()
ver=$($XBPS_REGPKGDB_CMD version $pkg)
[ -z "$ver" ] && msg_error "$pkg is not installed."
if [ ! -d "$XBPS_DESTDIR/$pkg-$ver" ]; then
msg_error "cannot find package on $XBPS_DESTDIR."
fi
. $XBPS_SHUTILSDIR/stow_funcs.sh
unstow_pkg $pkg
if [ $? -eq 0 ]; then
if [ $? -eq 0 -a -d $XBPS_DESTDIR/$pkg-$ver ]; then
rm -rf $XBPS_DESTDIR/$pkg-$ver
fi
return $?