[mingw-SDL: 2/17] Initial import.

Kalev Lember kalev at fedoraproject.org
Wed Mar 7 17:33:39 UTC 2012


commit 4cb7ba955a279db08d360ff251ec7e959a33bddf
Author: Richard W.M. Jones <rjones at fedoraproject.org>
Date:   Sat Jan 17 11:39:33 2009 +0000

    Initial import.

 .cvsignore                     |    1 +
 SDL-1.2.10-byteorder.patch     |   21 ++++++
 SDL-1.2.11-dynamic-esd.patch   |   19 ++++++
 SDL-1.2.12-disable_yasm.patch  |   11 +++
 SDL-1.2.12-multilib.patch      |   25 ++++++++
 SDL-1.2.12-x11dyn64.patch      |   13 ++++
 SDL-1.2.13-audiodriver.patch   |   29 +++++++++
 SDL-1.2.13-dynamic-pulse.patch |   40 ++++++++++++
 SDL-1.2.13-libdir.patch        |   66 ++++++++++++++++++++
 SDL-1.2.13-pulse-rework.patch  |  132 ++++++++++++++++++++++++++++++++++++++++
 import.log                     |    1 +
 mingw32-SDL.spec               |  128 ++++++++++++++++++++++++++++++++++++++
 sources                        |    1 +
 13 files changed, 487 insertions(+), 0 deletions(-)
---
diff --git a/.cvsignore b/.cvsignore
index e69de29..1e9e39c 100644
--- a/.cvsignore
+++ b/.cvsignore
@@ -0,0 +1 @@
+SDL-1.2.13.tar.gz
diff --git a/SDL-1.2.10-byteorder.patch b/SDL-1.2.10-byteorder.patch
new file mode 100644
index 0000000..64273e5
--- /dev/null
+++ b/SDL-1.2.10-byteorder.patch
@@ -0,0 +1,21 @@
+--- SDL-1.2.10/include/SDL_endian.h.byteorder	2006-05-01 10:02:59.000000000 +0200
++++ SDL-1.2.10/include/SDL_endian.h	2006-05-19 11:53:07.000000000 +0200
+@@ -32,6 +32,10 @@
+ #define SDL_BIG_ENDIAN	4321
+ 
+ #ifndef SDL_BYTEORDER	/* Not defined in SDL_config.h? */
++#ifdef __linux__
++#include <endian.h>
++#define SDL_BYTEORDER  __BYTE_ORDER
++#else /* __linux __ */
+ #if defined(__hppa__) || \
+     defined(__m68k__) || defined(mc68000) || defined(_M_M68K) || \
+     (defined(__MIPS__) && defined(__MISPEB__)) || \
+@@ -41,6 +45,7 @@
+ #else
+ #define SDL_BYTEORDER	SDL_LIL_ENDIAN
+ #endif
++#endif /* __linux __ */
+ #endif /* !SDL_BYTEORDER */
+ 
+ 
diff --git a/SDL-1.2.11-dynamic-esd.patch b/SDL-1.2.11-dynamic-esd.patch
new file mode 100644
index 0000000..d63958b
--- /dev/null
+++ b/SDL-1.2.11-dynamic-esd.patch
@@ -0,0 +1,19 @@
+--- SDL-1.2.11/configure.in.dynamic-esd	2007-03-19 17:44:47.000000000 +0100
++++ SDL-1.2.11/configure.in	2007-03-19 17:44:47.000000000 +0100
+@@ -430,6 +430,16 @@
+             AC_ARG_ENABLE(esd-shared,
+ AC_HELP_STRING([--enable-esd-shared], [dynamically load ESD audio support [[default=yes]]]),
+                           , enable_esd_shared=yes)
++            if test "x`echo $ESD_LIBS | grep -- -L`" = "x"; then
++                pfx=${libdir##*/}
++                if test "x`ls /${pfx}/libesd.so.* 2> /dev/null`" != "x"; then
++                    ESD_LIBS="-L/${pfx} $ESD_LIBS"
++                elif test "x`ls /usr/${pfx}/libesd.so.* 2> /dev/null`" != "x"; then
++                    ESD_LIBS="-L/usr/${pfx} $ESD_LIBS"
++                elif test "x`ls /usr/local/${pfx}/libesd.so.* 2> /dev/null`" != "x"; then
++                    ESD_LIBS="-L/usr/local/${pfx} $ESD_LIBS"
++                fi
++            fi
+             esd_lib_spec=`echo $ESD_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libesd.so.*/'`
+             esd_lib=`ls -- $esd_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
+             echo "-- $esd_lib_spec -> $esd_lib"
diff --git a/SDL-1.2.12-disable_yasm.patch b/SDL-1.2.12-disable_yasm.patch
new file mode 100644
index 0000000..2f9f977
--- /dev/null
+++ b/SDL-1.2.12-disable_yasm.patch
@@ -0,0 +1,11 @@
+diff -up SDL-1.2.12/configure.in.disable_yasm SDL-1.2.12/configure.in
+--- SDL-1.2.12/configure.in.disable_yasm	2007-08-27 18:24:44.000000000 +0200
++++ SDL-1.2.12/configure.in	2007-08-27 18:25:04.000000000 +0200
+@@ -715,7 +715,6 @@ AC_HELP_STRING([--enable-nasm], [use nas
+             esac
+         fi
+ 
+-        AC_PATH_PROG(NASM, yasm)
+         echo "%ifidn __OUTPUT_FORMAT__,elf" > unquoted-sections
+         echo "section .note.GNU-stack noalloc noexec nowrite progbits" >> unquoted-sections
+         echo "%endif" >> unquoted-sections
diff --git a/SDL-1.2.12-multilib.patch b/SDL-1.2.12-multilib.patch
new file mode 100644
index 0000000..29e6319
--- /dev/null
+++ b/SDL-1.2.12-multilib.patch
@@ -0,0 +1,25 @@
+diff -up SDL-1.2.12/sdl-config.in.multilib SDL-1.2.12/sdl-config.in
+--- SDL-1.2.12/sdl-config.in.multilib	2007-07-20 07:52:45.000000000 +0200
++++ SDL-1.2.12/sdl-config.in	2007-11-06 17:07:25.000000000 +0100
+@@ -3,7 +3,6 @@
+ prefix=@prefix@
+ exec_prefix=@exec_prefix@
+ exec_prefix_set=no
+-libdir=@libdir@
+ 
+ @ENABLE_STATIC_FALSE at usage="\
+ @ENABLE_STATIC_FALSE at Usage: sdl-config [--prefix[=DIR]] [--exec-prefix[=DIR]] [--version] [--cflags] [--libs]"
+@@ -45,11 +44,11 @@ while test $# -gt 0; do
+       echo -I at includedir@/SDL @SDL_CFLAGS@
+       ;;
+ @ENABLE_SHARED_TRUE@    --libs)
+- at ENABLE_SHARED_TRUE@      echo -L at libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@
++ at ENABLE_SHARED_TRUE@      echo @SDL_RLD_FLAGS@ @SDL_LIBS@
+ @ENABLE_SHARED_TRUE@      ;;
+ @ENABLE_STATIC_TRUE@@ENABLE_SHARED_TRUE@    --static-libs)
+ @ENABLE_STATIC_TRUE@@ENABLE_SHARED_FALSE@    --libs|--static-libs)
+- at ENABLE_STATIC_TRUE@      echo -L at libdir@ @SDL_RLD_FLAGS@ @SDL_STATIC_LIBS@
++ at ENABLE_STATIC_TRUE@      echo @SDL_RLD_FLAGS@ @SDL_STATIC_LIBS@
+ @ENABLE_STATIC_TRUE@      ;;
+     *)
+       echo "${usage}" 1>&2
diff --git a/SDL-1.2.12-x11dyn64.patch b/SDL-1.2.12-x11dyn64.patch
new file mode 100644
index 0000000..6b6d9fe
--- /dev/null
+++ b/SDL-1.2.12-x11dyn64.patch
@@ -0,0 +1,13 @@
+diff -up SDL-1.2.12/configure.in.x11dyn64 SDL-1.2.12/configure.in
+--- SDL-1.2.12/configure.in.x11dyn64	2007-08-27 18:18:28.000000000 +0200
++++ SDL-1.2.12/configure.in	2007-08-27 18:20:48.000000000 +0200
+@@ -950,7 +950,8 @@ AC_HELP_STRING([--enable-x11-shared], [d
+                     ;;
+                 *)
+                     x11_lib_path=[`echo $X_LIBS | sed 's/.*-L\([^ ]*\).*/\1/'`]
+-                    for path in $x11_lib_path /usr/lib /usr/X11/lib /usr/X11R6/lib; do
++		    pfx=${libdir##*/}
++                    for path in $x11_lib_path /usr/${pfx} /usr/lib /usr/X11/lib /usr/X11R6/lib; do
+                         if test "x$x11_lib" = "x"; then
+                             x11_lib=[`ls -- $path/libX11.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`]
+                             if test "x$x11_lib" = "x"; then
diff --git a/SDL-1.2.13-audiodriver.patch b/SDL-1.2.13-audiodriver.patch
new file mode 100644
index 0000000..204e5e6
--- /dev/null
+++ b/SDL-1.2.13-audiodriver.patch
@@ -0,0 +1,29 @@
+diff -up SDL-1.2.13/src/audio/SDL_audio.c.audiodriver SDL-1.2.13/src/audio/SDL_audio.c
+--- SDL-1.2.13/src/audio/SDL_audio.c.audiodriver	2007-12-31 05:47:59.000000000 +0100
++++ SDL-1.2.13/src/audio/SDL_audio.c	2008-09-01 14:53:58.000000000 +0200
+@@ -36,6 +36,12 @@
+ 
+ /* Available audio drivers */
+ static AudioBootStrap *bootstrap[] = {
++#if SDL_AUDIO_DRIVER_PULSE
++	&PULSE_bootstrap,
++#endif
++#if SDL_AUDIO_DRIVER_ALSA
++	&ALSA_bootstrap,
++#endif
+ #if SDL_AUDIO_DRIVER_BSD
+ 	&BSD_AUDIO_bootstrap,
+ #endif
+@@ -43,12 +49,6 @@ static AudioBootStrap *bootstrap[] = {
+ 	&DSP_bootstrap,
+ 	&DMA_bootstrap,
+ #endif
+-#if SDL_AUDIO_DRIVER_ALSA
+-	&ALSA_bootstrap,
+-#endif
+-#if SDL_AUDIO_DRIVER_PULSE
+-	&PULSE_bootstrap,
+-#endif
+ #if SDL_AUDIO_DRIVER_QNXNTO
+ 	&QNXNTOAUDIO_bootstrap,
+ #endif
diff --git a/SDL-1.2.13-dynamic-pulse.patch b/SDL-1.2.13-dynamic-pulse.patch
new file mode 100644
index 0000000..9e222c7
--- /dev/null
+++ b/SDL-1.2.13-dynamic-pulse.patch
@@ -0,0 +1,40 @@
+diff -up SDL-1.2.13/configure.in.dynamic-pulse SDL-1.2.13/configure.in
+--- SDL-1.2.13/configure.in.dynamic-pulse	2008-01-07 12:31:57.000000000 +0100
++++ SDL-1.2.13/configure.in	2008-01-07 12:32:02.000000000 +0100
+@@ -500,14 +510,15 @@ AC_HELP_STRING([--enable-pulseaudio], [u
+         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"
+-                elif test "x`ls /usr/lib/libpulse-simple.so.* 2> /dev/null`" != "x"; then
+-                    PULSE_LIBS="-L/usr/lib $PULSE_LIBS"
+-                elif test "x`ls /usr/local/lib/libpulse-simple.so.* 2> /dev/null`" != "x"; then
+-                    PULSE_LIBS="-L/usr/local/lib $PULSE_LIBS"
++	        pfx=${libdir##*/}
++                if test "x`ls /${pfx}/libpulse-simple.so.* 2> /dev/null`" != "x"; then
++                    PULSE_LIBS="-L/${pfx} $PULSE_LIBS"
++                elif test "x`ls /usr/${pfx}/libpulse-simple.so.* 2> /dev/null`" != "x"; then
++                    PULSE_LIBS="-L/usr/${pfx} $PULSE_LIBS"
++                elif test "x`ls /usr/local/${pfx}/libpulse-simple.so.* 2> /dev/null`" != "x"; then
++                    PULSE_LIBS="-L/usr/local/${pfx} $PULSE_LIBS"
+                 fi
+             fi
+             pulse_lib_spec=`echo $PULSE_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libpulse-simple.so.*/'`
+@@ -518,11 +529,11 @@ AC_HELP_STRING([--enable-pulseaudio-shar
+             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/SDL-1.2.13-libdir.patch b/SDL-1.2.13-libdir.patch
new file mode 100644
index 0000000..be23609
--- /dev/null
+++ b/SDL-1.2.13-libdir.patch
@@ -0,0 +1,66 @@
+diff -up SDL-1.2.13/configure.in.libdir SDL-1.2.13/configure.in
+--- SDL-1.2.13/configure.in.libdir	2007-12-31 05:48:39.000000000 +0100
++++ SDL-1.2.13/configure.in	2008-01-07 11:56:10.000000000 +0100
+@@ -348,12 +348,13 @@ AC_HELP_STRING([--enable-alsa], [support
+ AC_HELP_STRING([--enable-alsa-shared], [dynamically load ALSA audio support [[default=yes]]]),
+                           , enable_alsa_shared=yes)
+             if test "x`echo $ALSA_LIBS | grep -- -L`" = "x"; then
+-                if test "x`ls /lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/lib $ALSA_LIBS"
+-                elif test "x`ls /usr/lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/usr/lib $ALSA_LIBS"
+-                elif test "x`ls /usr/local/lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/usr/local/lib $ALSA_LIBS"
++	        pfx=${libdir##*/}
++                if test "x`ls /${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/${pfx} $ALSA_LIBS"
++                elif test "x`ls /usr/${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/usr/${pfx} $ALSA_LIBS"
++                elif test "x`ls /usr/local/${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/usr/local/${pfx} $ALSA_LIBS"
+                 fi
+             fi
+             alsa_lib_spec=`echo $ALSA_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libasound.so.*/'`
+@@ -561,7 +572,8 @@ AC_HELP_STRING([--enable-arts], [support
+                 AC_ARG_ENABLE(arts-shared,
+ AC_HELP_STRING([--enable-arts-shared], [dynamically load aRts audio support [[default=yes]]]),
+                               , enable_arts_shared=yes)
+-                arts_lib_spec="$ARTS_PREFIX/lib/libartsc.so.*"
++                pfx=${libdir##*/}
++                arts_lib_spec="$ARTS_PREFIX/${pfx}/libartsc.so.*"
+                 arts_lib=`ls -- $arts_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
+                 echo "-- $arts_lib_spec -> $arts_lib"
+ 
+diff -up SDL-1.2.13/configure.libdir SDL-1.2.13/configure
+--- SDL-1.2.13/configure.libdir	2007-12-31 06:09:39.000000000 +0100
++++ SDL-1.2.13/configure	2008-01-07 12:01:32.000000000 +0100
+@@ -24888,12 +24888,13 @@ else
+ fi
+ 
+             if test "x`echo $ALSA_LIBS | grep -- -L`" = "x"; then
+-                if test "x`ls /lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/lib $ALSA_LIBS"
+-                elif test "x`ls /usr/lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/usr/lib $ALSA_LIBS"
+-                elif test "x`ls /usr/local/lib/libasound.so.* 2> /dev/null`" != "x"; then
+-                    ALSA_LIBS="-L/usr/local/lib $ALSA_LIBS"
++	        pfx=${libdir##*/}
++                if test "x`ls /${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/${pfx} $ALSA_LIBS"
++                elif test "x`ls /usr/${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/usr/${pfx} $ALSA_LIBS"
++                elif test "x`ls /usr/local/${pfx}/libasound.so.* 2> /dev/null`" != "x"; then
++                    ALSA_LIBS="-L/usr/local/${pfx} $ALSA_LIBS"
+                 fi
+             fi
+             alsa_lib_spec=`echo $ALSA_LIBS | sed 's/.*-L\([^ ]*\).*/\1\/libasound.so.*/'`
+@@ -25643,7 +25634,8 @@ else
+   enable_arts_shared=yes
+ fi
+ 
+-                arts_lib_spec="$ARTS_PREFIX/lib/libartsc.so.*"
++		pfx=${libdir##*/}
++                arts_lib_spec="$ARTS_PREFIX/${pfx}/libartsc.so.*"
+                 arts_lib=`ls -- $arts_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
+                 echo "-- $arts_lib_spec -> $arts_lib"
+ 
diff --git a/SDL-1.2.13-pulse-rework.patch b/SDL-1.2.13-pulse-rework.patch
new file mode 100644
index 0000000..ce8d0e8
--- /dev/null
+++ b/SDL-1.2.13-pulse-rework.patch
@@ -0,0 +1,132 @@
+--- SDL-1.2.13/src/audio/pulse/SDL_pulseaudio.c	2007-12-31 05:47:58.000000000 +0100
++++ SDL-1.2.13.lennart/src/audio/pulse/SDL_pulseaudio.c	2008-03-31 16:09:05.000000000 +0200
+@@ -1,3 +1,4 @@
++/* -*- Mode: C; c-basic-offset: 8; indent-tabs-mode: t -*- */
+ /*
+     SDL - Simple DirectMedia Layer
+     Copyright (C) 1997-2007 Sam Lantinga
+@@ -18,7 +19,7 @@
+ 
+     Stéphan Kochen
+     stephan at kochen.nl
+-    
++
+     Based on parts of the ALSA and ESounD output drivers.
+ */
+ #include "SDL_config.h"
+@@ -78,14 +79,14 @@ static int (*SDL_NAME(pa_simple_write))(
+ 	pa_simple *s,
+ 	const void *data,
+ 	size_t length,
+-	int *error 
++	int *error
+ );
+ static pa_channel_map* (*SDL_NAME(pa_channel_map_init_auto))(
+ 	pa_channel_map *m,
+ 	unsigned channels,
+ 	pa_channel_map_def_t def
+ );
+-	
++
+ 
+ static struct {
+ 	const char *name;
+@@ -158,16 +159,16 @@ static int Audio_Available(void)
+ 	if ( LoadPulseLibrary() < 0 ) {
+ 		return available;
+ 	}
+-	
++
+ 	/* Connect with a dummy format. */
+ 	paspec.format = PA_SAMPLE_U8;
+ 	paspec.rate = 11025;
+ 	paspec.channels = 1;
+ 	connection = SDL_NAME(pa_simple_new)(
+-		SDL_getenv("PASERVER"),      /* server */
++		NULL,                        /* server */
+ 		"Test stream",               /* application name */
+ 		PA_STREAM_PLAYBACK,          /* playback mode */
+-		SDL_getenv("PADEVICE"),      /* device on the server */
++		NULL,                        /* device on the server */
+ 		"Simple DirectMedia Layer",  /* stream description */
+ 		&paspec,                     /* sample format spec */
+ 		NULL,                        /* channel map */
+@@ -178,7 +179,7 @@ static int Audio_Available(void)
+ 		available = 1;
+ 		SDL_NAME(pa_simple_free)(connection);
+ 	}
+-	
++
+ 	UnloadPulseLibrary();
+ 	return(available);
+ }
+@@ -233,7 +234,7 @@ static void PULSE_WaitAudio(_THIS)
+ {
+ 	/* Check to see if the thread-parent process is still alive */
+ 	{ static int cnt = 0;
+-		/* Note that this only works with thread implementations 
++		/* Note that this only works with thread implementations
+ 		   that use a different process id for each thread.
+ 		*/
+ 		if (parent && (((++cnt)%10) == 0)) { /* Check every 10 loops */
+@@ -302,7 +303,7 @@ static int PULSE_OpenAudio(_THIS, SDL_Au
+ 	pa_sample_spec  paspec;
+ 	pa_buffer_attr  paattr;
+ 	pa_channel_map  pacmap;
+-	
++
+ 	paspec.format = PA_SAMPLE_INVALID;
+ 	for ( test_format = SDL_FirstAudioFormat(spec->format); test_format; ) {
+ 		switch ( test_format ) {
+@@ -324,7 +325,7 @@ static int PULSE_OpenAudio(_THIS, SDL_Au
+ 		return(-1);
+ 	}
+ 	spec->format = test_format;
+-	
++
+ 	paspec.channels = spec->channels;
+ 	paspec.rate = spec->freq;
+ 
+@@ -338,25 +339,24 @@ static int PULSE_OpenAudio(_THIS, SDL_Au
+ 		return(-1);
+ 	}
+ 	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 */
+ 	SDL_NAME(pa_channel_map_init_auto)(
+ 		&pacmap, spec->channels, PA_CHANNEL_MAP_WAVEEX);
+-	
++
+ 	/* Connect to the PulseAudio server */
+ 	stream = SDL_NAME(pa_simple_new)(
+-		SDL_getenv("PASERVER"),      /* server */
++		NULL,                        /* server */
+ 		get_progname(),              /* application name */
+ 		PA_STREAM_PLAYBACK,          /* playback mode */
+-		SDL_getenv("PADEVICE"),      /* device on the server */
++		NULL,                        /* device on the server */
+ 		"Simple DirectMedia Layer",  /* stream description */
+ 		&paspec,                     /* sample format spec */
+ 		&pacmap,                     /* channel map */
+@@ -371,7 +371,6 @@ static int PULSE_OpenAudio(_THIS, SDL_Au
+ 
+ 	/* Get the parent process id (we're the parent of the audio thread) */
+ 	parent = getpid();
+-	
++
+ 	return(0);
+ }
+-
diff --git a/import.log b/import.log
new file mode 100644
index 0000000..944ad39
--- /dev/null
+++ b/import.log
@@ -0,0 +1 @@
+mingw32-SDL-1_2_13-4_fc10:HEAD:mingw32-SDL-1.2.13-4.fc10.src.rpm:1232192069
diff --git a/mingw32-SDL.spec b/mingw32-SDL.spec
new file mode 100644
index 0000000..443cd14
--- /dev/null
+++ b/mingw32-SDL.spec
@@ -0,0 +1,128 @@
+%define __strip %{_mingw32_strip}
+%define __objdump %{_mingw32_objdump}
+%define _use_internal_dependency_generator 0
+%define __find_requires %{_mingw32_findrequires}
+%define __find_provides %{_mingw32_findprovides}
+
+Name:           mingw32-SDL
+Version:        1.2.13
+Release:        4%{?dist}
+Summary:        MinGW Windows port of SDL cross-platform multimedia library
+
+License:        LGPLv2+
+Group:          Development/Libraries
+URL:            http://www.libsdl.org/
+Source0:        http://www.libsdl.org/release/SDL-%{version}.tar.gz
+BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+BuildArch:      noarch
+
+# Patches from native version.
+Patch0:         SDL-1.2.10-byteorder.patch
+Patch17:        SDL-1.2.13-libdir.patch
+Patch21:        SDL-1.2.12-multilib.patch
+Patch23:        SDL-1.2.11-dynamic-esd.patch
+Patch24:        SDL-1.2.12-x11dyn64.patch
+Patch25:        SDL-1.2.12-disable_yasm.patch
+Patch26:        SDL-1.2.13-dynamic-pulse.patch
+Patch27:        SDL-1.2.13-pulse-rework.patch
+Patch28:        SDL-1.2.13-audiodriver.patch
+
+BuildRequires:  mingw32-filesystem >= 40
+BuildRequires:  mingw32-gcc
+BuildRequires:  mingw32-binutils
+BuildRequires:  mingw32-dlfcn
+BuildRequires:  mingw32-iconv
+
+Requires:       pkgconfig
+
+# Not required at the moment, but SDL does contain plenty of C++ code,
+# I just haven't worked out how to enable it.
+#BuildRequires:  mingw32-gcc-c++
+
+# If we have nasm in the future, then this would enable future
+# optimizations on x86-based architectures.
+#%ifarch %{ix86}
+#BuildRequires: nasm
+#%endif
+
+
+%description
+Simple DirectMedia Layer (SDL) is a cross-platform multimedia library
+designed to provide fast access to the graphics frame buffer and audio
+device.
+
+
+%prep
+%setup -q -n SDL-%{version}
+%patch0 -p1 -b .byteorder
+%patch17 -p1 -b .libdir
+%patch21 -p1 -b .multilib
+%patch23 -p1 -b .dynamic-esd
+%patch24 -p1 -b .x11dyn64
+%patch25 -p1 -b .disable_yasm
+%patch26 -p1 -b .dynamic-pulse
+%patch27 -p1 -b .pulse-rework
+%patch28 -p1 -b .audiodriver
+
+
+%build
+%{_mingw32_configure} \
+  --disable-video-svga --disable-video-ggi --disable-video-aalib \
+  --disable-debug \
+  --enable-sdl-dlopen \
+  --enable-dlopen \
+  --enable-arts-shared \
+  --enable-esd-shared \
+  --enable-pulseaudio-shared \
+  --enable-alsa \
+  --disable-rpath
+
+make
+
+
+%install
+rm -rf $RPM_BUILD_ROOT
+make DESTDIR=$RPM_BUILD_ROOT install
+
+# Remove static libraries but DON'T remove *.dll.a files.
+rm $RPM_BUILD_ROOT%{_mingw32_libdir}/libSDL.a
+
+# Actually libSDLmain.a seems to be required.  It just contains
+# a single object file called SDL_win32_main.o.
+#rm $RPM_BUILD_ROOT%{_mingw32_libdir}/libSDLmain.a
+
+# Delete man pages since they duplicate what is already available
+# in base Fedora package.
+rm $RPM_BUILD_ROOT%{_mingw32_mandir}/man3/*.3*
+
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+
+%files
+%defattr(-,root,root)
+%doc COPYING
+%{_mingw32_bindir}/SDL.dll
+%{_mingw32_bindir}/sdl-config
+%{_mingw32_libdir}/libSDL.dll.a
+%{_mingw32_libdir}/libSDL.la
+%{_mingw32_libdir}/libSDLmain.a
+%{_mingw32_libdir}/pkgconfig/sdl.pc
+%{_mingw32_datadir}/aclocal/sdl.m4
+%{_mingw32_includedir}/SDL
+
+
+%changelog
+* Tue Jan 13 2009 Richard W.M. Jones <rjones at redhat.com> - 1.2.13-4
+- Verify we are still up to date with Fedora release.
+- Include COPYING in documentation.
+- Build with dlfcn.
+- List all BRs.
+- No need to package the man pages, don't duplicate what's in the
+  base Fedora package already.
+- Requires pkgconfig.
+
+* Fri Oct 24 2008 Richard W.M. Jones <rjones at redhat.com> - 1.2.13-2
+- Initial RPM release.
diff --git a/sources b/sources
index e69de29..0cb952e 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+c6660feea2a6834de10bc71b2f8e4d88  SDL-1.2.13.tar.gz


More information about the scm-commits mailing list