Cleanup tmpdirs if genkernel dies abnormally
authorEric Edgar <rocket@gentoo.org>
Mon, 18 Jul 2005 20:20:16 +0000 (20:20 +0000)
committerEric Edgar <rocket@gentoo.org>
Mon, 18 Jul 2005 20:20:16 +0000 (20:20 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/genkernel/trunk@270 67a159dc-881f-0410-a524-ba9dfbe2cb84

gen_funcs.sh
genkernel

index 21d35f3a59580e74cb17cd4bf4d41c0bd13df196..dcc48bf64dba965d9f4c2b0bb677253b16193193 100755 (executable)
@@ -225,6 +225,9 @@ gen_die() {
        print_info 1 'Please do *not* report compilation failures as genkernel bugs!'
        print_info 1 ''
        exit 1
+
+       # Cleanup temp dirs and caches if requested
+       cleanup
 }
 
 has_loop() {
index 9c15c16c267db439f2ba7cb125929b7db057db70..8f42f500eb595737f699197bf5a117d03b1142e3 100755 (executable)
--- a/genkernel
+++ b/genkernel
@@ -29,7 +29,6 @@ TEMP=${TEMP}/$RANDOM.$RANDOM.$RANDOM.$$
 
 cleanup(){
     if [ -n "$TEMP" -a -d "$TEMP" ]; then
-       echo "Removing $TEMP"
        rm -rf "$TEMP"
     fi