Use sub-directory that will be clean to correct building.
[SquirrelJME.git] / utils-dev / tmpdir.sh
blobdbc91fcc7b65a3a14c869f2062d823b70d7882f8
1 #!/bin/sh
2 # ---------------------------------------------------------------------------
3 # Multi-Phasic Applications: SquirrelJME
4 # Copyright (C) Stephanie Gawroriski <xer@multiphasicapps.net>
5 # ---------------------------------------------------------------------------
6 # SquirrelJME is under the GNU General Public License v3+, or later.
7 # See license.mkd for licensing and copyright information.
8 # ---------------------------------------------------------------------------
9 # DESCRIPTION: Outputs the temporary directory
11 # Force C locale
12 export LC_ALL=C
14 # Directory of this script
15 __exedir="$(dirname -- "$0")"
17 # Use this environment variable
18 if [ -n "$TMPDIR" ]
19 then
20 echo "$TMPDIR"
22 # Otherwise a fixed directory
23 else
24 echo "/tmp"