[arch-commits] Commit in sdl_sound/repos (8 files)

Jan Steffens heftig at archlinux.org
Thu Mar 30 21:13:42 UTC 2017


    Date: Thursday, March 30, 2017 @ 21:13:42
  Author: heftig
Revision: 291921

archrelease: copy trunk to extra-i686, extra-x86_64

Added:
  sdl_sound/repos/extra-i686/PKGBUILD
    (from rev 291919, sdl_sound/trunk/PKGBUILD)
  sdl_sound/repos/extra-i686/flac.patch
    (from rev 291919, sdl_sound/trunk/flac.patch)
  sdl_sound/repos/extra-x86_64/PKGBUILD
    (from rev 291919, sdl_sound/trunk/PKGBUILD)
  sdl_sound/repos/extra-x86_64/flac.patch
    (from rev 291919, sdl_sound/trunk/flac.patch)
Deleted:
  sdl_sound/repos/extra-i686/PKGBUILD
  sdl_sound/repos/extra-i686/flac.patch
  sdl_sound/repos/extra-x86_64/PKGBUILD
  sdl_sound/repos/extra-x86_64/flac.patch

-------------------------+
 /PKGBUILD               |   64 +++++++++++
 /flac.patch             |  252 ++++++++++++++++++++++++++++++++++++++++++++++
 extra-i686/PKGBUILD     |   32 -----
 extra-i686/flac.patch   |  126 -----------------------
 extra-x86_64/PKGBUILD   |   32 -----
 extra-x86_64/flac.patch |  126 -----------------------
 6 files changed, 316 insertions(+), 316 deletions(-)

Deleted: extra-i686/PKGBUILD
===================================================================
--- extra-i686/PKGBUILD	2017-03-30 21:13:37 UTC (rev 291920)
+++ extra-i686/PKGBUILD	2017-03-30 21:13:42 UTC (rev 291921)
@@ -1,32 +0,0 @@
-# $Id$
-# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens at gmail.com>
-# Contributor: Tom Newsom <Jeepster at gmx.co.uk>
-
-pkgname=sdl_sound
-pkgver=1.0.3
-pkgrel=5
-pkgdesc="A library to decode several popular sound file formats, such as .WAV and .MP3"
-arch=('i686' 'x86_64')
-url="http://icculus.org/SDL_sound/"
-license=('LGPL')
-depends=('sdl' 'libmikmod' 'libvorbis' 'flac' 'speex' 'smpeg')
-source=(http://icculus.org/SDL_sound/downloads/SDL_sound-$pkgver.tar.gz 
-        flac.patch)
-md5sums=('aa09cd52df85d29bee87a664424c94b5'
-         '302aa9dc94cc71dd3339ca3177d36e1c')
-
-build() {
-  cd ${srcdir}/SDL_sound-${pkgver}
-
-  CFLAGS="$CFLAGS -I/usr/include/smpeg" \
-  CXXFLAGS="$CXXFLAGS -I/usr/include/smpeg" \
-  ./configure --prefix=/usr --disable-static
-
-  make
-}
-
-package() {
-  cd ${srcdir}/SDL_sound-${pkgver}
-  make DESTDIR=${pkgdir} install
-}
-

Copied: sdl_sound/repos/extra-i686/PKGBUILD (from rev 291919, sdl_sound/trunk/PKGBUILD)
===================================================================
--- extra-i686/PKGBUILD	                        (rev 0)
+++ extra-i686/PKGBUILD	2017-03-30 21:13:42 UTC (rev 291921)
@@ -0,0 +1,32 @@
+# $Id$
+# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens at gmail.com>
+# Contributor: Tom Newsom <Jeepster at gmx.co.uk>
+
+pkgname=sdl_sound
+pkgver=1.0.3
+pkgrel=6
+pkgdesc="A library to decode several popular sound file formats, such as .WAV and .MP3"
+url="https://icculus.org/SDL_sound/"
+arch=(i686 x86_64)
+license=(LGPL)
+depends=(sdl libmikmod libvorbis flac speex smpeg)
+source=(https://icculus.org/SDL_sound/downloads/SDL_sound-$pkgver.tar.gz 
+        flac.patch)
+sha256sums=('3999fd0bbb485289a52be14b2f68b571cb84e380cc43387eadf778f64c79e6df'
+            '5ffe81fe08453f4abaa2611f9646db6b8fad0dfeaaf8c98b94613d5c6295c691')
+
+build() {
+  cd SDL_sound-$pkgver
+
+  CFLAGS+=" -I/usr/include/smpeg"
+  CXXFLAGS+=" -I/usr/include/smpeg"
+
+  ./configure --prefix=/usr --disable-static
+  make
+}
+
+package() {
+  cd SDL_sound-$pkgver
+  make DESTDIR="$pkgdir" install
+}
+

Deleted: extra-i686/flac.patch
===================================================================
--- extra-i686/flac.patch	2017-03-30 21:13:37 UTC (rev 291920)
+++ extra-i686/flac.patch	2017-03-30 21:13:42 UTC (rev 291921)
@@ -1,126 +0,0 @@
-diff -u -r SDL_sound-1.0.1/configure.in SDL_sound-1.0.1-flac/configure.in
---- SDL_sound-1.0.1/configure.in	2003-10-12 20:49:54.000000000 +0200
-+++ SDL_sound-1.0.1-flac/configure.in	2006-12-11 20:43:46.546583251 +0100
-@@ -155,9 +155,12 @@
- dnl  FLAC developers tend to break their API with every release, so we're
- dnl  checking for the latest-and-greatest here so we don't have to support
- dnl  obsolete versions.
-+dnl Starting with FLAC 1.1.3:
-+dnl   libFLAC supports Ogg FLAC (no more libOggFLAC) so we also need -logg
-+dnl   the libFLAC .so version is also #defined in FLAC/export.h
- 
- dnl Hooray for shitty autoconf bugs!
--x="C__seekable_stream_decoder_process_single"
-+x="C__stream_decoder_process_single"
- flcsym="FLA$x"
- dnl Check for libFLAC
- AC_ARG_ENABLE(flac,
-@@ -167,7 +170,7 @@
-   AC_CHECK_HEADER(FLAC/stream_decoder.h, have_flac_hdr=yes)
-   AC_CHECK_LIB(FLAC, $flcsym, have_flac_lib=yes)
-   if test x$have_flac_hdr = xyes -a x$have_flac_lib = xyes; then
--    LIBS="$LIBS -lFLAC"
-+    LIBS="$LIBS -lFLAC -logg"
-     AC_DEFINE(SOUND_SUPPORTS_FLAC)
-   fi
- fi
-diff -u -r SDL_sound-1.0.1/decoders/flac.c SDL_sound-1.0.1-flac/decoders/flac.c
---- SDL_sound-1.0.1/decoders/flac.c	2003-03-10 23:44:14.000000000 +0100
-+++ SDL_sound-1.0.1-flac/decoders/flac.c	2006-12-11 20:43:57.880097062 +0100
-@@ -44,6 +44,16 @@
- #define __SDL_SOUND_INTERNAL__
- #include "SDL_sound_internal.h"
- 
-+#include <FLAC/export.h>
-+
-+/* FLAC 1.1.3 has FLAC_API_VERSION_CURRENT == 8 */
-+#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
-+#define LEGACY_FLAC
-+#else
-+#undef LEGACY_FLAC
-+#endif
-+
-+#ifdef LEGACY_FLAC
- #include <FLAC/seekable_stream_decoder.h>
- 
- #define D_END_OF_STREAM               FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM
-@@ -80,6 +90,34 @@
- typedef FLAC__SeekableStreamDecoderSeekStatus   d_seek_status_t;
- typedef FLAC__SeekableStreamDecoderTellStatus   d_tell_status_t;
- typedef FLAC__SeekableStreamDecoderLengthStatus d_length_status_t;
-+#else
-+#include <FLAC/stream_decoder.h>
-+
-+#define D_END_OF_STREAM               FLAC__STREAM_DECODER_END_OF_STREAM
-+
-+#define d_new()                       FLAC__stream_decoder_new()
-+#define d_process_metadata(x)         FLAC__stream_decoder_process_until_end_of_metadata(x)
-+#define d_process_one_frame(x)        FLAC__stream_decoder_process_single(x)
-+#define d_get_state(x)                FLAC__stream_decoder_get_state(x)
-+#define d_finish(x)                   FLAC__stream_decoder_finish(x)
-+#define d_delete(x)                   FLAC__stream_decoder_delete(x)
-+
-+typedef FLAC__StreamDecoder           decoder_t;
-+typedef FLAC__StreamDecoderReadStatus d_read_status_t;
-+
-+#define D_SEEK_STATUS_OK              FLAC__STREAM_DECODER_SEEK_STATUS_OK
-+#define D_SEEK_STATUS_ERROR           FLAC__STREAM_DECODER_SEEK_STATUS_ERROR
-+#define D_TELL_STATUS_OK              FLAC__STREAM_DECODER_TELL_STATUS_OK
-+#define D_TELL_STATUS_ERROR           FLAC__STREAM_DECODER_TELL_STATUS_ERROR
-+#define D_LENGTH_STATUS_OK            FLAC__STREAM_DECODER_LENGTH_STATUS_OK
-+#define D_LENGTH_STATUS_ERROR         FLAC__STREAM_DECODER_LENGTH_STATUS_ERROR
-+
-+#define d_seek_absolute(x, y)         FLAC__stream_decoder_seek_absolute(x, y)
-+
-+typedef FLAC__StreamDecoderSeekStatus   d_seek_status_t;
-+typedef FLAC__StreamDecoderTellStatus   d_tell_status_t;
-+typedef FLAC__StreamDecoderLengthStatus d_length_status_t;
-+#endif
- 
- #define D_WRITE_CONTINUE     FLAC__STREAM_DECODER_WRITE_STATUS_CONTINUE
- #define D_READ_END_OF_STREAM FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM
-@@ -141,9 +179,15 @@
- } /* free_flac */
- 
- 
-+#ifdef LEGACY_FLAC
- static d_read_status_t read_callback(
-     const decoder_t *decoder, FLAC__byte buffer[],
-     unsigned int *bytes, void *client_data)
-+#else
-+static d_read_status_t read_callback(
-+    const decoder_t *decoder, FLAC__byte buffer[],
-+    size_t *bytes, void *client_data)
-+#endif
- {
-     flac_t *f = (flac_t *) client_data;
-     Uint32 retval;
-@@ -400,6 +444,7 @@
-         BAIL_MACRO(ERR_OUT_OF_MEMORY, 0);
-     } /* if */       
- 
-+#ifdef LEGACY_FLAC
-     d_set_read_callback(decoder, read_callback);
-     d_set_write_callback(decoder, write_callback);
-     d_set_metadata_callback(decoder, metadata_callback);
-@@ -410,6 +455,7 @@
-     d_set_eof_callback(decoder, eof_callback);
- 
-     d_set_client_data(decoder, f);
-+#endif
- 
-     f->rw = internal->rw;
-     f->sample = sample;
-@@ -418,7 +464,12 @@
-     f->is_flac = 0 /* !!! FIXME: should be "has_extension", not "0". */;
- 
-     internal->decoder_private = f;
-+    /* really should check the init return value here: */
-+#ifdef LEGACY_FLAC
-     d_init(decoder);
-+#else
-+    FLAC__stream_decoder_init_stream(decoder, read_callback, seek_callback, tell_callback, length_callback, eof_callback, write_callback, metadata_callback, error_callback, f);
-+#endif
- 
-     sample->flags = SOUND_SAMPLEFLAG_NONE;
- 

Copied: sdl_sound/repos/extra-i686/flac.patch (from rev 291919, sdl_sound/trunk/flac.patch)
===================================================================
--- extra-i686/flac.patch	                        (rev 0)
+++ extra-i686/flac.patch	2017-03-30 21:13:42 UTC (rev 291921)
@@ -0,0 +1,126 @@
+diff -u -r SDL_sound-1.0.1/configure.in SDL_sound-1.0.1-flac/configure.in
+--- SDL_sound-1.0.1/configure.in	2003-10-12 20:49:54.000000000 +0200
++++ SDL_sound-1.0.1-flac/configure.in	2006-12-11 20:43:46.546583251 +0100
+@@ -155,9 +155,12 @@
+ dnl  FLAC developers tend to break their API with every release, so we're
+ dnl  checking for the latest-and-greatest here so we don't have to support
+ dnl  obsolete versions.
++dnl Starting with FLAC 1.1.3:
++dnl   libFLAC supports Ogg FLAC (no more libOggFLAC) so we also need -logg
++dnl   the libFLAC .so version is also #defined in FLAC/export.h
+ 
+ dnl Hooray for shitty autoconf bugs!
+-x="C__seekable_stream_decoder_process_single"
++x="C__stream_decoder_process_single"
+ flcsym="FLA$x"
+ dnl Check for libFLAC
+ AC_ARG_ENABLE(flac,
+@@ -167,7 +170,7 @@
+   AC_CHECK_HEADER(FLAC/stream_decoder.h, have_flac_hdr=yes)
+   AC_CHECK_LIB(FLAC, $flcsym, have_flac_lib=yes)
+   if test x$have_flac_hdr = xyes -a x$have_flac_lib = xyes; then
+-    LIBS="$LIBS -lFLAC"
++    LIBS="$LIBS -lFLAC -logg"
+     AC_DEFINE(SOUND_SUPPORTS_FLAC)
+   fi
+ fi
+diff -u -r SDL_sound-1.0.1/decoders/flac.c SDL_sound-1.0.1-flac/decoders/flac.c
+--- SDL_sound-1.0.1/decoders/flac.c	2003-03-10 23:44:14.000000000 +0100
++++ SDL_sound-1.0.1-flac/decoders/flac.c	2006-12-11 20:43:57.880097062 +0100
+@@ -44,6 +44,16 @@
+ #define __SDL_SOUND_INTERNAL__
+ #include "SDL_sound_internal.h"
+ 
++#include <FLAC/export.h>
++
++/* FLAC 1.1.3 has FLAC_API_VERSION_CURRENT == 8 */
++#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
++#define LEGACY_FLAC
++#else
++#undef LEGACY_FLAC
++#endif
++
++#ifdef LEGACY_FLAC
+ #include <FLAC/seekable_stream_decoder.h>
+ 
+ #define D_END_OF_STREAM               FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM
+@@ -80,6 +90,34 @@
+ typedef FLAC__SeekableStreamDecoderSeekStatus   d_seek_status_t;
+ typedef FLAC__SeekableStreamDecoderTellStatus   d_tell_status_t;
+ typedef FLAC__SeekableStreamDecoderLengthStatus d_length_status_t;
++#else
++#include <FLAC/stream_decoder.h>
++
++#define D_END_OF_STREAM               FLAC__STREAM_DECODER_END_OF_STREAM
++
++#define d_new()                       FLAC__stream_decoder_new()
++#define d_process_metadata(x)         FLAC__stream_decoder_process_until_end_of_metadata(x)
++#define d_process_one_frame(x)        FLAC__stream_decoder_process_single(x)
++#define d_get_state(x)                FLAC__stream_decoder_get_state(x)
++#define d_finish(x)                   FLAC__stream_decoder_finish(x)
++#define d_delete(x)                   FLAC__stream_decoder_delete(x)
++
++typedef FLAC__StreamDecoder           decoder_t;
++typedef FLAC__StreamDecoderReadStatus d_read_status_t;
++
++#define D_SEEK_STATUS_OK              FLAC__STREAM_DECODER_SEEK_STATUS_OK
++#define D_SEEK_STATUS_ERROR           FLAC__STREAM_DECODER_SEEK_STATUS_ERROR
++#define D_TELL_STATUS_OK              FLAC__STREAM_DECODER_TELL_STATUS_OK
++#define D_TELL_STATUS_ERROR           FLAC__STREAM_DECODER_TELL_STATUS_ERROR
++#define D_LENGTH_STATUS_OK            FLAC__STREAM_DECODER_LENGTH_STATUS_OK
++#define D_LENGTH_STATUS_ERROR         FLAC__STREAM_DECODER_LENGTH_STATUS_ERROR
++
++#define d_seek_absolute(x, y)         FLAC__stream_decoder_seek_absolute(x, y)
++
++typedef FLAC__StreamDecoderSeekStatus   d_seek_status_t;
++typedef FLAC__StreamDecoderTellStatus   d_tell_status_t;
++typedef FLAC__StreamDecoderLengthStatus d_length_status_t;
++#endif
+ 
+ #define D_WRITE_CONTINUE     FLAC__STREAM_DECODER_WRITE_STATUS_CONTINUE
+ #define D_READ_END_OF_STREAM FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM
+@@ -141,9 +179,15 @@
+ } /* free_flac */
+ 
+ 
++#ifdef LEGACY_FLAC
+ static d_read_status_t read_callback(
+     const decoder_t *decoder, FLAC__byte buffer[],
+     unsigned int *bytes, void *client_data)
++#else
++static d_read_status_t read_callback(
++    const decoder_t *decoder, FLAC__byte buffer[],
++    size_t *bytes, void *client_data)
++#endif
+ {
+     flac_t *f = (flac_t *) client_data;
+     Uint32 retval;
+@@ -400,6 +444,7 @@
+         BAIL_MACRO(ERR_OUT_OF_MEMORY, 0);
+     } /* if */       
+ 
++#ifdef LEGACY_FLAC
+     d_set_read_callback(decoder, read_callback);
+     d_set_write_callback(decoder, write_callback);
+     d_set_metadata_callback(decoder, metadata_callback);
+@@ -410,6 +455,7 @@
+     d_set_eof_callback(decoder, eof_callback);
+ 
+     d_set_client_data(decoder, f);
++#endif
+ 
+     f->rw = internal->rw;
+     f->sample = sample;
+@@ -418,7 +464,12 @@
+     f->is_flac = 0 /* !!! FIXME: should be "has_extension", not "0". */;
+ 
+     internal->decoder_private = f;
++    /* really should check the init return value here: */
++#ifdef LEGACY_FLAC
+     d_init(decoder);
++#else
++    FLAC__stream_decoder_init_stream(decoder, read_callback, seek_callback, tell_callback, length_callback, eof_callback, write_callback, metadata_callback, error_callback, f);
++#endif
+ 
+     sample->flags = SOUND_SAMPLEFLAG_NONE;
+ 

Deleted: extra-x86_64/PKGBUILD
===================================================================
--- extra-x86_64/PKGBUILD	2017-03-30 21:13:37 UTC (rev 291920)
+++ extra-x86_64/PKGBUILD	2017-03-30 21:13:42 UTC (rev 291921)
@@ -1,32 +0,0 @@
-# $Id$
-# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens at gmail.com>
-# Contributor: Tom Newsom <Jeepster at gmx.co.uk>
-
-pkgname=sdl_sound
-pkgver=1.0.3
-pkgrel=5
-pkgdesc="A library to decode several popular sound file formats, such as .WAV and .MP3"
-arch=('i686' 'x86_64')
-url="http://icculus.org/SDL_sound/"
-license=('LGPL')
-depends=('sdl' 'libmikmod' 'libvorbis' 'flac' 'speex' 'smpeg')
-source=(http://icculus.org/SDL_sound/downloads/SDL_sound-$pkgver.tar.gz 
-        flac.patch)
-md5sums=('aa09cd52df85d29bee87a664424c94b5'
-         '302aa9dc94cc71dd3339ca3177d36e1c')
-
-build() {
-  cd ${srcdir}/SDL_sound-${pkgver}
-
-  CFLAGS="$CFLAGS -I/usr/include/smpeg" \
-  CXXFLAGS="$CXXFLAGS -I/usr/include/smpeg" \
-  ./configure --prefix=/usr --disable-static
-
-  make
-}
-
-package() {
-  cd ${srcdir}/SDL_sound-${pkgver}
-  make DESTDIR=${pkgdir} install
-}
-

Copied: sdl_sound/repos/extra-x86_64/PKGBUILD (from rev 291919, sdl_sound/trunk/PKGBUILD)
===================================================================
--- extra-x86_64/PKGBUILD	                        (rev 0)
+++ extra-x86_64/PKGBUILD	2017-03-30 21:13:42 UTC (rev 291921)
@@ -0,0 +1,32 @@
+# $Id$
+# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens at gmail.com>
+# Contributor: Tom Newsom <Jeepster at gmx.co.uk>
+
+pkgname=sdl_sound
+pkgver=1.0.3
+pkgrel=6
+pkgdesc="A library to decode several popular sound file formats, such as .WAV and .MP3"
+url="https://icculus.org/SDL_sound/"
+arch=(i686 x86_64)
+license=(LGPL)
+depends=(sdl libmikmod libvorbis flac speex smpeg)
+source=(https://icculus.org/SDL_sound/downloads/SDL_sound-$pkgver.tar.gz 
+        flac.patch)
+sha256sums=('3999fd0bbb485289a52be14b2f68b571cb84e380cc43387eadf778f64c79e6df'
+            '5ffe81fe08453f4abaa2611f9646db6b8fad0dfeaaf8c98b94613d5c6295c691')
+
+build() {
+  cd SDL_sound-$pkgver
+
+  CFLAGS+=" -I/usr/include/smpeg"
+  CXXFLAGS+=" -I/usr/include/smpeg"
+
+  ./configure --prefix=/usr --disable-static
+  make
+}
+
+package() {
+  cd SDL_sound-$pkgver
+  make DESTDIR="$pkgdir" install
+}
+

Deleted: extra-x86_64/flac.patch
===================================================================
--- extra-x86_64/flac.patch	2017-03-30 21:13:37 UTC (rev 291920)
+++ extra-x86_64/flac.patch	2017-03-30 21:13:42 UTC (rev 291921)
@@ -1,126 +0,0 @@
-diff -u -r SDL_sound-1.0.1/configure.in SDL_sound-1.0.1-flac/configure.in
---- SDL_sound-1.0.1/configure.in	2003-10-12 20:49:54.000000000 +0200
-+++ SDL_sound-1.0.1-flac/configure.in	2006-12-11 20:43:46.546583251 +0100
-@@ -155,9 +155,12 @@
- dnl  FLAC developers tend to break their API with every release, so we're
- dnl  checking for the latest-and-greatest here so we don't have to support
- dnl  obsolete versions.
-+dnl Starting with FLAC 1.1.3:
-+dnl   libFLAC supports Ogg FLAC (no more libOggFLAC) so we also need -logg
-+dnl   the libFLAC .so version is also #defined in FLAC/export.h
- 
- dnl Hooray for shitty autoconf bugs!
--x="C__seekable_stream_decoder_process_single"
-+x="C__stream_decoder_process_single"
- flcsym="FLA$x"
- dnl Check for libFLAC
- AC_ARG_ENABLE(flac,
-@@ -167,7 +170,7 @@
-   AC_CHECK_HEADER(FLAC/stream_decoder.h, have_flac_hdr=yes)
-   AC_CHECK_LIB(FLAC, $flcsym, have_flac_lib=yes)
-   if test x$have_flac_hdr = xyes -a x$have_flac_lib = xyes; then
--    LIBS="$LIBS -lFLAC"
-+    LIBS="$LIBS -lFLAC -logg"
-     AC_DEFINE(SOUND_SUPPORTS_FLAC)
-   fi
- fi
-diff -u -r SDL_sound-1.0.1/decoders/flac.c SDL_sound-1.0.1-flac/decoders/flac.c
---- SDL_sound-1.0.1/decoders/flac.c	2003-03-10 23:44:14.000000000 +0100
-+++ SDL_sound-1.0.1-flac/decoders/flac.c	2006-12-11 20:43:57.880097062 +0100
-@@ -44,6 +44,16 @@
- #define __SDL_SOUND_INTERNAL__
- #include "SDL_sound_internal.h"
- 
-+#include <FLAC/export.h>
-+
-+/* FLAC 1.1.3 has FLAC_API_VERSION_CURRENT == 8 */
-+#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
-+#define LEGACY_FLAC
-+#else
-+#undef LEGACY_FLAC
-+#endif
-+
-+#ifdef LEGACY_FLAC
- #include <FLAC/seekable_stream_decoder.h>
- 
- #define D_END_OF_STREAM               FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM
-@@ -80,6 +90,34 @@
- typedef FLAC__SeekableStreamDecoderSeekStatus   d_seek_status_t;
- typedef FLAC__SeekableStreamDecoderTellStatus   d_tell_status_t;
- typedef FLAC__SeekableStreamDecoderLengthStatus d_length_status_t;
-+#else
-+#include <FLAC/stream_decoder.h>
-+
-+#define D_END_OF_STREAM               FLAC__STREAM_DECODER_END_OF_STREAM
-+
-+#define d_new()                       FLAC__stream_decoder_new()
-+#define d_process_metadata(x)         FLAC__stream_decoder_process_until_end_of_metadata(x)
-+#define d_process_one_frame(x)        FLAC__stream_decoder_process_single(x)
-+#define d_get_state(x)                FLAC__stream_decoder_get_state(x)
-+#define d_finish(x)                   FLAC__stream_decoder_finish(x)
-+#define d_delete(x)                   FLAC__stream_decoder_delete(x)
-+
-+typedef FLAC__StreamDecoder           decoder_t;
-+typedef FLAC__StreamDecoderReadStatus d_read_status_t;
-+
-+#define D_SEEK_STATUS_OK              FLAC__STREAM_DECODER_SEEK_STATUS_OK
-+#define D_SEEK_STATUS_ERROR           FLAC__STREAM_DECODER_SEEK_STATUS_ERROR
-+#define D_TELL_STATUS_OK              FLAC__STREAM_DECODER_TELL_STATUS_OK
-+#define D_TELL_STATUS_ERROR           FLAC__STREAM_DECODER_TELL_STATUS_ERROR
-+#define D_LENGTH_STATUS_OK            FLAC__STREAM_DECODER_LENGTH_STATUS_OK
-+#define D_LENGTH_STATUS_ERROR         FLAC__STREAM_DECODER_LENGTH_STATUS_ERROR
-+
-+#define d_seek_absolute(x, y)         FLAC__stream_decoder_seek_absolute(x, y)
-+
-+typedef FLAC__StreamDecoderSeekStatus   d_seek_status_t;
-+typedef FLAC__StreamDecoderTellStatus   d_tell_status_t;
-+typedef FLAC__StreamDecoderLengthStatus d_length_status_t;
-+#endif
- 
- #define D_WRITE_CONTINUE     FLAC__STREAM_DECODER_WRITE_STATUS_CONTINUE
- #define D_READ_END_OF_STREAM FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM
-@@ -141,9 +179,15 @@
- } /* free_flac */
- 
- 
-+#ifdef LEGACY_FLAC
- static d_read_status_t read_callback(
-     const decoder_t *decoder, FLAC__byte buffer[],
-     unsigned int *bytes, void *client_data)
-+#else
-+static d_read_status_t read_callback(
-+    const decoder_t *decoder, FLAC__byte buffer[],
-+    size_t *bytes, void *client_data)
-+#endif
- {
-     flac_t *f = (flac_t *) client_data;
-     Uint32 retval;
-@@ -400,6 +444,7 @@
-         BAIL_MACRO(ERR_OUT_OF_MEMORY, 0);
-     } /* if */       
- 
-+#ifdef LEGACY_FLAC
-     d_set_read_callback(decoder, read_callback);
-     d_set_write_callback(decoder, write_callback);
-     d_set_metadata_callback(decoder, metadata_callback);
-@@ -410,6 +455,7 @@
-     d_set_eof_callback(decoder, eof_callback);
- 
-     d_set_client_data(decoder, f);
-+#endif
- 
-     f->rw = internal->rw;
-     f->sample = sample;
-@@ -418,7 +464,12 @@
-     f->is_flac = 0 /* !!! FIXME: should be "has_extension", not "0". */;
- 
-     internal->decoder_private = f;
-+    /* really should check the init return value here: */
-+#ifdef LEGACY_FLAC
-     d_init(decoder);
-+#else
-+    FLAC__stream_decoder_init_stream(decoder, read_callback, seek_callback, tell_callback, length_callback, eof_callback, write_callback, metadata_callback, error_callback, f);
-+#endif
- 
-     sample->flags = SOUND_SAMPLEFLAG_NONE;
- 

Copied: sdl_sound/repos/extra-x86_64/flac.patch (from rev 291919, sdl_sound/trunk/flac.patch)
===================================================================
--- extra-x86_64/flac.patch	                        (rev 0)
+++ extra-x86_64/flac.patch	2017-03-30 21:13:42 UTC (rev 291921)
@@ -0,0 +1,126 @@
+diff -u -r SDL_sound-1.0.1/configure.in SDL_sound-1.0.1-flac/configure.in
+--- SDL_sound-1.0.1/configure.in	2003-10-12 20:49:54.000000000 +0200
++++ SDL_sound-1.0.1-flac/configure.in	2006-12-11 20:43:46.546583251 +0100
+@@ -155,9 +155,12 @@
+ dnl  FLAC developers tend to break their API with every release, so we're
+ dnl  checking for the latest-and-greatest here so we don't have to support
+ dnl  obsolete versions.
++dnl Starting with FLAC 1.1.3:
++dnl   libFLAC supports Ogg FLAC (no more libOggFLAC) so we also need -logg
++dnl   the libFLAC .so version is also #defined in FLAC/export.h
+ 
+ dnl Hooray for shitty autoconf bugs!
+-x="C__seekable_stream_decoder_process_single"
++x="C__stream_decoder_process_single"
+ flcsym="FLA$x"
+ dnl Check for libFLAC
+ AC_ARG_ENABLE(flac,
+@@ -167,7 +170,7 @@
+   AC_CHECK_HEADER(FLAC/stream_decoder.h, have_flac_hdr=yes)
+   AC_CHECK_LIB(FLAC, $flcsym, have_flac_lib=yes)
+   if test x$have_flac_hdr = xyes -a x$have_flac_lib = xyes; then
+-    LIBS="$LIBS -lFLAC"
++    LIBS="$LIBS -lFLAC -logg"
+     AC_DEFINE(SOUND_SUPPORTS_FLAC)
+   fi
+ fi
+diff -u -r SDL_sound-1.0.1/decoders/flac.c SDL_sound-1.0.1-flac/decoders/flac.c
+--- SDL_sound-1.0.1/decoders/flac.c	2003-03-10 23:44:14.000000000 +0100
++++ SDL_sound-1.0.1-flac/decoders/flac.c	2006-12-11 20:43:57.880097062 +0100
+@@ -44,6 +44,16 @@
+ #define __SDL_SOUND_INTERNAL__
+ #include "SDL_sound_internal.h"
+ 
++#include <FLAC/export.h>
++
++/* FLAC 1.1.3 has FLAC_API_VERSION_CURRENT == 8 */
++#if !defined(FLAC_API_VERSION_CURRENT) || FLAC_API_VERSION_CURRENT < 8
++#define LEGACY_FLAC
++#else
++#undef LEGACY_FLAC
++#endif
++
++#ifdef LEGACY_FLAC
+ #include <FLAC/seekable_stream_decoder.h>
+ 
+ #define D_END_OF_STREAM               FLAC__SEEKABLE_STREAM_DECODER_END_OF_STREAM
+@@ -80,6 +90,34 @@
+ typedef FLAC__SeekableStreamDecoderSeekStatus   d_seek_status_t;
+ typedef FLAC__SeekableStreamDecoderTellStatus   d_tell_status_t;
+ typedef FLAC__SeekableStreamDecoderLengthStatus d_length_status_t;
++#else
++#include <FLAC/stream_decoder.h>
++
++#define D_END_OF_STREAM               FLAC__STREAM_DECODER_END_OF_STREAM
++
++#define d_new()                       FLAC__stream_decoder_new()
++#define d_process_metadata(x)         FLAC__stream_decoder_process_until_end_of_metadata(x)
++#define d_process_one_frame(x)        FLAC__stream_decoder_process_single(x)
++#define d_get_state(x)                FLAC__stream_decoder_get_state(x)
++#define d_finish(x)                   FLAC__stream_decoder_finish(x)
++#define d_delete(x)                   FLAC__stream_decoder_delete(x)
++
++typedef FLAC__StreamDecoder           decoder_t;
++typedef FLAC__StreamDecoderReadStatus d_read_status_t;
++
++#define D_SEEK_STATUS_OK              FLAC__STREAM_DECODER_SEEK_STATUS_OK
++#define D_SEEK_STATUS_ERROR           FLAC__STREAM_DECODER_SEEK_STATUS_ERROR
++#define D_TELL_STATUS_OK              FLAC__STREAM_DECODER_TELL_STATUS_OK
++#define D_TELL_STATUS_ERROR           FLAC__STREAM_DECODER_TELL_STATUS_ERROR
++#define D_LENGTH_STATUS_OK            FLAC__STREAM_DECODER_LENGTH_STATUS_OK
++#define D_LENGTH_STATUS_ERROR         FLAC__STREAM_DECODER_LENGTH_STATUS_ERROR
++
++#define d_seek_absolute(x, y)         FLAC__stream_decoder_seek_absolute(x, y)
++
++typedef FLAC__StreamDecoderSeekStatus   d_seek_status_t;
++typedef FLAC__StreamDecoderTellStatus   d_tell_status_t;
++typedef FLAC__StreamDecoderLengthStatus d_length_status_t;
++#endif
+ 
+ #define D_WRITE_CONTINUE     FLAC__STREAM_DECODER_WRITE_STATUS_CONTINUE
+ #define D_READ_END_OF_STREAM FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM
+@@ -141,9 +179,15 @@
+ } /* free_flac */
+ 
+ 
++#ifdef LEGACY_FLAC
+ static d_read_status_t read_callback(
+     const decoder_t *decoder, FLAC__byte buffer[],
+     unsigned int *bytes, void *client_data)
++#else
++static d_read_status_t read_callback(
++    const decoder_t *decoder, FLAC__byte buffer[],
++    size_t *bytes, void *client_data)
++#endif
+ {
+     flac_t *f = (flac_t *) client_data;
+     Uint32 retval;
+@@ -400,6 +444,7 @@
+         BAIL_MACRO(ERR_OUT_OF_MEMORY, 0);
+     } /* if */       
+ 
++#ifdef LEGACY_FLAC
+     d_set_read_callback(decoder, read_callback);
+     d_set_write_callback(decoder, write_callback);
+     d_set_metadata_callback(decoder, metadata_callback);
+@@ -410,6 +455,7 @@
+     d_set_eof_callback(decoder, eof_callback);
+ 
+     d_set_client_data(decoder, f);
++#endif
+ 
+     f->rw = internal->rw;
+     f->sample = sample;
+@@ -418,7 +464,12 @@
+     f->is_flac = 0 /* !!! FIXME: should be "has_extension", not "0". */;
+ 
+     internal->decoder_private = f;
++    /* really should check the init return value here: */
++#ifdef LEGACY_FLAC
+     d_init(decoder);
++#else
++    FLAC__stream_decoder_init_stream(decoder, read_callback, seek_callback, tell_callback, length_callback, eof_callback, write_callback, metadata_callback, error_callback, f);
++#endif
+ 
+     sample->flags = SOUND_SAMPLEFLAG_NONE;
+ 


More information about the arch-commits mailing list