xf86-video-mga: fix build
This commit is contained in:
parent
32eaca579c
commit
9db50baf74
2 changed files with 58 additions and 7 deletions
57
srcpkgs/xf86-video-mga/patches/no-vbe-non-x86.patch
Normal file
57
srcpkgs/xf86-video-mga/patches/no-vbe-non-x86.patch
Normal file
|
@ -0,0 +1,57 @@
|
|||
From 30449dfac037faebac42ddb4bf809e94412512cc Mon Sep 17 00:00:00 2001
|
||||
From: Daniel Kolesa <daniel@octaforge.org>
|
||||
Date: Mon, 22 Feb 2021 21:08:26 +0100
|
||||
Subject: [PATCH] only attempt to use VBE on x86
|
||||
|
||||
---
|
||||
src/mga_driver.c | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git src/mga_driver.c src/mga_driver.c
|
||||
index 94183db..2aa0063 100644
|
||||
--- src/mga_driver.c
|
||||
+++ src/mga_driver.c
|
||||
@@ -77,7 +77,9 @@
|
||||
|
||||
#include "xf86DDC.h"
|
||||
|
||||
+#if defined(__i386__) || defined(__x86_64__)
|
||||
#include "vbe.h"
|
||||
+#endif
|
||||
|
||||
#include "fb.h"
|
||||
#include "dixstruct.h"
|
||||
@@ -1378,6 +1380,7 @@ MGAdoDDC(ScrnInfoPtr pScrn)
|
||||
pMga->ddc1Read ) ;
|
||||
from = "DDC1";
|
||||
}
|
||||
+#if defined(__i386__) || defined(__x86_64__)
|
||||
if (!MonInfo){
|
||||
vbeInfoPtr pVbe;
|
||||
if (xf86LoadSubModule(pScrn, "vbe")) {
|
||||
@@ -1387,6 +1390,7 @@ MGAdoDDC(ScrnInfoPtr pScrn)
|
||||
from = "VBE";
|
||||
}
|
||||
}
|
||||
+#endif
|
||||
}
|
||||
|
||||
if (MonInfo) {
|
||||
@@ -1418,12 +1422,14 @@ MGAdoDDC(ScrnInfoPtr pScrn)
|
||||
void
|
||||
MGAProbeDDC(ScrnInfoPtr pScrn, int index)
|
||||
{
|
||||
+#if defined(__i386__) || defined(__x86_64__)
|
||||
vbeInfoPtr pVbe;
|
||||
if (xf86LoadSubModule(pScrn, "vbe")) {
|
||||
pVbe = VBEInit(NULL,index);
|
||||
ConfiguredMonitor = vbeDoEDID(pVbe, NULL);
|
||||
vbeFree(pVbe);
|
||||
}
|
||||
+#endif
|
||||
}
|
||||
|
||||
Bool
|
||||
--
|
||||
2.30.1
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'xf86-video-mga'
|
||||
pkgname=xf86-video-mga
|
||||
version=2.0.0
|
||||
revision=1
|
||||
revision=2
|
||||
build_style=gnu-configure
|
||||
hostmakedepends="automake libtool pkg-config xorg-util-macros"
|
||||
makedepends="xorg-server-devel"
|
||||
|
@ -17,12 +17,6 @@ lib32disabled=yes
|
|||
LDFLAGS="-Wl,-z,lazy"
|
||||
|
||||
pre_configure() {
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
i686*|x86_64*|aarch64*|ppc*)
|
||||
sed -i 's/^DRI="no"/DRI="yes"/' configure.ac
|
||||
;;
|
||||
*) ;;
|
||||
esac
|
||||
autoreconf -if
|
||||
}
|
||||
post_install() {
|
||||
|
|
Loading…
Reference in a new issue