[SCM] GNU Shockwave Flash (SWF) player branch, wheezy, updated. debian/0.8.11_git20120629-1-2-g3ec2603

Gabriele Giacone gg0-guest at moszumanska.debian.org
Tue Jan 21 19:44:51 UTC 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Shockwave Flash (SWF) player".

The branch, wheezy has been updated
       via  3ec2603bc1a27cdf10b562539ea77e430bbeb767 (commit)
      from  98588a288cf6825f4e85415f208b3b1bda41d9f3 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 3ec2603bc1a27cdf10b562539ea77e430bbeb767
Author: Gabriele Giacone <1o5g4r8o at gmail.com>
Date:   Sat Jan 11 14:07:34 2014 +0100

    Remove ifdefs according to wheezy libav versions.

-----------------------------------------------------------------------

Summary of changes:
 debian/changelog             |   4 +-
 debian/patches/02fixffmpegyt | 138 +++++++++++--------------------------------
 2 files changed, 35 insertions(+), 107 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 22b1523..924c6a7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,8 +1,8 @@
 gnash (0.8.11~git20120629-1+wheezy1) stable; urgency=low
 
-  * Fix youtube movies play with ffmpeg media handler (Closes: 729995).
+  * Fix youtube movies play with ffmpeg media handler (Closes: #729995).
 
- -- Gabriele Giacone <1o5g4r8o at gmail.com>  Tue, 19 Nov 2013 20:49:33 +0100
+ -- Gabriele Giacone <1o5g4r8o at gmail.com>  Sat, 11 Jan 2014 16:45:09 +0100
 
 gnash (0.8.11~git20120629-1) unstable; urgency=low
 
diff --git a/debian/patches/02fixffmpegyt b/debian/patches/02fixffmpegyt
index 02e5831..ca36885 100644
--- a/debian/patches/02fixffmpegyt
+++ b/debian/patches/02fixffmpegyt
@@ -3,23 +3,18 @@ Description: Fixes build and ffmpeg decoding with recent ffmpeg/libav
 Author: Alexis Ballier <aballier at gentoo.org>
 Origin: http://git.savannah.gnu.org/gitweb/?p=gnash.git;a=commit;h=4b3dae970549d42723c2528c250a1f95248145c7
 
-diff --git a/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp b/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
-index 067e418..5c8e1ad 100644
 --- a/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
 +++ b/libmedia/ffmpeg/AudioDecoderFfmpeg.cpp
-@@ -84,8 +84,10 @@ AudioDecoderFfmpeg::~AudioDecoderFfmpeg()
+@@ -84,8 +84,6 @@ AudioDecoderFfmpeg::~AudioDecoderFfmpeg(
  
  void AudioDecoderFfmpeg::setup(SoundInfo& info)
  {
 -    // Init the avdecoder-decoder
-+#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(52,6,2)
-+    // Starting from this version avcodec_register calls avcodec_init
-     avcodec_init();
-+#endif
+-    avcodec_init();
      avcodec_register_all();// change this to only register need codec?
  
      enum CodecID codec_id;
-@@ -158,14 +160,14 @@ void AudioDecoderFfmpeg::setup(SoundInfo& info)
+@@ -158,22 +156,20 @@ void AudioDecoderFfmpeg::setup(SoundInfo
              case CODEC_ID_PCM_U16LE:
                  _audioCodecCtx->channels = (info.isStereo() ? 2 : 1);
                  _audioCodecCtx->sample_rate = info.getSampleRate();
@@ -36,18 +31,15 @@ index 067e418..5c8e1ad 100644
                  break;
      }
  }
-@@ -173,7 +175,10 @@ void AudioDecoderFfmpeg::setup(SoundInfo& info)
+ 
  void AudioDecoderFfmpeg::setup(const AudioInfo& info)
  {
-     // Init the avdecoder-decoder
-+#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(52,6,2)
-+    // Starting from this version avcodec_register calls avcodec_init
-     avcodec_init();
-+#endif
+-    // Init the avdecoder-decoder
+-    avcodec_init();
      avcodec_register_all();// change this to only register need codec?
  
      enum CodecID codec_id = CODEC_ID_NONE;
-@@ -297,7 +302,7 @@ void AudioDecoderFfmpeg::setup(const AudioInfo& info)
+@@ -297,7 +293,7 @@ void AudioDecoderFfmpeg::setup(const Aud
                  _audioCodecCtx->channels = (info.stereo ? 2 : 1);
                  _audioCodecCtx->sample_rate = info.sampleRate;
                  // was commented out (why?):
@@ -56,85 +48,65 @@ index 067e418..5c8e1ad 100644
                  break;
      }
  
-diff --git a/libmedia/ffmpeg/MediaParserFfmpeg.cpp b/libmedia/ffmpeg/MediaParserFfmpeg.cpp
-index d6e6902..136cc08 100644
 --- a/libmedia/ffmpeg/MediaParserFfmpeg.cpp
 +++ b/libmedia/ffmpeg/MediaParserFfmpeg.cpp
-@@ -344,8 +344,10 @@ MediaParserFfmpeg::initializeParser()
+@@ -344,8 +344,6 @@ MediaParserFfmpeg::initializeParser()
  {
      av_register_all(); // TODO: needs to be invoked only once ?
  
-+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52,107,0)
-     _byteIOCxt.buffer = NULL;
+-    _byteIOCxt.buffer = NULL;
 -    
-+#endif
-+
      _inputFmt = probeStream();
  
  #ifdef GNASH_ALLOW_VCODEC_ENV	
-@@ -366,7 +368,11 @@ MediaParserFfmpeg::initializeParser()
+@@ -366,7 +364,7 @@ MediaParserFfmpeg::initializeParser()
      // which isn't needed.
      _byteIOBuffer.reset(new unsigned char[byteIOBufferSize]);
  
-+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52,107,0)
-     init_put_byte(&_byteIOCxt,
-+#else
+-    init_put_byte(&_byteIOCxt,
 +    _avIOCxt = avio_alloc_context(
-+#endif
  		  _byteIOBuffer.get(), // buffer
  		  byteIOBufferSize, // buffer size
  		  0, // write flags
-@@ -376,7 +382,11 @@ MediaParserFfmpeg::initializeParser()
+@@ -376,7 +374,7 @@ MediaParserFfmpeg::initializeParser()
  		  MediaParserFfmpeg::seekMediaWrapper // seeker callback
  		  );
      
-+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52,107,0)
-     _byteIOCxt.is_streamed = 1;
-+#else
+-    _byteIOCxt.is_streamed = 1;
 +    _avIOCxt->seekable = 0;
-+#endif
  
  #if !defined(LIBAVCODEC_VERSION_MAJOR) || LIBAVCODEC_VERSION_MAJOR < 52
      // Needed for Lenny.
-@@ -387,12 +397,19 @@ MediaParserFfmpeg::initializeParser()
+@@ -387,12 +385,9 @@ MediaParserFfmpeg::initializeParser()
  
      assert(_formatCtx);
  
-+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52,107,0)
-     // Otherwise av_open_input_stream will reallocate the context.
-     AVFormatParameters ap;
-     std::memset(&ap, 0, sizeof ap);
-     ap.prealloced_context = 1;
- 
-     if (av_open_input_stream(&_formatCtx, &_byteIOCxt, "", _inputFmt, &ap) < 0)
-+#else
-+
+-    // Otherwise av_open_input_stream will reallocate the context.
+-    AVFormatParameters ap;
+-    std::memset(&ap, 0, sizeof ap);
+-    ap.prealloced_context = 1;
 +    _formatCtx->pb = _avIOCxt;
-+
+ 
+-    if (av_open_input_stream(&_formatCtx, &_byteIOCxt, "", _inputFmt, &ap) < 0)
 +    if (avformat_open_input(&_formatCtx, "", _inputFmt, NULL) < 0)
-+#endif
      {
          throw IOException("MediaParserFfmpeg couldn't open input stream");
      }
-@@ -400,10 +417,17 @@ MediaParserFfmpeg::initializeParser()
+@@ -400,10 +395,10 @@ MediaParserFfmpeg::initializeParser()
  #if defined(LIBAVCODEC_VERSION_MAJOR) && LIBAVCODEC_VERSION_MAJOR >= 52
      // Note: in at least some versions of ffmpeg, av_open_input_stream does
      // not parse metadata; not sure why.
-+#if LIBAVUTIL_VERSION_INT < AV_VERSION_INT(51,5,0)
-     AVMetadata* md = _formatCtx->metadata;
-     if (md) {
-         AVMetadataTag* tag = av_metadata_get(md, "album", 0,
-                 AV_METADATA_MATCH_CASE);
-+#else
+-    AVMetadata* md = _formatCtx->metadata;
 +    AVDictionary* md = _formatCtx->metadata;
-+    if (md) {
+     if (md) {
+-        AVMetadataTag* tag = av_metadata_get(md, "album", 0,
+-                AV_METADATA_MATCH_CASE);
 +        AVDictionaryEntry* tag = av_dict_get(md, "album", 0,
 +                AV_DICT_MATCH_CASE);
-+#endif
          if (tag && tag->value) {
              setId3Info(&Id3Info::album, std::string(tag->value),
                      _id3Object);
-@@ -620,27 +644,27 @@ MediaParserFfmpeg::seekMedia(boost::int64_t offset, int whence)
+@@ -620,27 +615,27 @@ MediaParserFfmpeg::seekMedia(boost::int6
  }
  
  boost::uint16_t
@@ -169,26 +141,18 @@ index d6e6902..136cc08 100644
  		default:
  			return 8; // arbitrary value
  	}
-diff --git a/libmedia/ffmpeg/MediaParserFfmpeg.h b/libmedia/ffmpeg/MediaParserFfmpeg.h
-index 4e410d8..a14cfb6 100644
 --- a/libmedia/ffmpeg/MediaParserFfmpeg.h
 +++ b/libmedia/ffmpeg/MediaParserFfmpeg.h
-@@ -154,7 +154,13 @@ private:
+@@ -154,7 +154,7 @@ private:
  	AVStream* _audioStream;
  
  	/// ?
 -	ByteIOContext _byteIOCxt;
-+#if LIBAVFORMAT_VERSION_INT < AV_VERSION_INT(52,107,0)
-+// AVIOContext was introduced a bit earlier but without version bump, so let's
-+// be safe
-+        ByteIOContext _byteIOCxt;
-+#else
-+        AVIOContext* _avIOCxt;
-+#endif
++	AVIOContext* _avIOCxt;
  
  	/// Size of the ByteIO context buffer
  	//
-@@ -172,7 +178,7 @@ private:
+@@ -172,7 +172,7 @@ private:
  	//
  	/// TODO: move somewhere in ffmpeg utils..
  	///
@@ -197,50 +161,14 @@ index 4e410d8..a14cfb6 100644
  
  	/// Make an EncodedVideoFrame from an AVPacket and push to buffer
  	//
-diff --git a/libmedia/ffmpeg/VideoDecoderFfmpeg.cpp b/libmedia/ffmpeg/VideoDecoderFfmpeg.cpp
-index 40a5c80..eeefafe 100644
 --- a/libmedia/ffmpeg/VideoDecoderFfmpeg.cpp
 +++ b/libmedia/ffmpeg/VideoDecoderFfmpeg.cpp
-@@ -171,7 +171,10 @@ VideoDecoderFfmpeg::init(enum CodecID codecId, int /*width*/, int /*height*/,
+@@ -170,8 +170,6 @@ void
+ VideoDecoderFfmpeg::init(enum CodecID codecId, int /*width*/, int /*height*/,
          boost::uint8_t* extradata, int extradataSize)
  {
-     // Init the avdecoder-decoder
-+#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(52,6,2)
-+    // Starting from this version avcodec_register calls avcodec_init
-     avcodec_init();
-+#endif
+-    // Init the avdecoder-decoder
+-    avcodec_init();
      avcodec_register_all();// change this to only register need codec?
  
      _videoCodec = avcodec_find_decoder(codecId); 
-@@ -529,7 +532,11 @@ get_buffer(AVCodecContext* avctx, AVFrame* pic)
- 
-     static unsigned int pic_num = 0;
-     pic->type = FF_BUFFER_TYPE_USER;
-+#if LIBAVCODEC_VERSION_MAJOR < 54
-+    // This field has been unused for longer but has been removed with
-+    // libavcodec 54.
-     pic->age  = ++pic_num - surface->getPicNum();
-+#endif
-     surface->setPicNum(pic_num);
-     return 0;
- #endif
-diff --git a/libmedia/ffmpeg/ffmpegHeaders.h b/libmedia/ffmpeg/ffmpegHeaders.h
-index 65a8d0c..7710121 100644
---- a/libmedia/ffmpeg/ffmpegHeaders.h
-+++ b/libmedia/ffmpeg/ffmpegHeaders.h
-@@ -83,5 +83,15 @@ extern "C" {
- #define HAVE_SWSCALE_H 1
- #endif
- 
-+#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(52,94,1)
-+#define AV_SAMPLE_FMT_NONE SAMPLE_FMT_NONE
-+#define AV_SAMPLE_FMT_U8   SAMPLE_FMT_U8
-+#define AV_SAMPLE_FMT_S16  SAMPLE_FMT_S16
-+#define AV_SAMPLE_FMT_S32  SAMPLE_FMT_S32
-+#define AV_SAMPLE_FMT_FLT  SAMPLE_FMT_FLT
-+#define AV_SAMPLE_FMT_DBL  SAMPLE_FMT_DBL
-+
-+#define AVSampleFormat SampleFormat
-+#endif
- 
- #endif // GNASH_MEDIA_FFMPEG_HEADERS_H


hooks/post-receive
-- 
GNU Shockwave Flash (SWF) player



More information about the pkg-flash-devel mailing list