[Pkg-sdl-commits] [libsdl2] 03/05: fReview of patches: removal of old/invalid and not applied in SDL2 package, forwarding some upstream, documenting others, etc.
Manuel A. Fernandez Montecelo
mafm at alioth.debian.org
Sun Oct 20 00:05:49 UTC 2013
This is an automated email from the git hooks/post-receive script.
mafm pushed a commit to branch master
in repository libsdl2.
commit dfb938978b24d62974a6023d5d18c4cfc9cbe6fb
Author: Manuel A. Fernandez Montecelo <mafm at debian.org>
Date: Sat Oct 19 20:56:57 2013 +0100
fReview of patches: removal of old/invalid and not applied in SDL2 package, forwarding some upstream, documenting others, etc.
---
debian/changelog | 28 +
debian/patches/001_autogen_autotools_fix.diff | 43 --
debian/patches/020_libcaca_new_api.diff | 622 --------------------
debian/patches/030_pulseaudio_enable.diff | 40 --
debian/patches/040_propagate_pic_to_nasm.diff | 17 -
debian/patches/050_altivec_detection.diff | 120 ----
debian/patches/060_disable_ipod.diff | 37 --
debian/patches/205_lock_keys.diff | 64 --
debian/patches/205_x11_keysym_fix.diff | 21 -
debian/patches/206_gcc4_compilation_fix.diff | 24 -
debian/patches/209_alsa_priority.diff | 25 -
debian/patches/214_missing_mmx_blit.diff | 15 -
debian/patches/215_kfreebsd_gnu.diff | 71 ---
debian/patches/216_page_size.diff | 15 -
debian/patches/217_x11_keytounicode.diff | 33 --
debian/patches/218_double_free.diff | 22 -
debian/patches/218_joystick_memmove.diff | 15 -
debian/patches/219_pulseaudio_crackles.diff | 21 -
debian/patches/220_std_cld.diff | 14 -
.../221_check_SDL_NOKBD_environment_variable.diff | 60 --
debian/patches/222_joystick_crash.diff | 14 -
debian/patches/310_fixmouseclicks | 25 -
debian/patches/310_segfault_noGLX.diff | 16 -
debian/patches/320_activate_xrandr_on_default.diff | 22 -
debian/patches/320_disappearingcursor.diff | 17 -
debian/patches/series | 13 -
26 files changed, 28 insertions(+), 1386 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 989ad88..3dbe566 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,34 @@ libsdl2 (2.0.0+dfsg1-3) UNRELEASED; urgency=low
* Apply patch accepted upstream to work around a false-positive in the
X11 mouse wheel code (Closes: #723797). Thanks Darren Salt for the
report and the fix.
+ * Review and removal of old patches not applied in SDL2, virtually of
+ them applied upstream, or rejected as invalid for good reason, or
+ don't apply any more (code/functionality removed upstream). I
+ forwarded and documented the remaining patches.
+ - 001_autogen_autotools_fix.diff
+ - 020_libcaca_new_api.diff
+ - 030_pulseaudio_enable.diff
+ - 040_propagate_pic_to_nasm.diff
+ - 050_altivec_detection.diff
+ - 060_disable_ipod.diff
+ - 205_lock_keys.diff
+ - 205_x11_keysym_fix.diff
+ - 206_gcc4_compilation_fix.diff
+ - 209_alsa_priority.diff
+ - 214_missing_mmx_blit.diff
+ - 215_kfreebsd_gnu.diff
+ - 216_page_size.diff
+ - 217_x11_keytounicode.diff
+ - 218_double_free.diff
+ - 218_joystick_memmove.diff
+ - 219_pulseaudio_crackles.diff
+ - 220_std_cld.diff
+ - 221_check_SDL_NOKBD_environment_variable.diff
+ - 222_joystick_crash.diff
+ - 310_fixmouseclicks
+ - 310_segfault_noGLX.diff
+ - 320_activate_xrandr_on_default.diff
+ - 320_disappearingcursor.diff
-- Manuel A. Fernandez Montecelo <mafm at debian.org> Fri, 18 Oct 2013 22:00:37 +0100
diff --git a/debian/patches/001_autogen_autotools_fix.diff b/debian/patches/001_autogen_autotools_fix.diff
deleted file mode 100644
index 24ee2be..0000000
--- a/debian/patches/001_autogen_autotools_fix.diff
+++ /dev/null
@@ -1,43 +0,0 @@
----
- autogen.sh | 12 +++---------
- test/autogen.sh | 11 ++---------
- 2 files changed, 5 insertions(+), 18 deletions(-)
-
---- a/autogen.sh
-+++ b/autogen.sh
-@@ -4,15 +4,9 @@
- echo "This may take a while ..."
-
- # Regenerate configuration files
--cp acinclude.m4 aclocal.m4
--found=false
--for autoconf in autoconf autoconf259 autoconf-2.59
--do if which $autoconf >/dev/null 2>&1; then $autoconf && found=true; break; fi
--done
--if test x$found = xfalse; then
-- echo "Couldn't find autoconf, aborting"
-- exit 1
--fi
-+aclocal-1.9
-+autoconf
-+autoheader
- (cd test; sh autogen.sh)
-
- # Run configure for this platform
---- a/test/autogen.sh
-+++ b/test/autogen.sh
-@@ -1,12 +1,5 @@
- #!/bin/sh
- #
- # Regenerate configuration files
--cp acinclude.m4 aclocal.m4
--found=false
--for autoconf in autoconf autoconf259 autoconf-2.59
--do if which $autoconf >/dev/null 2>&1; then $autoconf && found=true; break; fi
--done
--if test x$found = xfalse; then
-- echo "Couldn't find autoconf, aborting"
-- exit 1
--fi
-+aclocal-1.9
-+autoconf
diff --git a/debian/patches/020_libcaca_new_api.diff b/debian/patches/020_libcaca_new_api.diff
deleted file mode 100644
index 0decfba..0000000
--- a/debian/patches/020_libcaca_new_api.diff
+++ /dev/null
@@ -1,622 +0,0 @@
----
- configure.in | 33 ++++
- include/SDL_config.h.in | 1
- src/video/SDL_sysvideo.h | 3
- src/video/SDL_video.c | 3
- src/video/caca/SDL_cacaevents.c | 101 ++++++++++++
- src/video/caca/SDL_cacaevents_c.h | 35 ++++
- src/video/caca/SDL_cacavideo.c | 304 ++++++++++++++++++++++++++++++++++++++
- src/video/caca/SDL_cacavideo.h | 76 +++++++++
- 8 files changed, 556 insertions(+)
-
---- a/configure.in
-+++ b/configure.in
-@@ -1437,6 +1437,38 @@
- fi
- }
-
-+dnl Find the libcaca includes
-+CheckCaca()
-+{
-+ AC_ARG_ENABLE(video-caca,
-+AC_HELP_STRING([--enable-video-caca], [use libcaca video driver [[default=no]]]),
-+ , enable_video_caca=no)
-+ if test x$enable_video = xyes -a x$enable_video_caca = xyes; then
-+ video_caca=no
-+ AC_PATH_PROG(CACACONFIG, caca-config, no)
-+ if test x$CACACONFIG != xno; then
-+ AC_MSG_CHECKING(for libcaca support)
-+ CACA_CFLAGS=`$CACACONFIG --cflags`
-+ CACA_LDFLAGS=`$CACACONFIG --libs`
-+ save_CFLAGS="$CFLAGS"
-+ AC_TRY_COMPILE([
-+ #include <caca.h>
-+ ],[
-+ ],[
-+ video_caca=yes
-+ ])
-+ CFLAGS="$save_CFLAGS"
-+ AC_MSG_RESULT($video_caca)
-+ if test x$video_caca = xyes; then
-+ AC_DEFINE(SDL_VIDEO_DRIVER_CACA)
-+ EXTRA_CFLAGS="$EXTRA_CFLAGS $CACA_CFLAGS"
-+ EXTRA_LDFLAGS="$EXTRA_LDFLAGS $CACA_LDFLAGS"
-+ SOURCES="$SOURCES $srcdir/src/video/caca/*.c"
-+ fi
-+ fi
-+ fi
-+}
-+
- dnl Set up the QTopia video driver if enabled
- CheckQtopia()
- {
-@@ -2258,6 +2290,7 @@
- CheckVGL
- CheckWscons
- CheckAAlib
-+ CheckCaca
- CheckQtopia
- CheckPicoGUI
- CheckOpenGLX11
---- a/src/video/SDL_video.c
-+++ b/src/video/SDL_video.c
-@@ -120,6 +120,9 @@
- #if SDL_VIDEO_DRIVER_AALIB
- &AALIB_bootstrap,
- #endif
-+#if SDL_VIDEO_DRIVER_CACA
-+ &CACA_bootstrap,
-+#endif
- #if SDL_VIDEO_DRIVER_DUMMY
- &DUMMY_bootstrap,
- #endif
---- a/src/video/SDL_sysvideo.h
-+++ b/src/video/SDL_sysvideo.h
-@@ -404,6 +404,9 @@
- #if SDL_VIDEO_DRIVER_AALIB
- extern VideoBootStrap AALIB_bootstrap;
- #endif
-+#if SDL_VIDEO_DRIVER_CACA
-+extern VideoBootStrap CACA_bootstrap;
-+#endif
- #if SDL_VIDEO_DRIVER_DUMMY
- extern VideoBootStrap DUMMY_bootstrap;
- #endif
---- /dev/null
-+++ b/src/video/caca/SDL_cacaevents_c.h
-@@ -0,0 +1,35 @@
-+/*
-+ SDL - Simple DirectMedia Layer
-+ Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga
-+
-+ This library is free software; you can redistribute it and/or
-+ modify it under the terms of the GNU Library General Public
-+ License as published by the Free Software Foundation; either
-+ version 2 of the License, or (at your option) any later version.
-+
-+ This library is distributed in the hope that it will be useful,
-+ but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ Library General Public License for more details.
-+
-+ You should have received a copy of the GNU Library General Public
-+ License along with this library; if not, write to the Free
-+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-+
-+ Sam Lantinga
-+ slouken at libsdl.org
-+*/
-+
-+#ifdef SAVE_RCSID
-+static char rcsid =
-+ "@(#) $Id: libsdl-1.2.11-libcaca.patch,v 1.1 2006/09/18 16:06:06 mr_bones_ Exp $";
-+#endif
-+
-+#include "SDL_cacavideo.h"
-+
-+/* Variables and functions exported by SDL_sysevents.c to other parts.
-+ of the native video subsystem (SDL_sysvideo.c)
-+*/
-+extern void Caca_PumpEvents(_THIS);
-+extern void Caca_InitOSKeymap(_THIS);
-+
---- /dev/null
-+++ b/src/video/caca/SDL_cacaevents.c
-@@ -0,0 +1,101 @@
-+/*
-+ SDL - Simple DirectMedia Layer
-+ Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga
-+
-+ This library is free software; you can redistribute it and/or
-+ modify it under the terms of the GNU Library General Public
-+ License as published by the Free Software Foundation; either
-+ version 2 of the License, or (at your option) any later version.
-+
-+ This library is distributed in the hope that it will be useful,
-+ but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ Library General Public License for more details.
-+
-+ You should have received a copy of the GNU Library General Public
-+ License along with this library; if not, write to the Free
-+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-+
-+ Sam Lantinga
-+ slouken at libsdl.org
-+*/
-+
-+#ifdef SAVE_RCSID
-+static char rcsid =
-+ "@(#) $Id: libsdl-1.2.11-libcaca.patch,v 1.1 2006/09/18 16:06:06 mr_bones_ Exp $";
-+#endif
-+
-+#include <stdio.h>
-+
-+#include <caca.h>
-+#ifdef CACA_API_VERSION_1
-+#include <caca0.h>
-+#endif
-+
-+#include "SDL.h"
-+#include "../../events/SDL_sysevents.h"
-+#include "../../events/SDL_events_c.h"
-+#include "SDL_cacavideo.h"
-+#include "SDL_cacaevents_c.h"
-+
-+void Caca_PumpEvents(_THIS)
-+{
-+ int posted = 0;
-+ int event;
-+ SDL_keysym keysym;
-+
-+ if( ! this->screen ) /* Wait till we got the screen initialised */
-+ return;
-+
-+ do {
-+ posted = 0;
-+
-+ /* Get libcaca event */
-+ SDL_mutexP(Caca_mutex);
-+ event = caca_get_event(CACA_EVENT_ANY);
-+ SDL_mutexV(Caca_mutex);
-+
-+ if ( event & (CACA_EVENT_KEY_PRESS | CACA_EVENT_KEY_RELEASE)) {
-+ int key;
-+ switch ( event & 0xffffff )
-+ {
-+ case CACA_KEY_LEFT: key = SDLK_LEFT; break;
-+ case CACA_KEY_RIGHT: key = SDLK_RIGHT; break;
-+ case CACA_KEY_UP: key = SDLK_UP; break;
-+ case CACA_KEY_DOWN: key = SDLK_DOWN; break;
-+ default: key = event & 0xff; break;
-+ }
-+ /* Key pressed */
-+/* printf("Key pressed: %d (%c)\n", key, key); */
-+ keysym.scancode = key;
-+ keysym.sym = key;
-+ keysym.mod = KMOD_NONE;
-+ keysym.unicode = 0;
-+ if ( SDL_TranslateUNICODE ) {
-+ keysym.unicode = key;
-+ }
-+ posted += SDL_PrivateKeyboard((event & CACA_EVENT_KEY_PRESS) ? SDL_PRESSED : SDL_RELEASED, &keysym);
-+ }
-+ else if ( event & (CACA_EVENT_MOUSE_PRESS | CACA_EVENT_MOUSE_RELEASE) ) {
-+ /* FIXME: we currently ignore the button type! */
-+ int button = event & 0x00ffffff;
-+ if ( button > 3 ) {
-+ button = 1;
-+ }
-+ posted += SDL_PrivateMouseButton((event & CACA_EVENT_MOUSE_PRESS) ? SDL_PRESSED : SDL_RELEASED, button, 0, 0);
-+ }
-+ else if ( event & CACA_EVENT_MOUSE_MOTION ) {
-+ int new_x = 0, new_y = 0;
-+ new_x = ((event & 0x00fff000) >> 12) * Caca_w / caca_get_width();
-+ new_y = ((event & 0x00000fff) >> 0) * Caca_h / caca_get_height();
-+ posted += SDL_PrivateMouseMotion(0, 0, new_x, new_y);
-+ }
-+ } while ( posted );
-+}
-+
-+void Caca_InitOSKeymap(_THIS)
-+{
-+ return;
-+}
-+
-+
---- /dev/null
-+++ b/src/video/caca/SDL_cacavideo.h
-@@ -0,0 +1,76 @@
-+/*
-+ SDL - Simple DirectMedia Layer
-+ Copyright (C) 2003 Sam Hocevar
-+
-+ This library is free software; you can redistribute it and/or
-+ modify it under the terms of the GNU Library General Public
-+ License as published by the Free Software Foundation; either
-+ version 2 of the License, or (at your option) any later version.
-+
-+ This library is distributed in the hope that it will be useful,
-+ but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ Library General Public License for more details.
-+
-+ You should have received a copy of the GNU Library General Public
-+ License along with this library; if not, write to the Free
-+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-+
-+ Sam Hocevar
-+ sam at zoy.org
-+*/
-+
-+#ifdef SAVE_RCSID
-+static char rcsid =
-+ "@(#) $Id: libsdl-1.2.11-libcaca.patch,v 1.1 2006/09/18 16:06:06 mr_bones_ Exp $";
-+#endif
-+
-+#ifndef _SDL_cacavideo_h
-+#define _SDL_cacavideo_h
-+
-+#include "SDL_mouse.h"
-+#include "../SDL_sysvideo.h"
-+#include "SDL_mutex.h"
-+
-+#include <sys/time.h>
-+#include <time.h>
-+
-+#include <caca.h>
-+#ifdef CACA_API_VERSION_1
-+#include <caca0.h>
-+#endif
-+
-+/* Hidden "this" pointer for the video functions */
-+#define _THIS SDL_VideoDevice *this
-+
-+#define SDL_NUMMODES 6
-+
-+/* Private display data */
-+struct SDL_PrivateVideoData {
-+ SDL_Rect *SDL_modelist[SDL_NUMMODES+1];
-+ SDL_mutex *mutex;
-+
-+ struct caca_bitmap *bitmap;
-+ void *buffer;
-+ int w, h;
-+
-+ int lastkey;
-+ struct timeval lasttime;
-+};
-+
-+/* Old variable names */
-+#define SDL_modelist (this->hidden->SDL_modelist)
-+#define Caca_palette (this->hidden->palette)
-+#define Caca_bitmap (this->hidden->bitmap)
-+#define Caca_buffer (this->hidden->buffer)
-+
-+#define Caca_w (this->hidden->w)
-+#define Caca_h (this->hidden->h)
-+
-+#define Caca_lastkey (this->hidden->lastkey)
-+#define Caca_lasttime (this->hidden->lasttime)
-+
-+#define Caca_mutex (this->hidden->mutex)
-+
-+#endif /* _SDL_cacavideo_h */
-+
---- /dev/null
-+++ b/src/video/caca/SDL_cacavideo.c
-@@ -0,0 +1,304 @@
-+/*
-+ SDL - Simple DirectMedia Layer
-+ Copyright (C) 2003 Sam Hocevar
-+
-+ This library is free software; you can redistribute it and/or
-+ modify it under the terms of the GNU Library General Public
-+ License as published by the Free Software Foundation; either
-+ version 2 of the License, or (at your option) any later version.
-+
-+ This library is distributed in the hope that it will be useful,
-+ but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ Library General Public License for more details.
-+
-+ You should have received a copy of the GNU Library General Public
-+ License along with this library; if not, write to the Free
-+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-+
-+ Sam Hocevar
-+ sam at zoy.org
-+*/
-+
-+#ifdef SAVE_RCSID
-+static char rcsid =
-+ "@(#) $Id: libsdl-1.2.11-libcaca.patch,v 1.1 2006/09/18 16:06:06 mr_bones_ Exp $";
-+#endif
-+
-+/* libcaca based SDL video driver implementation.
-+*/
-+
-+#include <stdlib.h>
-+#include <stdio.h>
-+#include <string.h>
-+#include <unistd.h>
-+#include <sys/stat.h>
-+
-+
-+#include "SDL.h"
-+#include "SDL_error.h"
-+#include "SDL_video.h"
-+#include "SDL_mouse.h"
-+#include "../SDL_sysvideo.h"
-+#include "../SDL_pixels_c.h"
-+#include "../../events/SDL_events_c.h"
-+
-+#include "SDL_cacavideo.h"
-+#include "SDL_cacaevents_c.h"
-+
-+#include <caca.h>
-+#ifdef CACA_API_VERSION_1
-+#include <caca0.h>
-+#endif
-+
-+/* Initialization/Query functions */
-+static int Caca_VideoInit(_THIS, SDL_PixelFormat *vformat);
-+static SDL_Rect **Caca_ListModes(_THIS, SDL_PixelFormat *format, Uint32 flags);
-+static SDL_Surface *Caca_SetVideoMode(_THIS, SDL_Surface *current, int width, int height, int bpp, Uint32 flags);
-+static void Caca_VideoQuit(_THIS);
-+
-+/* Hardware surface functions */
-+static int Caca_AllocHWSurface(_THIS, SDL_Surface *surface);
-+static int Caca_LockHWSurface(_THIS, SDL_Surface *surface);
-+static int Caca_FlipHWSurface(_THIS, SDL_Surface *surface);
-+static void Caca_UnlockHWSurface(_THIS, SDL_Surface *surface);
-+static void Caca_FreeHWSurface(_THIS, SDL_Surface *surface);
-+
-+/* Cache the VideoDevice struct */
-+static struct SDL_VideoDevice *local_this;
-+
-+/* libcaca driver bootstrap functions */
-+
-+static int Caca_Available(void)
-+{
-+ return 1; /* Always available ! */
-+}
-+
-+static void Caca_DeleteDevice(SDL_VideoDevice *device)
-+{
-+ free(device->hidden);
-+ free(device);
-+}
-+static SDL_VideoDevice *Caca_CreateDevice(int devindex)
-+{
-+ SDL_VideoDevice *device;
-+
-+ /* Initialize all variables that we clean on shutdown */
-+ device = (SDL_VideoDevice *)malloc(sizeof(SDL_VideoDevice));
-+ if ( device ) {
-+ memset(device, 0, (sizeof *device));
-+ device->hidden = (struct SDL_PrivateVideoData *)
-+ malloc((sizeof *device->hidden));
-+ }
-+ if ( (device == NULL) || (device->hidden == NULL) ) {
-+ SDL_OutOfMemory();
-+ if ( device ) {
-+ free(device);
-+ }
-+ return(0);
-+ }
-+ memset(device->hidden, 0, (sizeof *device->hidden));
-+
-+ /* Set the function pointers */
-+ device->VideoInit = Caca_VideoInit;
-+ device->ListModes = Caca_ListModes;
-+ device->SetVideoMode = Caca_SetVideoMode;
-+ device->CreateYUVOverlay = NULL;
-+ device->SetColors = NULL;
-+ device->UpdateRects = NULL;
-+ device->VideoQuit = Caca_VideoQuit;
-+ device->AllocHWSurface = Caca_AllocHWSurface;
-+ device->CheckHWBlit = NULL;
-+ device->FillHWRect = NULL;
-+ device->SetHWColorKey = NULL;
-+ device->SetHWAlpha = NULL;
-+ device->LockHWSurface = Caca_LockHWSurface;
-+ device->UnlockHWSurface = Caca_UnlockHWSurface;
-+ device->FlipHWSurface = NULL;
-+ device->FreeHWSurface = Caca_FreeHWSurface;
-+ device->SetCaption = NULL;
-+ device->SetIcon = NULL;
-+ device->IconifyWindow = NULL;
-+ device->GrabInput = NULL;
-+ device->GetWMInfo = NULL;
-+ device->InitOSKeymap = Caca_InitOSKeymap;
-+ device->PumpEvents = Caca_PumpEvents;
-+
-+ device->free = Caca_DeleteDevice;
-+
-+ return device;
-+}
-+
-+VideoBootStrap CACA_bootstrap = {
-+ "caca", "Color ASCII Art Library",
-+ Caca_Available, Caca_CreateDevice
-+};
-+
-+int Caca_VideoInit(_THIS, SDL_PixelFormat *vformat)
-+{
-+ int i;
-+
-+ /* Initialize all variables that we clean on shutdown */
-+ for ( i=0; i<SDL_NUMMODES; ++i ) {
-+ SDL_modelist[i] = malloc(sizeof(SDL_Rect));
-+ SDL_modelist[i]->x = SDL_modelist[i]->y = 0;
-+ }
-+ /* Modes sorted largest to smallest */
-+ SDL_modelist[0]->w = 1024; SDL_modelist[0]->h = 768;
-+ SDL_modelist[1]->w = 800; SDL_modelist[1]->h = 600;
-+ SDL_modelist[2]->w = 640; SDL_modelist[2]->h = 480;
-+ SDL_modelist[3]->w = 320; SDL_modelist[3]->h = 400;
-+ SDL_modelist[4]->w = 320; SDL_modelist[4]->h = 240;
-+ SDL_modelist[5]->w = 320; SDL_modelist[5]->h = 200;
-+ SDL_modelist[6] = NULL;
-+
-+ Caca_mutex = SDL_CreateMutex();
-+
-+ /* Initialize the library */
-+ if ( caca_init() != 0 ) {
-+ SDL_SetError("Unable to initialize libcaca");
-+ return(-1);
-+ }
-+
-+ /* Initialize private variables */
-+ Caca_lastkey = 0;
-+ Caca_bitmap = NULL;
-+ Caca_buffer = NULL;
-+
-+ local_this = this;
-+
-+ /* Determine the screen depth (use default 8-bit depth) */
-+ vformat->BitsPerPixel = 8;
-+ vformat->BytesPerPixel = 1;
-+
-+ /* We're done! */
-+ return(0);
-+}
-+
-+SDL_Rect **Caca_ListModes(_THIS, SDL_PixelFormat *format, Uint32 flags)
-+{
-+ if(format->BitsPerPixel != 8)
-+ return NULL;
-+
-+ if ( flags & SDL_FULLSCREEN ) {
-+ return SDL_modelist;
-+ } else {
-+ return (SDL_Rect **) -1;
-+ }
-+}
-+
-+/* Various screen update functions available */
-+static void Caca_DirectUpdate(_THIS, int numrects, SDL_Rect *rects);
-+
-+SDL_Surface *Caca_SetVideoMode(_THIS, SDL_Surface *current,
-+ int width, int height, int bpp, Uint32 flags)
-+{
-+ if ( Caca_buffer ) {
-+ free( Caca_buffer );
-+ Caca_buffer = NULL;
-+ }
-+
-+ if ( Caca_bitmap ) {
-+ caca_free_bitmap( Caca_bitmap );
-+ Caca_bitmap = NULL;
-+ }
-+
-+ Caca_buffer = malloc(2 * ((width + 15) & ~15) * height);
-+ if ( ! Caca_buffer ) {
-+ SDL_SetError("Couldn't allocate buffer for requested mode");
-+ return(NULL);
-+ }
-+
-+ memset(Caca_buffer, 0, 2 * ((width + 15) & ~15) * height);
-+
-+ /* Allocate the new pixel format for the screen */
-+ if ( ! SDL_ReallocFormat(current, 16, 0xf800, 0x07e0, 0x001f, 0) ) {
-+ return(NULL);
-+ }
-+
-+ /* Set up the new mode framebuffer */
-+ current->flags = SDL_FULLSCREEN;
-+ Caca_w = current->w = width;
-+ Caca_h = current->h = height;
-+ current->pitch = 2 * ((width + 15) & ~15);
-+ current->pixels = Caca_buffer;
-+
-+ /* Create the libcaca bitmap */
-+ Caca_bitmap = caca_create_bitmap( 16, width, height, current->pitch, 0xf800, 0x07e0, 0x001f, 0x0000 );
-+ if ( ! Caca_bitmap ) {
-+ SDL_SetError("Couldn't allocate libcaca bitmap");
-+ return(NULL);
-+ }
-+
-+ /* Set the blit function */
-+ this->UpdateRects = Caca_DirectUpdate;
-+
-+ /* We're done */
-+ return(current);
-+}
-+
-+/* We don't actually allow hardware surfaces other than the main one */
-+static int Caca_AllocHWSurface(_THIS, SDL_Surface *surface)
-+{
-+ return(-1);
-+}
-+static void Caca_FreeHWSurface(_THIS, SDL_Surface *surface)
-+{
-+ return;
-+}
-+
-+/* We need to wait for vertical retrace on page flipped displays */
-+static int Caca_LockHWSurface(_THIS, SDL_Surface *surface)
-+{
-+ /* TODO ? */
-+ return(0);
-+}
-+static void Caca_UnlockHWSurface(_THIS, SDL_Surface *surface)
-+{
-+ return;
-+}
-+
-+/* FIXME: How is this done with libcaca? */
-+static int Caca_FlipHWSurface(_THIS, SDL_Surface *surface)
-+{
-+ SDL_mutexP(Caca_mutex);
-+ caca_refresh();
-+ SDL_mutexV(Caca_mutex);
-+ return(0);
-+}
-+
-+static void Caca_DirectUpdate(_THIS, int numrects, SDL_Rect *rects)
-+{
-+ SDL_mutexP(Caca_mutex);
-+ caca_draw_bitmap( 0, 0, caca_get_width() - 1, caca_get_height() - 1,
-+ Caca_bitmap, Caca_buffer );
-+ caca_refresh();
-+ SDL_mutexV(Caca_mutex);
-+ return;
-+}
-+
-+/* Note: If we are terminated, this could be called in the middle of
-+ another SDL video routine -- notably UpdateRects.
-+*/
-+void Caca_VideoQuit(_THIS)
-+{
-+ int i;
-+
-+ /* Free video mode lists */
-+ for ( i=0; i<SDL_NUMMODES; ++i ) {
-+ if ( SDL_modelist[i] != NULL ) {
-+ free(SDL_modelist[i]);
-+ SDL_modelist[i] = NULL;
-+ }
-+ }
-+
-+ if ( Caca_bitmap ) {
-+ caca_free_bitmap( Caca_bitmap );
-+ Caca_bitmap = NULL;
-+ }
-+
-+ caca_end();
-+
-+ SDL_DestroyMutex(Caca_mutex);
-+}
-+
---- a/include/SDL_config.h.in
-+++ b/include/SDL_config.h.in
-@@ -253,6 +253,7 @@
- /* Enable various video drivers */
- #undef SDL_VIDEO_DRIVER_AALIB
- #undef SDL_VIDEO_DRIVER_BWINDOW
-+#undef SDL_VIDEO_DRIVER_CACA
- #undef SDL_VIDEO_DRIVER_DC
- #undef SDL_VIDEO_DRIVER_DDRAW
- #undef SDL_VIDEO_DRIVER_DGA
diff --git a/debian/patches/030_pulseaudio_enable.diff b/debian/patches/030_pulseaudio_enable.diff
deleted file mode 100644
index 189e091..0000000
--- a/debian/patches/030_pulseaudio_enable.diff
+++ /dev/null
@@ -1,40 +0,0 @@
----
- configure.in | 10 +++++-----
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
---- a/configure.in
-+++ b/configure.in
-@@ -479,8 +479,8 @@
- {
- AC_ARG_ENABLE(pulseaudio,
- AC_HELP_STRING([--enable-pulseaudio], [use PulseAudio [[default=yes]]]),
-- , enable_pulse=yes)
-- if test x$enable_audio = xyes -a x$enable_pulse = xyes; then
-+ , enable_pulseaudio=yes)
-+ if test x$enable_audio = xyes -a x$enable_pulseaudio = xyes; then
- audio_pulse=no
-
- PULSE_REQUIRED_VERSION=0.9
-@@ -499,7 +499,7 @@
- if test x$audio_pulse = xyes; then
- AC_ARG_ENABLE(pulseaudio-shared,
- AC_HELP_STRING([--enable-pulseaudio-shared], [dynamically load PulseAudio support [[default=yes]]]),
-- , enable_pulse_shared=yes)
-+ , enable_pulseaudio_shared=yes)
- if test "x`echo $PULSE_LIBS | grep -- -L`" = "x"; then
- if test "x`ls /lib/libpulse-simple.so.* 2> /dev/null`" != "x"; then
- PULSE_LIBS="-L/lib $PULSE_LIBS"
-@@ -517,11 +517,11 @@
- SOURCES="$SOURCES $srcdir/src/audio/pulse/*.c"
- EXTRA_CFLAGS="$EXTRA_CFLAGS $PULSE_CFLAGS"
- if test x$have_loadso != xyes && \
-- test x$enable_pulse_shared = xyes; then
-+ test x$enable_pulseaudio_shared = xyes; then
- AC_MSG_WARN([You must have SDL_LoadObject() support for dynamic PulseAudio loading])
- fi
- if test x$have_loadso = xyes && \
-- test x$enable_pulse_shared = xyes && test x$pulse_lib != x; then
-+ test x$enable_pulseaudio_shared = xyes && test x$pulse_lib != x; then
- AC_DEFINE_UNQUOTED(SDL_AUDIO_DRIVER_PULSE_DYNAMIC, "$pulse_lib")
- else
- EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PULSE_LIBS"
diff --git a/debian/patches/040_propagate_pic_to_nasm.diff b/debian/patches/040_propagate_pic_to_nasm.diff
deleted file mode 100644
index c54e9bf..0000000
--- a/debian/patches/040_propagate_pic_to_nasm.diff
+++ /dev/null
@@ -1,17 +0,0 @@
----
- build-scripts/strip_fPIC.sh | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
---- a/build-scripts/strip_fPIC.sh
-+++ b/build-scripts/strip_fPIC.sh
-@@ -5,8 +5,8 @@
- command=""
- while [ $# -gt 0 ]; do
- case "$1" in
-- -?PIC)
-- # Ignore -fPIC and -DPIC options
-+ -fPIC)
-+ # Ignore -fPIC option
- ;;
- -fno-common)
- # Ignore -fPIC and -DPIC options
diff --git a/debian/patches/050_altivec_detection.diff b/debian/patches/050_altivec_detection.diff
deleted file mode 100644
index eff270d..0000000
--- a/debian/patches/050_altivec_detection.diff
+++ /dev/null
@@ -1,120 +0,0 @@
-Index: libsdl1.2-1.2.13/configure.in
-===================================================================
---- libsdl1.2-1.2.13.orig/configure.in 2008-10-21 16:19:05.000000000 +0200
-+++ libsdl1.2-1.2.13/configure.in 2008-10-21 16:27:11.000000000 +0200
-@@ -749,64 +749,66 @@
- AC_HELP_STRING([--enable-altivec], [use altivec assembly blitters on PPC [[default=yes]]]),
- , enable_altivec=yes)
- if test x$enable_video = xyes -a x$enable_assembly = xyes -a x$enable_altivec = xyes; then
-- have_altivec_h_hdr=no
-- AC_CHECK_HEADER(altivec.h, have_altivec_h_hdr=yes)
--
- save_CFLAGS="$CFLAGS"
- have_gcc_altivec=no
-- AC_MSG_CHECKING(for Altivec with GCC -maltivec option)
-+ have_altivec_h_hdr=no
- altivec_CFLAGS="-maltivec"
- CFLAGS="$save_CFLAGS $altivec_CFLAGS"
-
-- if test x$have_altivec_h_hdr = xyes; then
-- AC_TRY_COMPILE([
-- #include <altivec.h>
-- vector unsigned int vzero() {
-- return vec_splat_u32(0);
-- }
-- ],[
-- ],[
-- have_gcc_altivec=yes
-- ])
-- AC_MSG_RESULT($have_gcc_altivec)
-- else
-- AC_TRY_COMPILE([
-- vector unsigned int vzero() {
-- return vec_splat_u32(0);
-- }
-- ],[
-- ],[
-- have_gcc_altivec=yes
-- ])
-- AC_MSG_RESULT($have_gcc_altivec)
-+ AC_MSG_CHECKING(for Altivec with GCC altivec.h and -maltivec option)
-+ AC_TRY_COMPILE([
-+ #include <altivec.h>
-+ vector unsigned int vzero() {
-+ return vec_splat_u32(0);
-+ }
-+ ],[
-+ ],[
-+ have_gcc_altivec=yes
-+ have_altivec_h_hdr=yes
-+ ])
-+ AC_MSG_RESULT($have_gcc_altivec)
-+
-+ if test x$have_gcc_altivec = xno; then
-+ AC_MSG_CHECKING(for Altivec with GCC -maltivec option)
-+ AC_TRY_COMPILE([
-+ vector unsigned int vzero() {
-+ return vec_splat_u32(0);
-+ }
-+ ],[
-+ ],[
-+ have_gcc_altivec=yes
-+ ])
-+ AC_MSG_RESULT($have_gcc_altivec)
- fi
-
- if test x$have_gcc_altivec = xno; then
-- AC_MSG_CHECKING(for Altivec with GCC -faltivec option)
-+ AC_MSG_CHECKING(for Altivec with GCC altivec.h and -faltivec option)
- altivec_CFLAGS="-faltivec"
- CFLAGS="$save_CFLAGS $altivec_CFLAGS"
-- if test x$have_altivec_h_hdr = xyes; then
-- AC_TRY_COMPILE([
-- #include <altivec.h>
-- vector unsigned int vzero() {
-- return vec_splat_u32(0);
-- }
-- ],[
-- ],[
-- have_gcc_altivec=yes
-- ])
-- AC_MSG_RESULT($have_gcc_altivec)
-- else
-- AC_TRY_COMPILE([
-- vector unsigned int vzero() {
-- return vec_splat_u32(0);
-- }
-- ],[
-- ],[
-- have_gcc_altivec=yes
-- ])
-- AC_MSG_RESULT($have_gcc_altivec)
-- fi
-+ AC_TRY_COMPILE([
-+ #include <altivec.h>
-+ vector unsigned int vzero() {
-+ return vec_splat_u32(0);
-+ }
-+ ],[
-+ ],[
-+ have_gcc_altivec=yes
-+ have_altivec_h_hdr=yes
-+ ])
-+ AC_MSG_RESULT($have_gcc_altivec)
-+ fi
-+
-+ if test x$have_gcc_altivec = xno; then
-+ AC_MSG_CHECKING(for Altivec with GCC -faltivec option)
-+ AC_TRY_COMPILE([
-+ vector unsigned int vzero() {
-+ return vec_splat_u32(0);
-+ }
-+ ],[
-+ ],[
-+ have_gcc_altivec=yes
-+ ])
-+ AC_MSG_RESULT($have_gcc_altivec)
- fi
- CFLAGS="$save_CFLAGS"
-
-
diff --git a/debian/patches/060_disable_ipod.diff b/debian/patches/060_disable_ipod.diff
deleted file mode 100644
index de5a7e8..0000000
--- a/debian/patches/060_disable_ipod.diff
+++ /dev/null
@@ -1,37 +0,0 @@
-Index: SDL-1.2.14/configure.in
-===================================================================
---- SDL-1.2.14.orig/configure.in 2009-11-27 15:01:50.000000000 -0500
-+++ SDL-1.2.14/configure.in 2009-11-27 15:01:50.000000000 -0500
-@@ -882,19 +882,19 @@
- }
-
-
--dnl Do the iPod thing
--CheckIPod()
--{
-- AC_ARG_ENABLE(ipod,
--AC_HELP_STRING([--enable-ipod], [configure SDL to work with iPodLinux [[default=no]]]),
-- , enable_ipod=no)
--
-- if test x$enable_ipod = xyes; then
-- EXTRA_CFLAGS="$EXTRA_CFLAGS -DIPOD"
-- AC_DEFINE(SDL_VIDEO_DRIVER_IPOD)
-- SOURCES="$SOURCES $srcdir/src/video/ipod/*.c"
-- fi
--}
-+#dnl Do the iPod thing
-+#CheckIPod()
-+#{
-+# AC_ARG_ENABLE(ipod,
-+#AC_HELP_STRING([--enable-ipod], [configure SDL to work with iPodLinux [[default=no]]]),
-+# , enable_ipod=no)
-+#
-+# if test x$enable_ipod = xyes; then
-+# EXTRA_CFLAGS="$EXTRA_CFLAGS -DIPOD"
-+# AC_DEFINE(SDL_VIDEO_DRIVER_IPOD)
-+# SOURCES="$SOURCES $srcdir/src/video/ipod/*.c"
-+# fi
-+#}
-
- dnl Find the nanox include and library directories
- CheckNANOX()
diff --git a/debian/patches/205_lock_keys.diff b/debian/patches/205_lock_keys.diff
deleted file mode 100644
index 2c33fcd..0000000
--- a/debian/patches/205_lock_keys.diff
+++ /dev/null
@@ -1,64 +0,0 @@
----
- src/events/SDL_keyboard.c | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
---- a/src/events/SDL_keyboard.c
-+++ b/src/events/SDL_keyboard.c
-@@ -32,6 +32,7 @@
- /* Global keystate information */
- static Uint8 SDL_KeyState[SDLK_LAST];
- static SDLMod SDL_ModState;
-+static char *SDL_UseLockKeys;
- int SDL_TranslateUNICODE = 0;
-
- static const char *keynames[SDLK_LAST]; /* Array of keycode names */
-@@ -64,6 +65,7 @@
- video->InitOSKeymap(this);
-
- SDL_EnableKeyRepeat(0, 0);
-+ SDL_UseLockKeys = getenv("SDL_DISABLE_LOCK_KEYS");
-
- /* Fill in the blanks in keynames */
- keynames[SDLK_BACKSPACE] = "backspace";
-@@ -375,6 +377,7 @@
- SDL_Event event;
- int posted, repeatable;
- Uint16 modstate;
-+ int use_lock_keys;
-
- SDL_memset(&event, 0, sizeof(event));
-
-@@ -386,6 +389,7 @@
- modstate = (Uint16)SDL_ModState;
-
- repeatable = 0;
-+ use_lock_keys = ( SDL_UseLockKeys && *SDL_UseLockKeys );
-
- if ( state == SDL_PRESSED ) {
- keysym->mod = (SDLMod)modstate;
-@@ -393,12 +397,16 @@
- case SDLK_UNKNOWN:
- break;
- case SDLK_NUMLOCK:
-+ if ( ! use_lock_keys )
-+ break;
- modstate ^= KMOD_NUM;
- if ( ! (modstate&KMOD_NUM) )
- state = SDL_RELEASED;
- keysym->mod = (SDLMod)modstate;
- break;
- case SDLK_CAPSLOCK:
-+ if ( ! use_lock_keys )
-+ break;
- modstate ^= KMOD_CAPS;
- if ( ! (modstate&KMOD_CAPS) )
- state = SDL_RELEASED;
-@@ -441,6 +449,8 @@
- break;
- case SDLK_NUMLOCK:
- case SDLK_CAPSLOCK:
-+ if (! use_lock_keys )
-+ break;
- /* Only send keydown events */
- return(0);
- case SDLK_LCTRL:
diff --git a/debian/patches/205_x11_keysym_fix.diff b/debian/patches/205_x11_keysym_fix.diff
deleted file mode 100644
index 88b3762..0000000
--- a/debian/patches/205_x11_keysym_fix.diff
+++ /dev/null
@@ -1,21 +0,0 @@
----
- src/video/x11/SDL_x11events.c | 8 +++++++-
- 1 file changed, 7 insertions(+), 1 deletion(-)
-
---- a/src/video/x11/SDL_x11events.c
-+++ b/src/video/x11/SDL_x11events.c
-@@ -1098,7 +1098,13 @@
- KeySym xsym;
- SDLKey key;
-
-- xsym = XKeycodeToKeysym(display, kc, 0);
-+// if ( xkey ) {
-+// /* Until we handle the IM protocol, use XLookupString() */
-+// unsigned char keybuf[32];
-+// XLookupString(xkey, keybuf, sizeof(keybuf), &xsym, NULL);
-+// } else {
-+ xsym = XKeycodeToKeysym(display, kc, 0);
-+// }
- #ifdef DEBUG_KEYS
- fprintf(stderr, "Translating key code %d -> 0x%.4x\n", kc, xsym);
- #endif
diff --git a/debian/patches/206_gcc4_compilation_fix.diff b/debian/patches/206_gcc4_compilation_fix.diff
deleted file mode 100644
index 7d05bb5..0000000
--- a/debian/patches/206_gcc4_compilation_fix.diff
+++ /dev/null
@@ -1,24 +0,0 @@
----
- include/SDL_events.h | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
---- a/include/SDL_events.h
-+++ b/include/SDL_events.h
-@@ -44,7 +44,7 @@
- #define SDL_PRESSED 1
-
- /* Event enumerations */
--typedef enum {
-+typedef enum SDL_Events {
- SDL_NOEVENT = 0, /* Unused (do not remove) */
- SDL_ACTIVEEVENT, /* Application loses/gains visibility */
- SDL_KEYDOWN, /* Keys pressed */
-@@ -79,7 +79,7 @@
-
- /* Predefined event masks */
- #define SDL_EVENTMASK(X) (1<<(X))
--typedef enum {
-+typedef enum SDL_EventMasks {
- SDL_ACTIVEEVENTMASK = SDL_EVENTMASK(SDL_ACTIVEEVENT),
- SDL_KEYDOWNMASK = SDL_EVENTMASK(SDL_KEYDOWN),
- SDL_KEYUPMASK = SDL_EVENTMASK(SDL_KEYUP),
diff --git a/debian/patches/209_alsa_priority.diff b/debian/patches/209_alsa_priority.diff
deleted file mode 100644
index a4d498a..0000000
--- a/debian/patches/209_alsa_priority.diff
+++ /dev/null
@@ -1,25 +0,0 @@
----
- src/audio/SDL_audio.c | 6 +++---
- src/audio/SDL_sysaudio.h | 6 +++---
- 2 files changed, 6 insertions(+), 6 deletions(-)
-
-Index: SDL-1.2.14/src/audio/SDL_audio.c
-===================================================================
---- SDL-1.2.14.orig/src/audio/SDL_audio.c 2009-10-13 06:25:35.000000000 -0400
-+++ SDL-1.2.14/src/audio/SDL_audio.c 2009-11-28 09:09:36.000000000 -0500
-@@ -39,12 +39,12 @@
- #if SDL_AUDIO_DRIVER_BSD
- &BSD_AUDIO_bootstrap,
- #endif
--#if SDL_AUDIO_DRIVER_PULSE
-- &PULSE_bootstrap,
--#endif
- #if SDL_AUDIO_DRIVER_ALSA
- &ALSA_bootstrap,
- #endif
-+#if SDL_AUDIO_DRIVER_PULSE
-+ &PULSE_bootstrap,
-+#endif
- #if SDL_AUDIO_DRIVER_OSS
- &DSP_bootstrap,
- &DMA_bootstrap,
diff --git a/debian/patches/214_missing_mmx_blit.diff b/debian/patches/214_missing_mmx_blit.diff
deleted file mode 100644
index 67892d2..0000000
--- a/debian/patches/214_missing_mmx_blit.diff
+++ /dev/null
@@ -1,15 +0,0 @@
----
- src/video/SDL_blit_N.c | 2 ++
- 1 file changed, 2 insertions(+)
-
---- a/src/video/SDL_blit_N.c
-+++ b/src/video/SDL_blit_N.c
-@@ -2333,6 +2333,8 @@
- { 0x00FF0000,0x0000FF00,0x000000FF, 2, 0x0000001F,0x000003E0,0x00007C00,
- 0, ConvertX86p32_16BGR555, ConvertX86, NO_ALPHA },
- { 0x00FF0000,0x0000FF00,0x000000FF, 3, 0x00FF0000,0x0000FF00,0x000000FF,
-+ 1, ConvertMMXpII32_24RGB888, ConvertMMX, NO_ALPHA },
-+ { 0x00FF0000,0x0000FF00,0x000000FF, 3, 0x00FF0000,0x0000FF00,0x000000FF,
- 0, ConvertX86p32_24RGB888, ConvertX86, NO_ALPHA },
- { 0x00FF0000,0x0000FF00,0x000000FF, 3, 0x000000FF,0x0000FF00,0x00FF0000,
- 0, ConvertX86p32_24BGR888, ConvertX86, NO_ALPHA },
diff --git a/debian/patches/215_kfreebsd_gnu.diff b/debian/patches/215_kfreebsd_gnu.diff
deleted file mode 100644
index 801926b..0000000
--- a/debian/patches/215_kfreebsd_gnu.diff
+++ /dev/null
@@ -1,71 +0,0 @@
----
- src/joystick/bsd/SDL_sysjoystick.c | 14 +++++++-------
- 1 file changed, 7 insertions(+), 7 deletions(-)
-
-Index: libsdl1.2-1.2.14/src/joystick/bsd/SDL_sysjoystick.c
-===================================================================
---- libsdl1.2-1.2.14.orig/src/joystick/bsd/SDL_sysjoystick.c 2009-10-13 01:07:13.000000000 +0200
-+++ libsdl1.2-1.2.14/src/joystick/bsd/SDL_sysjoystick.c 2010-01-09 17:32:25.000000000 +0100
-@@ -59,7 +59,7 @@
- #include <libusbhid.h>
- #endif
-
--#ifdef __FREEBSD__
-+#if defined(__FREEBSD__) || defined(__FreeBSD_kernel__)
- #ifndef __DragonFly__
- #include <osreldate.h>
- #endif
-@@ -78,7 +78,7 @@
- #define MAX_JOY_JOYS 2
- #define MAX_JOYS (MAX_UHID_JOYS + MAX_JOY_JOYS)
-
--#if defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063)
-+#if defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063) && false
- struct usb_ctl_report {
- int ucr_report;
- u_char ucr_data[1024]; /* filled data size will vary */
-@@ -148,7 +148,7 @@
- static int report_alloc(struct report *, struct report_desc *, int);
- static void report_free(struct report *);
-
--#if defined(USBHID_UCR_DATA) || (defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063))
-+#if defined(USBHID_UCR_DATA) || (defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063)) || defined(__FreeBSD_kernel__)
- #define REP_BUF_DATA(rep) ((rep)->buf->ucr_data)
- #else
- #define REP_BUF_DATA(rep) ((rep)->buf->data)
-@@ -303,7 +303,7 @@
- strerror(errno));
- goto usberr;
- }
--#if defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063)
-+#if defined(__FREEBSD__) && (__FreeBSD_kernel_version > 800063) || defined(__FreeBSD_kernel__)
- rep->rid = hid_get_report_id(fd);
- if (rep->rid < 0) {
- #else
-@@ -321,7 +321,7 @@
- goto usberr;
- }
-
--#if defined(USBHID_NEW) || (defined(__FREEBSD__) && __FreeBSD_kernel_version >= 500111)
-+#if defined(USBHID_NEW) || (defined(__FREEBSD__) && __FreeBSD_kernel_version >= 500111) || defined(__FreeBSD_kernel__)
- hdata = hid_start_parse(hw->repdesc, 1 << hid_input, rep->rid);
- #else
- hdata = hid_start_parse(hw->repdesc, 1 << hid_input);
-@@ -405,7 +405,7 @@
- int nbutton, naxe = -1;
- Sint32 v;
-
--#if defined(__FREEBSD__) || SDL_JOYSTICK_USBHID_MACHINE_JOYSTICK_H
-+#if defined(__FREEBSD__) || SDL_JOYSTICK_USBHID_MACHINE_JOYSTICK_H || defined(__FreeBSD_kernel__)
- struct joystick gameport;
-
- if (joy->hwdata->type == BSDJOY_JOY) {
-@@ -460,7 +460,7 @@
- if (read(joy->hwdata->fd, REP_BUF_DATA(rep), rep->size) != rep->size) {
- return;
- }
--#if defined(USBHID_NEW) || (defined(__FREEBSD__) && __FreeBSD_kernel_version >= 500111)
-+#if defined(USBHID_NEW) || (defined(__FREEBSD__) && __FreeBSD_kernel_version >= 500111) || defined(__FreeBSD_kernel__)
- hdata = hid_start_parse(joy->hwdata->repdesc, 1 << hid_input, rep->rid);
- #else
- hdata = hid_start_parse(joy->hwdata->repdesc, 1 << hid_input);
diff --git a/debian/patches/216_page_size.diff b/debian/patches/216_page_size.diff
deleted file mode 100644
index 98b0ffb..0000000
--- a/debian/patches/216_page_size.diff
+++ /dev/null
@@ -1,15 +0,0 @@
----
- src/video/ps2gs/SDL_gsyuv.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/src/video/ps2gs/SDL_gsyuv.c
-+++ b/src/video/ps2gs/SDL_gsyuv.c
-@@ -180,7 +180,7 @@
-
- /* Allocate a DMA area for pixel conversion */
- bpp = this->screen->format->BytesPerPixel;
-- map_offset = (mapped_len + (PAGE_SIZE - 1)) & ~(PAGE_SIZE - 1);
-+ map_offset = (mapped_len + (sysconf(_SC_PAGESIZE) - 1)) & ~(sysconf(_SC_PAGESIZE) - 1);
- hwdata->dma_len = hwdata->macroblocks * (16 * 16 + 8 * 8 + 8 * 8) +
- width * height * bpp +
- hwdata->macroblocks * (16 * sizeof(long long)) +
diff --git a/debian/patches/217_x11_keytounicode.diff b/debian/patches/217_x11_keytounicode.diff
deleted file mode 100644
index 53376a7..0000000
--- a/debian/patches/217_x11_keytounicode.diff
+++ /dev/null
@@ -1,33 +0,0 @@
----
- src/video/x11/SDL_x11events.c | 9 +++++++++
- 1 file changed, 9 insertions(+)
-
-Index: SDL-1.2.14/src/video/x11/SDL_x11events.c
-===================================================================
---- SDL-1.2.14.orig/src/video/x11/SDL_x11events.c 2009-10-12 19:07:15.000000000 -0400
-+++ SDL-1.2.14/src/video/x11/SDL_x11events.c 2009-11-28 09:19:15.000000000 -0500
-@@ -1228,8 +1228,11 @@
- * sequences (dead accents, compose key sequences) will not work since the
- * state has been irrevocably lost.
- */
-+extern DECLSPEC Uint16 SDLCALL X11_KeyToUnicode(SDLKey, SDLMod);
-+
- Uint16 X11_KeyToUnicode(SDLKey keysym, SDLMod modifiers)
- {
-+ static int warning = 1;
- struct SDL_VideoDevice *this = current_video;
- char keybuf[32];
- int i;
-@@ -1237,6 +1240,12 @@
- XKeyEvent xkey;
- Uint16 unicode;
-
-+ if ( warning ) {
-+ warning = 0;
-+ fprintf(stderr, "WARNING: Application is using X11_KeyToUnicode().\n");
-+ fprintf(stderr, "This is not an official SDL function, please report this as a bug.\n");
-+ }
-+
- if ( !this || !SDL_Display ) {
- return 0;
- }
diff --git a/debian/patches/218_double_free.diff b/debian/patches/218_double_free.diff
deleted file mode 100644
index aa2fd86..0000000
--- a/debian/patches/218_double_free.diff
+++ /dev/null
@@ -1,22 +0,0 @@
-Index: libsdl1.2-1.2.11/src/cdrom/linux/SDL_syscdrom.c
-===================================================================
---- libsdl1.2-1.2.11.orig/src/cdrom/linux/SDL_syscdrom.c 2007-02-09 16:13:16.000000000 +0100
-+++ libsdl1.2-1.2.11/src/cdrom/linux/SDL_syscdrom.c 2007-02-09 16:13:22.000000000 +0100
-@@ -218,7 +218,7 @@
- if ( SDL_strcmp(mnt_type, MNTTYPE_SUPER) == 0 ) {
- tmp = SDL_strstr(mntent->mnt_opts, "fs=");
- if ( tmp ) {
-- SDL_free(mnt_type);
-+ SDL_stack_free(mnt_type);
- mnt_type = SDL_strdup(tmp + SDL_strlen("fs="));
- if ( mnt_type ) {
- tmp = SDL_strchr(mnt_type, ',');
-@@ -229,7 +229,7 @@
- }
- tmp = SDL_strstr(mntent->mnt_opts, "dev=");
- if ( tmp ) {
-- SDL_free(mnt_dev);
-+ SDL_stack_free(mnt_dev);
- mnt_dev = SDL_strdup(tmp + SDL_strlen("dev="));
- if ( mnt_dev ) {
- tmp = SDL_strchr(mnt_dev, ',');
diff --git a/debian/patches/218_joystick_memmove.diff b/debian/patches/218_joystick_memmove.diff
deleted file mode 100644
index 90dead4..0000000
--- a/debian/patches/218_joystick_memmove.diff
+++ /dev/null
@@ -1,15 +0,0 @@
----
- src/joystick/SDL_joystick.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
---- a/src/joystick/SDL_joystick.c
-+++ b/src/joystick/SDL_joystick.c
-@@ -373,7 +373,7 @@
- /* Remove joystick from list */
- for ( i=0; SDL_joysticks[i]; ++i ) {
- if ( joystick == SDL_joysticks[i] ) {
-- SDL_memcpy(&SDL_joysticks[i], &SDL_joysticks[i+1],
-+ SDL_memmove(&SDL_joysticks[i], &SDL_joysticks[i+1],
- (SDL_numjoysticks-i)*sizeof(joystick));
- break;
- }
diff --git a/debian/patches/219_pulseaudio_crackles.diff b/debian/patches/219_pulseaudio_crackles.diff
deleted file mode 100644
index 93470ce..0000000
--- a/debian/patches/219_pulseaudio_crackles.diff
+++ /dev/null
@@ -1,21 +0,0 @@
----
- src/audio/pulse/SDL_pulseaudio.c | 7 +++----
- 1 file changed, 3 insertions(+), 4 deletions(-)
-
---- a/src/audio/pulse/SDL_pulseaudio.c
-+++ b/src/audio/pulse/SDL_pulseaudio.c
-@@ -340,11 +340,10 @@
- SDL_memset(mixbuf, spec->silence, spec->size);
-
- /* Reduced prebuffering compared to the defaults. */
-- paattr.tlength = mixlen;
-+ paattr.tlength = mixlen*2;
- paattr.minreq = mixlen;
-- paattr.fragsize = mixlen;
-- paattr.prebuf = mixlen;
-- paattr.maxlength = mixlen * 4;
-+ paattr.prebuf = mixlen * 2;
-+ paattr.maxlength = mixlen * 2;
-
- /* The SDL ALSA output hints us that we use Windows' channel mapping */
- /* http://bugzilla.libsdl.org/show_bug.cgi?id=110 */
diff --git a/debian/patches/220_std_cld.diff b/debian/patches/220_std_cld.diff
deleted file mode 100644
index d45e40d..0000000
--- a/debian/patches/220_std_cld.diff
+++ /dev/null
@@ -1,14 +0,0 @@
----
- include/SDL_stdinc.h | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/include/SDL_stdinc.h
-+++ b/include/SDL_stdinc.h
-@@ -331,6 +331,7 @@
- __asm__ __volatile__ ( \
- "std\n\t" \
- "rep ; movsl\n\t" \
-+ "cld\n\t" \
- : "=&c" (u0), "=&D" (u1), "=&S" (u2) \
- : "0" (n >> 2), \
- "1" (dstp+(n-4)), "2" (srcp+(n-4)) \
diff --git a/debian/patches/221_check_SDL_NOKBD_environment_variable.diff b/debian/patches/221_check_SDL_NOKBD_environment_variable.diff
deleted file mode 100644
index 41888f5..0000000
--- a/debian/patches/221_check_SDL_NOKBD_environment_variable.diff
+++ /dev/null
@@ -1,60 +0,0 @@
- 1.2.13-4+nmu2: Closes: #438915
----
- src/video/fbcon/SDL_fbvideo.c | 20 ++++++++++++--------
- 1 file changed, 12 insertions(+), 8 deletions(-)
-
-Index: SDL-1.2.14/src/video/fbcon/SDL_fbvideo.c
-===================================================================
---- SDL-1.2.14.orig/src/video/fbcon/SDL_fbvideo.c 2009-10-12 19:07:15.000000000 -0400
-+++ SDL-1.2.14/src/video/fbcon/SDL_fbvideo.c 2009-11-28 09:20:05.000000000 -0500
-@@ -792,14 +792,19 @@
- }
- }
-
-- /* Enable mouse and keyboard support */
-- if ( FB_OpenKeyboard(this) < 0 ) {
-- FB_VideoQuit(this);
-- return(-1);
-- }
-+ if (!SDL_getenv("SDL_NOKBD"))
-+ {
-+ fprintf(stderr, "init kbd.\n");
-+ /* Enable mouse and keyboard support */
-+ if ( FB_OpenKeyboard(this) < 0 ) {
-+ FB_VideoQuit(this);
-+ return(-1);
-+ }
-+ }
- if ( FB_OpenMouse(this) < 0 ) {
- const char *sdl_nomouse;
-
-+ fprintf(stderr, "init mouse failed.\n");
- sdl_nomouse = SDL_getenv("SDL_NOMOUSE");
- if ( ! sdl_nomouse ) {
- SDL_SetError("Unable to open mouse");
-@@ -1009,7 +1014,6 @@
-
- /* Set the terminal into graphics mode */
- if ( FB_EnterGraphicsMode(this) < 0 ) {
-- return(NULL);
- }
-
- /* Restore the original palette */
-@@ -1910,7 +1914,7 @@
-
- if ( this->screen ) {
- /* Clear screen and tell SDL not to free the pixels */
-- if ( this->screen->pixels && FB_InGraphicsMode(this) ) {
-+ if ( this->screen->pixels && (FB_InGraphicsMode(this) || SDL_getenv("SDL_NOKBD")) ) {
- #if defined(__powerpc__) || defined(__ia64__) /* SIGBUS when using SDL_memset() ?? */
- Uint8 *rowp = (Uint8 *)this->screen->pixels;
- int left = this->screen->pitch*this->screen->h;
-@@ -1959,7 +1963,7 @@
- }
-
- /* Restore the original video mode and palette */
-- if ( FB_InGraphicsMode(this) ) {
-+ if ( FB_InGraphicsMode(this) || SDL_getenv("SDL_NOKBD") ) {
- FB_RestorePalette(this);
- ioctl(console_fd, FBIOPUT_VSCREENINFO, &saved_vinfo);
- }
diff --git a/debian/patches/222_joystick_crash.diff b/debian/patches/222_joystick_crash.diff
deleted file mode 100644
index 949e18b..0000000
--- a/debian/patches/222_joystick_crash.diff
+++ /dev/null
@@ -1,14 +0,0 @@
-Description: Fix crash with joystick detection.
-Index: libsdl1.2-1.2.14/src/joystick/linux/SDL_sysjoystick.c
-===================================================================
---- libsdl1.2-1.2.14.orig/src/joystick/linux/SDL_sysjoystick.c 2010-01-12 12:37:36.000000000 -0500
-+++ libsdl1.2-1.2.14/src/joystick/linux/SDL_sysjoystick.c 2010-01-12 12:38:27.000000000 -0500
-@@ -700,7 +700,7 @@
- continue;
- }
- if ( test_bit(i, absbit) ) {
-- int values[5];
-+ int values[6];
-
- if ( ioctl(fd, EVIOCGABS(i), values) < 0 )
- continue;
diff --git a/debian/patches/310_fixmouseclicks b/debian/patches/310_fixmouseclicks
deleted file mode 100644
index 3f0177c..0000000
--- a/debian/patches/310_fixmouseclicks
+++ /dev/null
@@ -1,25 +0,0 @@
-Index: libsdl1.2-1.2.14/src/video/x11/SDL_x11events.c
-===================================================================
---- libsdl1.2-1.2.14.orig/src/video/x11/SDL_x11events.c 2010-04-06 19:29:05.000000000 +0100
-+++ libsdl1.2-1.2.14/src/video/x11/SDL_x11events.c 2010-04-06 19:29:46.000000000 +0100
-@@ -423,12 +423,15 @@
- if ( xevent.xcrossing.mode == NotifyUngrab )
- printf("Mode: NotifyUngrab\n");
- #endif
-- if ( this->input_grab == SDL_GRAB_OFF ) {
-- posted = SDL_PrivateAppActive(1, SDL_APPMOUSEFOCUS);
-+ if ( (xevent.xcrossing.mode != NotifyGrab) &&
-+ (xevent.xcrossing.mode != NotifyUngrab) ) {
-+ if ( this->input_grab == SDL_GRAB_OFF ) {
-+ posted = SDL_PrivateAppActive(1, SDL_APPMOUSEFOCUS);
-+ }
-+ posted = SDL_PrivateMouseMotion(0, 0,
-+ xevent.xcrossing.x,
-+ xevent.xcrossing.y);
- }
-- posted = SDL_PrivateMouseMotion(0, 0,
-- xevent.xcrossing.x,
-- xevent.xcrossing.y);
- }
- break;
-
diff --git a/debian/patches/310_segfault_noGLX.diff b/debian/patches/310_segfault_noGLX.diff
deleted file mode 100644
index ba0798f..0000000
--- a/debian/patches/310_segfault_noGLX.diff
+++ /dev/null
@@ -1,16 +0,0 @@
-Index: libsdl1.2-1.2.13/src/video/x11/SDL_x11gl.c
-===================================================================
---- libsdl1.2-1.2.13.orig/src/video/x11/SDL_x11gl.c 2009-10-01 16:53:43.000000000 -0400
-+++ libsdl1.2-1.2.13/src/video/x11/SDL_x11gl.c 2009-10-01 16:55:39.000000000 -0400
-@@ -70,6 +70,11 @@
- /* It takes a bit of care to be fool-proof about parsing the
- * OpenGL extensions string. Don't be fooled by sub-strings, etc.
- */
-+
-+ /* http://bugs.debian.org/537487 */
-+ if (extensions == NULL) {
-+ return 0;
-+ }
-
- start = extensions;
-
diff --git a/debian/patches/320_activate_xrandr_on_default.diff b/debian/patches/320_activate_xrandr_on_default.diff
deleted file mode 100644
index 5c9208c..0000000
--- a/debian/patches/320_activate_xrandr_on_default.diff
+++ /dev/null
@@ -1,22 +0,0 @@
-Index: libsdl1.2-1.2.13/src/video/x11/SDL_x11modes.c
-===================================================================
---- libsdl1.2-1.2.13.orig/src/video/x11/SDL_x11modes.c 2009-10-02 10:07:12.000000000 -0400
-+++ libsdl1.2-1.2.13/src/video/x11/SDL_x11modes.c 2009-10-02 10:07:59.000000000 -0400
-@@ -392,11 +392,14 @@
- return 0;
- }
-
-- /* This defaults off now, due to KDE window maximize problems */
-- if ( !env ) {
-+ // deactivated since I haven't encountered such problems with KDE, but if
-+ // one does encounter such problems he/she can just set
-+ // SDL_VIDEO_X11_XRANDR to 0
-+ // Closes: #450689
-+/* if ( !env ) {
- return 0;
- }
--
-+*/
- if ( !SDL_X11_HAVE_XRANDR ) {
- return 0;
- }
diff --git a/debian/patches/320_disappearingcursor.diff b/debian/patches/320_disappearingcursor.diff
deleted file mode 100644
index fcd3c31..0000000
--- a/debian/patches/320_disappearingcursor.diff
+++ /dev/null
@@ -1,17 +0,0 @@
-Index: SDL-1.2.14/src/video/x11/SDL_x11events.c
-===================================================================
---- SDL-1.2.14.orig/src/video/x11/SDL_x11events.c 2010-04-30 09:16:35.000000000 -0400
-+++ SDL-1.2.14/src/video/x11/SDL_x11events.c 2010-04-30 09:16:35.000000000 -0400
-@@ -444,8 +444,10 @@
- if ( xevent.xcrossing.mode == NotifyUngrab )
- printf("Mode: NotifyUngrab\n");
- #endif
-- if ( xevent.xcrossing.detail != NotifyInferior ) {
-- if ( this->input_grab == SDL_GRAB_OFF ) {
-+ if ( (xevent.xcrossing.mode != NotifyGrab) &&
-+ (xevent.xcrossing.mode != NotifyUngrab) &&
-+ (xevent.xcrossing.detail != NotifyInferior) ) {
-+ if ( this->input_grab == SDL_GRAB_OFF ) {
- posted = SDL_PrivateAppActive(0, SDL_APPMOUSEFOCUS);
- } else {
- posted = SDL_PrivateMouseMotion(0, 0,
diff --git a/debian/patches/series b/debian/patches/series
index d79ae11..d087830 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,16 +1,3 @@
-#020_libcaca_new_api.diff
-#030_pulseaudio_enable.diff
-#040_propagate_pic_to_nasm.diff
-#050_altivec_detection.diff
-####060_disable_ipod.diff
-#206_gcc4_compilation_fix.diff
-#209_alsa_priority.diff - Refreshed but should pulse be before ALSA?
-####215_kfreebsd_gnu.diff
-####217_x11_keytounicode.diff
-####221_check_SDL_NOKBD_environment_variable.diff
-####222_joystick_crash.diff
300_dont_propagate_lpthread.diff
-####310_fixmouseclicks
-####320_disappearingcursor.diff
fix_joystick_misc_axes.diff
bug-723797-false_positives_in_mouse_wheel_code.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-sdl/packages/libsdl2.git
More information about the pkg-sdl-commits
mailing list