$OpenBSD: patch-configure,v 1.2 2005/08/11 01:15:17 todd Exp $
--- configure.orig	Sun Jul 24 13:52:08 2005
+++ configure	Tue Aug  9 22:34:48 2005
@@ -21,8 +21,8 @@ prefix=""
 interp_prefix="/usr/gnemul/qemu-%M"
 static="no"
 cross_prefix=""
-cc="gcc"
-host_cc="gcc"
+cc="${CC:-cc}"
+host_cc="${CC:-cc}"
 ar="ar"
 make="make"
 strip="strip"
@@ -41,7 +41,7 @@ case "$cpu" in
   alpha)
     cpu="alpha"
   ;;
-  "Power Macintosh"|ppc|ppc64)
+  "Power Macintosh"|macppc|ppc|ppc64)
     cpu="powerpc"
   ;;
   mips)
@@ -109,6 +109,7 @@ oss="yes"
 ;;
 OpenBSD)
 bsd="yes"
+openbsd="yes"
 oss="yes"
 ;;
 Darwin)
@@ -366,7 +367,7 @@ else
 if test -z "$prefix" ; then
     prefix="/usr/local"
 fi
-mandir="$prefix/share/man"
+mandir="$prefix/man"
 datadir="$prefix/share/qemu"
 docdir="$prefix/share/doc/qemu"
 bindir="$prefix/bin"
@@ -434,9 +435,7 @@ if test "$darwin" = "yes" ; then
     echo "Cocoa support     $cocoa"
 fi
 echo "SDL support       $sdl"
-if test "$sdl" != "no" ; then
-    echo "SDL static link   $sdl_static"
-fi
+echo "SDL static link   $sdl_static"
 echo "mingw32 support   $mingw32"
 echo "Adlib support     $adlib"
 echo -n "FMOD support      $fmod"
@@ -567,6 +566,9 @@ fi
 if test "$oss" = "yes" ; then
   echo "CONFIG_OSS=yes" >> $config_mak
   echo "#define CONFIG_OSS 1" >> $config_h
+  if test "$openbsd"="yes" ; then
+     echo "CONFIG_OSS_LIBRARY=yes" >> $config_mak
+  fi
 fi
 if test "$fmod" = "yes" ; then
   echo "CONFIG_FMOD=yes" >> $config_mak
@@ -599,6 +601,14 @@ if [ "$bsd" = "yes" ] ; then
   echo "#define MAP_ANONYMOUS MAP_ANON" >> $config_h
   echo "#define _BSD 1" >> $config_h
 fi
+
+if [ "$openbsd" = "yes" ] ; then
+  echo "#define ENOTSUP 4096" >> $config_h
+  echo "#define PRIx64 \"llX\"" >> $config_h
+  echo "#define qemu_siginfo siginfo_t" >> $config_h
+else
+  echo "#define qemu_siginfo struct siginfo" >> $config_h
+fi     
 
 for target in $target_list; do 
 
