dosbox-x/env-gcc-8.3.sh
Jookia b3fa848f0f Replace '/bin/bash' with '/usr/bin/env bash' in shebangs
This should hopefully help portability with BSDs.
2022-12-12 17:52:27 +08:00

25 lines
401 B
Bash
Executable File

#!/usr/bin/env bash
#
# Look for GCC-8.3
x=`which gcc-8.3 2>/dev/null`
if [ -n "$x" ]; then
gdir=`dirname $x`
elif [ -f "/usr/gcc-8.3/bin/gcc" ]; then
gdir="/usr/gcc-8.3/bin"
else
echo Cannot find GCC 8.3
exit 1
fi
echo GCC is in $gdir
export CC="$gdir/gcc"
export CPP="$gdir/cpp"
export CXX="$gdir/g++"
export PATH="$gdir:$PATH"
echo Starting subshell. Type exit to exit.
$SHELL