Pass XBPS_MASTERDIR to the xbps-src signal handler.
This commit is contained in:
parent
fe36d782ca
commit
fecc9617dd
|
@ -96,7 +96,9 @@ umount_chroot_fs()
|
|||
|
||||
# Remove created dirs
|
||||
if [ ! -f ${XBPS_MASTERDIR}/.xbps_mount_bind_done ]; then
|
||||
[ -d ${XBPS_MASTERDIR}/xbps ] && rmdir ${XBPS_MASTERDIR}/xbps
|
||||
if [ -d ${XBPS_MASTERDIR}/xbps ]; then
|
||||
rmdir ${XBPS_MASTERDIR}/xbps 2>/dev/null
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -33,13 +33,14 @@
|
|||
: ${xbps_machine:=$(uname -m)}
|
||||
: ${XBPS_UTILS_REQVER:=20100511}
|
||||
|
||||
trap 'sighandler_exit $?' 0 INT QUIT
|
||||
trap '_MASTERDIR=${XBPS_MASTERDIR} sighandler_exit $?' 0 INT QUIT
|
||||
|
||||
sighandler_exit()
|
||||
{
|
||||
# Always unmount in case, we failed before!
|
||||
if [ -z "$in_chroot" ]; then
|
||||
@@XBPS_INSTALL_LIBEXECDIR@@/xbps-src-chroot-helper umount
|
||||
env MASTERDIR="${_MASTERDIR}" \
|
||||
@@XBPS_INSTALL_LIBEXECDIR@@/xbps-src-chroot-helper umount
|
||||
fi
|
||||
[ -n "$1" ] && exit $1
|
||||
exit $?
|
||||
|
|
Loading…
Reference in New Issue