[arch-commits] Commit in xmms2/trunk (PKGBUILD ffmpeg2.0.patch)

Bartłomiej Piotrowski bpiotrowski at nymeria.archlinux.org
Mon Jul 22 15:27:47 UTC 2013


    Date: Monday, July 22, 2013 @ 17:27:46
  Author: bpiotrowski
Revision: 94394

upgpkg: xmms2 0.8DrO_o-19

- rebuild against ffmpeg 2.0

Added:
  xmms2/trunk/ffmpeg2.0.patch
Modified:
  xmms2/trunk/PKGBUILD

-----------------+
 PKGBUILD        |   14 +++++---------
 ffmpeg2.0.patch |   37 +++++++++++++++++++++++++++++++++++++
 2 files changed, 42 insertions(+), 9 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2013-07-22 14:40:40 UTC (rev 94393)
+++ PKGBUILD	2013-07-22 15:27:46 UTC (rev 94394)
@@ -3,7 +3,7 @@
 
 pkgname=xmms2
 pkgver=0.8DrO_o
-pkgrel=18
+pkgrel=19
 pkgdesc="complete rewrite of the popular music player"
 arch=('i686' 'x86_64')
 url="http://xmms2.org/"
@@ -53,22 +53,18 @@
 source=("http://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2"
 	"xmms2d.conf"
 	"xmms2d.service"
-	"ffmpeg-0.11.diff")
+	"ffmpeg2.0.patch")
 md5sums=('84d5c05a70bfd31ed392a4e3f701eaa3'
          'af13c937bf3c86b77ae6820107aab9b8'
          '47e68461589578e8a99857746c5b6f29'
-         'e176971ef96807f72fa8fc17d260c20a')
+         'da84ec58c5711f3c4ecd932c3e6642d6')
 
 build() {
-  cd xmms2-${pkgver}/src/plugins/avcodec/
-  # remove call to avcodec_init
-  # http://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=3211932c513338566b31d990d06957e15a644d13
-  patch -Np0 -i ${srcdir}/ffmpeg-0.11.diff
-
   cd ${srcdir}/${pkgname}-${pkgver}
+  patch -Np1 -i ../ffmpeg2.0.patch
 
   # python2 fix
-#  sed -i 's_#!/usr/bin/env python_#!/usr/bin/env python2_' waf
+  # sed -i 's_#!/usr/bin/env python_#!/usr/bin/env python2_' waf
   sed -i 's|#include <cdio/cdda.h>|#include <cdio/paranoia/cdda.h>|' src/plugins/cdda/cdda.c
   sed -i 's|libsmbclient.h|samba-4.0/libsmbclient.h|' src/plugins/samba/{samba.c,wscript}
 

Added: ffmpeg2.0.patch
===================================================================
--- ffmpeg2.0.patch	                        (rev 0)
+++ ffmpeg2.0.patch	2013-07-22 15:27:46 UTC (rev 94394)
@@ -0,0 +1,37 @@
+diff -rupN a/src/plugins/avcodec/avcodec.c b/src/plugins/avcodec/avcodec.c
+--- a/src/plugins/avcodec/avcodec.c	2011-10-20 21:26:08.000000000 +0200
++++ b/src/plugins/avcodec/avcodec.c	2013-07-22 17:17:53.098385978 +0200
+@@ -134,7 +134,6 @@ xmms_avcodec_init (xmms_xform_t *xform)
+ 
+ 	xmms_xform_private_data_set (xform, data);
+ 
+-	avcodec_init ();
+ 	avcodec_register_all ();
+ 
+ 	mimetype = xmms_xform_indata_get_str (xform,
+@@ -200,7 +199,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
+ 		}
+ 	}
+ 
+-	data->codecctx = avcodec_alloc_context ();
++	data->codecctx = avcodec_alloc_context3 (NULL);
+ 	data->codecctx->sample_rate = data->samplerate;
+ 	data->codecctx->channels = data->channels;
+ 	data->codecctx->bit_rate = data->bitrate;
+@@ -211,7 +210,7 @@ xmms_avcodec_init (xmms_xform_t *xform)
+ 	data->codecctx->codec_id = codec->id;
+ 	data->codecctx->codec_type = codec->type;
+ 
+-	if (avcodec_open (data->codecctx, codec) < 0) {
++	if (avcodec_open2 (data->codecctx, codec, NULL) < 0) {
+ 		XMMS_DBG ("Opening decoder '%s' failed", codec->name);
+ 		goto err;
+ 	} else {
+diff -rupN a/src/plugins/avcodec/avcodec_compat.h b/src/plugins/avcodec/avcodec_compat.h
+--- a/src/plugins/avcodec/avcodec_compat.h	2011-10-20 21:26:08.000000000 +0200
++++ b/src/plugins/avcodec/avcodec_compat.h	2013-07-22 17:16:15.841723560 +0200
+@@ -65,3 +65,4 @@ typedef struct AVPacket {
+ # define AVMEDIA_TYPE_AUDIO CODEC_TYPE_AUDIO
+ #endif
+ 
++#define AVCODEC_MAX_AUDIO_FRAME_SIZE 192000




More information about the arch-commits mailing list