#! /bin/sh
# i386-gnu-gcc - cross-compile for i386-gnu using /usr/bin/gcc

# Make sure we find shared library dependencies without hardcoding them.
rpath_link="-Wl,-rpath-link=/usr/i386-gnu/lib"
for arg
do
  case "$arg" in
  -c | -S | -E | -M | -MM )
    # No linking to do, so avoid gratuitous warnings.
    rpath_link=
    ;;
  esac
done
gpp_include=`find /usr/i386-gnu/include -type d -name "g++*" 2> /dev/null | tail -n 1`
if [ "$gpp_include" ]; then
  gpp_args="-isystem $gpp_include"
fi
exec /usr/bin/gcc -b i386-gnu -nostdinc \
	-isystem /usr/lib/gcc-lib/i386-gnu/2.95.4/include \
	-isystem /usr/i386-gnu/include $gpp_args \
	${1+"$@"} $rpath_link
