diff options
-rwxr-xr-x | bin/ebuild.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/ebuild.sh b/bin/ebuild.sh index 7701af1b3..764a59b9a 100755 --- a/bin/ebuild.sh +++ b/bin/ebuild.sh @@ -727,6 +727,11 @@ dyn_unpack() { } dyn_clean() { + if [ -z "${PORTAGE_BUILDDIR}" ]; then + echo "Aborting clean phase because PORTAGE_BUILDDIR is unset!" + return 1 + fi + if [ "$USERLAND" == "BSD" ] && type -p chflags &>/dev/null; then chflags -R noschg,nouchg,nosappnd,nouappnd,nosunlnk,nouunlnk \ "${PORTAGE_BUILDDIR}" |