You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
62 lines
1.7 KiB
62 lines
1.7 KiB
# --- SDE-COPYRIGHT-NOTE-BEGIN --- |
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
# |
|
# Filename: package/.../tuxkart/non-x86-ioperm.patch |
|
# Copyright (C) 2004 - 2006 The T2 SDE Project |
|
# |
|
# More information can be found in the files COPYING and README. |
|
# |
|
# This patch file is dual-licensed. It is available under the license the |
|
# patched project is licensed under, as long as it is an OpenSource license |
|
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms |
|
# of the GNU General Public License as published by the Free Software |
|
# Foundation; either version 2 of the License, or (at your option) any later |
|
# version. |
|
# --- SDE-COPYRIGHT-NOTE-END --- |
|
|
|
No (?) non-x86 has ioperm (the direct IO-Port access mechanism) - so |
|
we disable this (stereo shutter glass?) code. |
|
|
|
- Rene Rebe <rene@exactcode.de> |
|
|
|
--- tuxkart-0.2.0/src/gfx.cxx.orig 2001-11-10 00:32:52.000000000 +0100 |
|
+++ tuxkart-0.2.0/src/gfx.cxx 2003-11-22 11:08:12.000000000 +0100 |
|
@@ -4,9 +4,11 @@ |
|
#ifndef WIN32 |
|
#include <unistd.h> |
|
#include <string.h> |
|
+#ifdef __i386__ |
|
#include <sys/io.h> |
|
#include <sys/perm.h> |
|
#endif |
|
+#endif |
|
|
|
static unsigned int lastGLUTKeystroke = 0 ; |
|
|
|
@@ -197,6 +199,7 @@ |
|
return ; |
|
} |
|
|
|
+#ifdef __i386__ |
|
fprintf ( stderr, "Requesting control of parallel printer port...\n" ) ; |
|
|
|
int res = ioperm ( LPBASE, 8, 1 ) ; |
|
@@ -212,13 +215,18 @@ |
|
fprintf ( stderr, "Stereo Enabled!\n" ) ; |
|
stereo = -1 ; |
|
} |
|
+#else |
|
+ stereo = 0; |
|
+#endif |
|
} |
|
|
|
+#ifdef __i386__ |
|
if ( stereo != 0 ) |
|
{ |
|
outb ( (stereo==-1) ? ~3 : ~2, LPBASE+2 ) ; |
|
stereo = -stereo ; |
|
} |
|
+#endif |
|
} |
|
|
|
|
|
|