Following patch allows compiling geode driver latest Xorg release
candidate.
From fbb9a1e5bf2a382eb6ab69b5ecc63d68657a1bd7 Mon Sep 17 00:00:00 2001
From: Priit Laes <[email protected]>
Date: Sun, 12 Dec 2010 16:17:24 +0200
Subject: [PATCH] Fix compilation under xorg >1.9.99

Signed-off-by: Priit Laes <[email protected]>
---
 src/gx_randr.c |   11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/src/gx_randr.c b/src/gx_randr.c
index 1593c97..345eaa5 100644
--- a/src/gx_randr.c
+++ b/src/gx_randr.c
@@ -26,7 +26,12 @@
  * software without specific prior written permission.
  */
 
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
 #include "xf86.h"
+#include "xf86Modes.h"
 #include "os.h"
 #include "globals.h"
 #include "xf86.h"
@@ -171,7 +176,9 @@ GXRandRSetMode(ScreenPtr pScreen,
 #endif
     DisplayModePtr currentMode = NULL;
     Bool ret = TRUE;
+#if XORG_VERSION_CURRENT < XORG_VERSION_NUMERIC(1,9,99,1,0)
     PixmapPtr pspix = NULL;
+ #endif
 
     if (pRoot)
 	(*pScrni->EnableDisableFBAccess) (pScreen->myNum, FALSE);
@@ -210,16 +217,16 @@ GXRandRSetMode(ScreenPtr pScreen,
 	pScrni->currentMode = currentMode;
     }
 
+#if XORG_VERSION_CURRENT < XORG_VERSION_NUMERIC(1,9,99,1,0)
     /*
      * Get the new Screen pixmap ptr as SwitchMode might have called
      * ModifyPixmapHeader and xf86EnableDisableFBAccess will put it back...
      * Unfortunately.
-     
      */
-
     pspix = (*pScreen->GetScreenPixmap) (pScreen);
     if (pspix->devPrivate.ptr)
 	pScrni->pixmapPrivate = pspix->devPrivate;
+#endif
 
     xf86ReconfigureLayout();
 
-- 
1.7.3.3

_______________________________________________
Xorg-driver-geode mailing list
[email protected]
http://lists.x.org/mailman/listinfo/xorg-driver-geode

Reply via email to