Use $TMPDIR rather than hardcoding for /tmp