#!/bin/sh
# Simple bootstrap script for the installer. This script uses the bundled
# Ruby interpreter binary whenever possible, and falls back to the system's
# Ruby interpreter if no suitable bundled Ruby interpreter exists.
dir=`dirname "$0"`
cd "$dir"
platform="`uname`-`uname -m`"
if ruby -e '' 2>/dev/null; then
	exec ruby installer.rb "$@"
else
	#echo "Using 'runtime/$platform/ruby'"
	RUBYOPT=""
	export RUBYOPT
	exec "runtime/$platform/ruby" installer.rb "$@"
fi
