guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/03: gnu: xf86-video-savage: Fix FTBFS with xorg-server >= 1.20.


From: Marius Bakke
Subject: 02/03: gnu: xf86-video-savage: Fix FTBFS with xorg-server >= 1.20.
Date: Sun, 8 Jul 2018 17:21:08 -0400 (EDT)

mbakke pushed a commit to branch staging
in repository guix.

commit a4edd9ad05821284f532cb912e757955cf656f7e
Author: Marius Bakke <address@hidden>
Date:   Sun Jul 8 18:33:07 2018 +0200

    gnu: xf86-video-savage: Fix FTBFS with xorg-server >= 1.20.
    
    * gnu/packages/patches/xf86-video-savage-xorg-compat.patch: New file.
    * gnu/local.mk (dist_patch_DATA): Register it.
    * gnu/packages/xorg.scm (xf86-video-savage)[source](patches): Use it.
---
 gnu/local.mk                                       |  1 +
 .../patches/xf86-video-savage-xorg-compat.patch    | 33 ++++++++++++++++++++++
 gnu/packages/xorg.scm                              |  1 +
 3 files changed, 35 insertions(+)

diff --git a/gnu/local.mk b/gnu/local.mk
index 89bad3d..47963b6 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1214,6 +1214,7 @@ dist_patch_DATA =                                         
\
   %D%/packages/patches/xf86-video-geode-glibc-2.20.patch       \
   %D%/packages/patches/xf86-video-i128-remove-mibstore.patch   \
   %D%/packages/patches/xf86-video-mach64-glibc-2.20.patch      \
+  %D%/packages/patches/xf86-video-savage-xorg-compat.patch     \
   %D%/packages/patches/xf86-video-siliconmotion-fix-ftbfs.patch \
   %D%/packages/patches/xf86-video-sis-xorg-compat.patch        \
   %D%/packages/patches/xf86-video-tga-remove-mibstore.patch    \
diff --git a/gnu/packages/patches/xf86-video-savage-xorg-compat.patch 
b/gnu/packages/patches/xf86-video-savage-xorg-compat.patch
new file mode 100644
index 0000000..9524032
--- /dev/null
+++ b/gnu/packages/patches/xf86-video-savage-xorg-compat.patch
@@ -0,0 +1,33 @@
+Fix build against xorg-server >= 1.20.
+
+Patch taken from upstream:
+https://cgit.freedesktop.org/xorg/driver/xf86-video-savage/commit/?id=0ece556daa8a88771b669d8104396abd9166d2d0
+
+diff --git a/src/savage_driver.c b/src/savage_driver.c
+index 58a294d..3cda923 100644
+--- a/src/savage_driver.c
++++ b/src/savage_driver.c
+@@ -2034,8 +2034,6 @@ static Bool SavagePreInit(ScrnInfoPtr pScrn, int flags)
+     xf86DrvMsg(pScrn->scrnIndex, X_PROBED, "Detected current MCLK value of 
%1.3f MHz\n",
+              mclk / 1000.0);
+ 
+-    pScrn->maxHValue = 2048 << 3;     /* 11 bits of h_total 8-pixel units */
+-    pScrn->maxVValue = 2048;          /* 11 bits of v_total */
+     pScrn->virtualX = pScrn->display->virtualX;
+     pScrn->virtualY = pScrn->display->virtualY;
+ 
+@@ -3637,6 +3635,14 @@ static ModeStatus SavageValidMode(SCRN_ARG_TYPE arg, 
DisplayModePtr pMode,
+        (pMode->VDisplay > psav->PanelY)))
+           return MODE_PANEL;
+ 
++    /* 11 bits of h_total 8-pixel units */
++    if (pMode->HTotal > (2048 << 3))
++      return MODE_BAD_HVALUE;
++
++    /* 11 bits of v_total */
++    if (pMode->VTotal > 2048)
++      return MODE_BAD_VVALUE;
++
+     if (psav->UseBIOS) {
+       refresh = SavageGetRefresh(pMode);
+         return (SavageMatchBiosMode(pScrn,pMode->HDisplay,
diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm
index f253d79..ba3b680 100644
--- a/gnu/packages/xorg.scm
+++ b/gnu/packages/xorg.scm
@@ -3214,6 +3214,7 @@ This driver is intended for ATI Rage 128 based cards.")
                "mirror://xorg/individual/driver/xf86-video-savage-"
                version
                ".tar.bz2"))
+        (patches (search-patches "xf86-video-savage-xorg-compat.patch"))
         (sha256
           (base32
            "11pcrsdpdrwk0mrgv83s5nsx8a9i4lhmivnal3fjbrvi3zdw94rc"))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]