open-src/xserver/xorg/pci-stubs.patch
changeset 606 068c11b419c9
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/open-src/xserver/xorg/pci-stubs.patch	Thu Jan 15 12:55:00 2009 -0800
@@ -0,0 +1,51 @@
+From 570835b9a89187a36e08defbccc56051bb349b52 Mon Sep 17 00:00:00 2001
+From: Alan Coopersmith <[email protected]>
+Date: Wed, 19 Nov 2008 10:19:20 -0800
+Subject: [PATCH] Use bsd_pci stub routines on Solaris too, since we use pciaccess for real work
+
+Depends on commit 70e18a3b6b9d52169bca650f6cd4ef5d8ab40d95 to get
+definition of xf86InitVidMem on Solaris.
+---
+ configure.ac                    |    5 ++++-
+ hw/xfree86/os-support/bus/Pci.h |    2 +-
+ 2 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 4bea8ac..048416f 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1278,6 +1278,9 @@ if test "x$XORG" = xyes; then
+ 	  solaris*)
+ 	  	XORG_OS="solaris"
+ 		XORG_OS_SUBDIR="solaris"
++		# Use the same stubs as BSD for old functions, since we now
++		# use libpciaccess for PCI
++		xorg_bus_bsdpci="yes"
+ 		AC_CHECK_HEADERS([sys/kd.h])
+ 		# This really should be tests for specific features, but the #ifdef's
+ 		# were done as a simple version check in XFree86 4.x and haven't been 
+@@ -1346,7 +1349,7 @@ if test "x$XORG" = xyes; then
+ 		;;
+ 	  i*86|x86_64*|amd64*)
+ 		case $host_os in
+-		  *bsd*|linux*)
++		  *bsd*|linux*|solaris*)
+ 			;;
+ 		  *)
+ 			xorg_bus_ix86pci="yes"
+diff --git a/hw/xfree86/os-support/bus/Pci.h b/hw/xfree86/os-support/bus/Pci.h
+index 31a7fbf..2eb1745 100644
+--- a/hw/xfree86/os-support/bus/Pci.h
++++ b/hw/xfree86/os-support/bus/Pci.h
+@@ -179,7 +179,7 @@
+ #define PCI_CFGMECH1_MAXDEV	32
+ 
+ #if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || \
+-	defined(__DragonFly__)
++	defined(__DragonFly__) || defined(__sun)
+ #define ARCH_PCI_INIT bsdPciInit
+ #endif
+ 
+-- 
+1.5.6.5
+