summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2024-06-27 03:18:23 +0100
committerLeah Rowe <leah@libreboot.org>2024-06-27 03:18:23 +0100
commitfac74cd60a3d90e6e0df971b481a55b0a01050c4 (patch)
tree55903b0d83895d9592a93ffb7bdf42d8fb7ffe92 /build
parent671893a802cb9f7b684037062d0debd1c049addb (diff)
lib.sh: simplified TMPDIR handling
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'build')
-rwxr-xr-xbuild8
1 files changed, 4 insertions, 4 deletions
diff --git a/build b/build
index ef5a1109..6eae3aac 100755
--- a/build
+++ b/build
@@ -125,16 +125,16 @@ fetch_trees()
fail()
{
- tmp_cleanup || printf "WARNING: can't rm tmpfiles: %s\n" "$tmpdir" 1>&2
+ tmp_cleanup || printf "WARNING: can't rm tmpfiles: %s\n" "$TMPDIR" 1>&2
err_ "${1}"
}
tmp_cleanup()
{
- [ "$tmpdir_was_set" = "n" ] || return 0
- rm -Rf "$tmpdir" || return 1
+ [ "$xbmk_parent" = "y" ] || return 0
+ rm -Rf "$TMPDIR" || return 1
rm -f lock || return 1
}
main $@
-tmp_cleanup || err_ "can't rm tmpdir upon non-zero exit: $tmpdir"
+tmp_cleanup || err_ "can't rm TMPDIR upon non-zero exit: $TMPDIR"