Index: configure
===================================================================
--- configure	(revision 43430)
+++ configure	(working copy)
@@ -946,36 +946,74 @@
 
 cxx_version=`( $CXX -dumpversion ) 2>&1`
 if test "$?" -gt 0; then
-	cxx_version="not found"
+	# TODO: Big scary warning about unsupported Compilers
+	cxx_version=`( $CXX -version ) 2>&1`
+	if test "$?" -eq 0; then
+		cxx_version="`echo "${cxx_version}" | sed -ne 's/^.*[^0-9]\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*$/\1/gp'`"
+		if test -z "${cxx_version}"; then
+			cxx_version="not found"
+			cxx_verc_fail=yes
+		fi
+		echo non-gcc compiler version ${cxx_version}
+	else
+		cxx_version="not found"
+		cxx_verc_fail=yes
+		echo fooo non-gcc compiler version ${cxx_version}
+	fi
+else
+	add_line_to_config_mk 'HAVE_GCC = 1'
+	HAVE_GCC=1
 fi
 
-case $cxx_version in
-	2.95.[2-9]|2.95.[2-9][-.]*|3.[0-9]|3.[0-9].[0-9]|3.[0-9].[0-9][-.]*|4.[0-9]|4.[0-9].[0-9]|4.[0-9].[0-9][-.]*)
-		_cxx_major=`echo $cxx_version | cut -d '.' -f 1`
-		_cxx_minor=`echo $cxx_version | cut -d '.' -f 2`
-		cxx_version="$cxx_version, ok"
-		cxx_verc_fail=no
-		;;
-	# whacky beos version strings
-	2.9-beos-991026*|2.9-beos-000224*)
-		_cxx_major=2
-		_cxx_minor=95
-		cxx_version="$cxx_version, ok"
-		cxx_verc_fail=no
-		;;
-	3_4)
-		_cxx_major=3
-		_cxx_minor=4
-		;;
-	'not found')
-		cxx_verc_fail=yes
-		;;
-	*)
-		cxx_version="$cxx_version, bad"
-		cxx_verc_fail=yes
-		;;
-esac
+if test "$HAVE_GCC" -eq 1; then
+	case $cxx_version in
+		2.95.[2-9]|2.95.[2-9][-.]*|3.[0-9]|3.[0-9].[0-9]|3.[0-9].[0-9][-.]*|4.[0-9]|4.[0-9].[0-9]|4.[0-9].[0-9][-.]*)
+			_cxx_major=`echo $cxx_version | cut -d '.' -f 1`
+			_cxx_minor=`echo $cxx_version | cut -d '.' -f 2`
+			cxx_version="$cxx_version, ok"
+			cxx_verc_fail=no
+			;;
+		# whacky beos version strings
+		2.9-beos-991026*|2.9-beos-000224*)
+			_cxx_major=2
+			_cxx_minor=95
+			cxx_version="$cxx_version, ok"
+			cxx_verc_fail=no
+			;;
+		3_4)
+			_cxx_major=3
+			_cxx_minor=4
+			;;
+		'not found')
+			cxx_verc_fail=yes
+			;;
+		*)
+			cxx_version="$cxx_version, bad"
+			cxx_verc_fail=yes
+			;;
+	esac
+else
+	case $_host_os in
+		irix*)
+			case $cxx_version in
+				7.4.4*)
+					_cxx_major=7
+					_cxx_minor=4
+					;;
+				*)
+					cxx_version="$cxx_version, bad"
+					cxx_verc_fail=yes
+					;;
+			esac
+			;;
+		*) 
+			cxx_version="$cxx_version, bad"
+			cxx_verc_fail=yes
+			;;
+	esac
 
+fi
+
 echo "$cxx_version"
 
 if test "$cxx_verc_fail" = yes ; then
@@ -1110,7 +1148,10 @@
 		;;
 	irix*)
 		DEFINES="$DEFINES -DUNIX -DIRIX -DSYSTEM_NOT_SUPPORTING_D_TYPE"
-		LIBS="$LIBS -lmd "
+		LIBS="$LIBS -lmd -lfastm -lm"
+		if test "$HAVE_GCC" -ne 1 ; then
+			add_line_to_config_mk 'CXX_UPDATE_DEP_FLAG = -MDupdate'
+		fi
 		_ranlib=:
 		;;
 	darwin*)
@@ -2000,24 +2041,26 @@
 #
 # Do CXXFLAGS now we know the compiler version
 #
-if test "$_cxx_major" -ge "3" ; then
-	case $_host_os in
-	# newlib-based system include files suppress non-C89 function 
-	# declarations under __STRICT_ANSI__
-	mingw* | dreamcast | wii | gamecube | psp | wince | amigaos*)
-		CXXFLAGS="$CXXFLAGS -W -Wno-unused-parameter"
-		;;
-	*)
-		CXXFLAGS="$CXXFLAGS -ansi -W -Wno-unused-parameter"
-		;;
-	esac
-	add_line_to_config_mk 'HAVE_GCC3 = 1'
-fi;
+if test "$HAVE_GCC" -eq 1 ; then
+	if test "$_cxx_major" -ge "3" ; then
+		case $_host_os in
+		# newlib-based system include files suppress non-C89 function 
+		# declarations under __STRICT_ANSI__
+		mingw* | dreamcast | wii | gamecube | psp | wince | amigaos*)
+			CXXFLAGS="$CXXFLAGS -W -Wno-unused-parameter"
+			;;
+		*)
+			CXXFLAGS="$CXXFLAGS -ansi -W -Wno-unused-parameter"
+			;;
+		esac
+		add_line_to_config_mk 'HAVE_GCC3 = 1'
+	fi;
 
-if test "$_cxx_major" -ge "4" && test "$_cxx_minor" -ge "3" ; then
-	CXXFLAGS="$CXXFLAGS -Wno-empty-body"
-else
-	CXXFLAGS="$CXXFLAGS -Wconversion"
+	if test "$_cxx_major" -ge "4" && test "$_cxx_minor" -ge "3" ; then
+		CXXFLAGS="$CXXFLAGS -Wno-empty-body"
+	else
+		CXXFLAGS="$CXXFLAGS -Wconversion"
+	fi;
 fi;
 
 # Some platforms use certain GNU extensions in header files
Index: Makefile.common
===================================================================
--- Makefile.common	(revision 43430)
+++ Makefile.common	(working copy)
@@ -73,15 +73,24 @@
 	$(RM_REC) $(DEPDIRS)
 	$(RM) $(OBJS) $(EXECUTABLE)
 
+ifndef HAVE_GCC
+INCS	= config.h
+ifdef CXX_UPDATE_DEP_FLAG
+%.o: %.cpp
+	$(MKDIR) $(*D)/$(DEPDIR)
+	$(CXX) $(CXX_UPDATE_DEP_FLAG) "$(*D)/$(DEPDIR)/$(*F).d" $(CXXFLAGS) $(CPPFLAGS) -c $(<) -o $*.o
+else
 # Old (dumb) compile & dependcy rules
-#INCS	= scumm/scumm.h common/scummsys.h
-#.cpp.o:
-#	$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(<) -o $*.o
-#$(OBJS): $(INCS)
+.cpp.o:
+	$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(<) -o $*.o
 
+$(OBJS): $(INCS)
+endif
+endif
+
+ifdef HAVE_GCC
 ifndef HAVE_GCC3
-# If you use GCC, disable the above and enable this for intelligent
-# dependency tracking.
+# If you use GCC, enable this for intelligent # dependency tracking.
 %.o: %.cpp
 	$(MKDIR) $(*D)/$(DEPDIR)
 	$(CXX) -Wp,-MMD,"$(*D)/$(DEPDIR)/$(*F).d2" $(CXXFLAGS) $(CPPFLAGS) -c $(<) -o $*.o
@@ -100,6 +109,7 @@
 	$(MKDIR) $(*D)/$(DEPDIR)
 	$(CXX) -Wp,-MMD,"$(*D)/$(DEPDIR)/$(*F).d",-MQ,"$@",-MP $(OBJCFLAGS) -c $(<) -o $*.o
 endif
+endif
 
 ifdef HAVE_NASM
 %.o: %.asm
Index: Makefile
===================================================================
--- Makefile	(revision 43430)
+++ Makefile	(working copy)
@@ -19,28 +19,31 @@
 
 # Load the make rules generated by configure
 -include config.mk
+-include Makedepend
 
-CXXFLAGS:= -Wall $(CXXFLAGS)
-# Turn off some annoying and not-so-useful warnings
-CXXFLAGS+= -Wno-long-long -Wno-multichar -Wno-unknown-pragmas -Wno-reorder
-# Enable even more warnings...
-CXXFLAGS+= -Wpointer-arith -Wcast-qual -Wcast-align
-CXXFLAGS+= -Wshadow -Wimplicit -Wnon-virtual-dtor -Wwrite-strings
+ifeq "$(HAVE_GCC)" "1"
+	CXXFLAGS:= -Wall $(CXXFLAGS)
+	# Turn off some annoying and not-so-useful warnings
+	CXXFLAGS+= -Wno-long-long -Wno-multichar -Wno-unknown-pragmas -Wno-reorder
+	# Enable even more warnings...
+	CXXFLAGS+= -Wpointer-arith -Wcast-qual -Wcast-align
+	CXXFLAGS+= -Wshadow -Wimplicit -Wnon-virtual-dtor -Wwrite-strings
 
-# Currently we disable this gcc flag, since it will also warn in cases,
-# where using GCC_PRINTF (means: __attribute__((format(printf, x, y))))
-# is not possible, thus it would fail compiliation with -Werror without
-# being helpful.
-#CXXFLAGS+= -Wmissing-format-attribute
+	# Currently we disable this gcc flag, since it will also warn in cases,
+	# where using GCC_PRINTF (means: __attribute__((format(printf, x, y))))
+	# is not possible, thus it would fail compiliation with -Werror without
+	# being helpful.
+	#CXXFLAGS+= -Wmissing-format-attribute
 
-# Disable RTTI and exceptions, and enabled checking of pointers returned by "new"
-CXXFLAGS+= -fno-rtti -fno-exceptions -fcheck-new
+	# Disable RTTI and exceptions, and enabled checking of pointers returned by "new"
+	CXXFLAGS+= -fno-rtti -fno-exceptions -fcheck-new
 
-# There is a nice extra warning that flags variables that are potentially
-# used before being initialized. Very handy to catch a certain kind of
-# bugs. Unfortunately, it only works when optimizations are turned on,
-# which is why we normally don't use it.
-#CXXFLAGS+= -O -Wuninitialized
+	# There is a nice extra warning that flags variables that are potentially
+	# used before being initialized. Very handy to catch a certain kind of
+	# bugs. Unfortunately, it only works when optimizations are turned on,
+	# which is why we normally don't use it.
+	#CXXFLAGS+= -O -Wuninitialized
+endif
 
 #######################################################################
 # Default commands - put the necessary replacements in config.mk      #
