summaryrefslogtreecommitdiff
path: root/devel/sdl-devel
diff options
context:
space:
mode:
authorMaxim Sobolev <sobomax@FreeBSD.org>2001-01-27 21:22:21 +0000
committerMaxim Sobolev <sobomax@FreeBSD.org>2001-01-27 21:22:21 +0000
commit64ad20c2407be1af979ef11937f17f12dda2860b (patch)
tree7c15cb1e05e7c9a54a71b5d3f63b27dac31952e2 /devel/sdl-devel
parentMake vgl driver working OOB without the need to use custom patched version (diff)
Fix a rather nasty last-minute bug, which prevented SDL from using vesa modes
with bpp > 8.
Notes
Notes: svn path=/head/; revision=37653
Diffstat (limited to 'devel/sdl-devel')
-rw-r--r--devel/sdl-devel/files/patch-src_video_vgl_SDL__vglvideo.c20
1 files changed, 13 insertions, 7 deletions
diff --git a/devel/sdl-devel/files/patch-src_video_vgl_SDL__vglvideo.c b/devel/sdl-devel/files/patch-src_video_vgl_SDL__vglvideo.c
index 7a8f38ca46b4..e98aed5ce760 100644
--- a/devel/sdl-devel/files/patch-src_video_vgl_SDL__vglvideo.c
+++ b/devel/sdl-devel/files/patch-src_video_vgl_SDL__vglvideo.c
@@ -1,9 +1,9 @@
$FreeBSD$
---- src/video/vgl/SDL_vglvideo.c.orig Sat Jan 27 17:45:48 2001
-+++ src/video/vgl/SDL_vglvideo.c Sat Jan 27 18:13:31 2001
-@@ -0,0 +1,616 @@
+--- src/video/vgl/SDL_vglvideo.c.orig Sat Jan 27 22:36:17 2001
++++ src/video/vgl/SDL_vglvideo.c Sat Jan 27 23:14:47 2001
+@@ -0,0 +1,622 @@
+/*
+ SDL - Simple DirectMedia Layer
+ Copyright (C) 1997, 1998, 1999, 2000 Sam Lantinga
@@ -34,6 +34,8 @@ $FreeBSD$
+/* libvga based SDL video driver implementation.
+*/
+
++#include <err.h>
++#include <osreldate.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <unistd.h>
@@ -232,9 +234,13 @@ $FreeBSD$
+ }
+
+ /* Enable mouse and keyboard support */
-+ if (VGLKeyboardInit(VGL_CODEKEYS) != 0) {
-+ SDL_SetError("Unable to initialize keyboard");
-+ return -1;
++ if (getenv("SDL_NO_RAWKBD") == NULL) {
++ if (VGLKeyboardInit(VGL_CODEKEYS) != 0) {
++ SDL_SetError("Unable to initialize keyboard");
++ return -1;
++ }
++ } else {
++ warnx("Requiest to put keyboard into a raw mode ignored");
+ }
+ if (VGL_initkeymaps(STDIN_FILENO) != 0) {
+ SDL_SetError("Unable to initialize keymap");
@@ -537,7 +543,7 @@ $FreeBSD$
+ case V_INFO_MM_VGAX:
+ vminfop->Type = VIDBUF8X;
+ break;
-+#if __FreeBSD_version >= 500000
++#if defined(__FreeBSD_version) && __FreeBSD_version >= 500000
+ case V_INFO_MM_DIRECT:
+ vminfop->PixelBytes = minfo.vi_pixel_size;
+ switch (vminfop->PixelBytes) {