$NetBSD: patch-ag,v 1.4 2006/08/19 23:34:54 abs Exp $

--- config/os-type.orig	1999-08-04 16:57:30.000000000 +0100
+++ config/os-type
@@ -75,7 +75,6 @@ fi
 if [ -z "${OS}" -a ! -z "${uname}" ]; then
 	case "`$uname -a | tr '[A-Z]' '[a-z]'`" in
 		"osf1"*)	OS="osf1";;
-		*"4.0"*)	OS=svr4;;	# There has to be a better way
 		*" dcosx "*)	OS=dcosx;;
 		*"cx/ux"*)	OS=cxux;;
 		*"hp-ux"*)	OS=hpux;;	# HP-UX 9.x
@@ -102,6 +101,7 @@ if [ -z "${OS}" -a ! -z "${uname}" ]; th
 		"linux"*)	OS=linux;;
 		"netbsd"*)	OS="${osname}";;
 		"freebsd"*)	OS="${osname}${osmajver}";;
+		"dragonfly"*)	OS="${osname}";;
 		"openbsd"*)	OS="${osname}";;
 		"dgux"*)	OS=dgux;;
 		"unicos"*)	OS=unicos;;
@@ -109,6 +109,13 @@ if [ -z "${OS}" -a ! -z "${uname}" ]; th
 	esac
 fi
 
+# At least do this _after_ the above to avoid some false matches
+if [ -z "${OS}" -a ! -z "${uname}" ]; then
+    case "`$uname -a | tr '[A-Z]' '[a-z]'`" in
+	*"4.0"*)	OS=svr4;;	# There has to be a better way
+    esac
+fi
+
 #
 # NeXTStep specific.
 #
