exit point, create a trap to automatically delete the script when exiting.
This way the linker script gets cleaned up whenever there is an error as
well. Otherwise every link invocation that ends in a failure could leave
behind crap. On my system, i found almost 2 million of these suckers in
my /tmp dir.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
[ "$VERBOSE" = "y" ] && set -x
ARG1="$ARG1 $FINAL_ONLY"
NEWLDSCRIPT=`mktemp /tmp/flt-XXXXXX`
+ trap 'rm -f "$NEWLDSCRIPT"' EXIT
SEDOP=" -e s/^R_RODAT// -e /^W_RODAT/d"
OBJCOPYOP=""
if [ "$MOVDAT" ]
fi
fi
[ "$RFILE" = "$OFILE.gdb" ] || rm -f "$RFILE" # not needed for any reason
- rm -f "$NEWLDSCRIPT"
exit 0
fi