summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2013-08-12 17:07:25 +0000
committerAlexis Ballier <aballier@gentoo.org>2013-08-12 17:07:25 +0000
commit28983f98774c828a667f12161b88b302026490d1 (patch)
tree0e488b46a08807fa3e956246eb881e59bd7b5a2c /media-video/ffmpeg2theora
parentVersion bump (diff)
downloadgentoo-2-28983f98774c828a667f12161b88b302026490d1.tar.gz
gentoo-2-28983f98774c828a667f12161b88b302026490d1.tar.bz2
gentoo-2-28983f98774c828a667f12161b88b302026490d1.zip
Use upstream patch for swr, backport upstream fix for ffmpeg2 compat, bug #476532, move myesconsargs setup to src_configure, drop debug useflag that only adds debug cflags. Use correct order in the ffmpeg/libav dep since upstream uses ffmpeg.
(Portage version: 2.2.0_alpha196/cvs/Linux x86_64, signed Manifest commit with key 160F534A)
Diffstat (limited to 'media-video/ffmpeg2theora')
-rw-r--r--media-video/ffmpeg2theora/ChangeLog12
-rw-r--r--media-video/ffmpeg2theora/ffmpeg2theora-0.29-r1.ebuild49
-rw-r--r--media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-ffmpeg2.patch40
-rw-r--r--media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-swr.patch24
4 files changed, 124 insertions, 1 deletions
diff --git a/media-video/ffmpeg2theora/ChangeLog b/media-video/ffmpeg2theora/ChangeLog
index 0e51cae97fc3..b38648c12949 100644
--- a/media-video/ffmpeg2theora/ChangeLog
+++ b/media-video/ffmpeg2theora/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for media-video/ffmpeg2theora
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg2theora/ChangeLog,v 1.62 2013/08/12 16:32:58 aballier Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg2theora/ChangeLog,v 1.63 2013/08/12 17:07:25 aballier Exp $
+
+*ffmpeg2theora-0.29-r1 (12 Aug 2013)
+
+ 12 Aug 2013; Alexis Ballier <aballier@gentoo.org>
+ +ffmpeg2theora-0.29-r1.ebuild, +files/ffmpeg2theora-0.29-ffmpeg2.patch,
+ +files/ffmpeg2theora-0.29-swr.patch:
+ Use upstream patch for swr, backport upstream fix for ffmpeg2 compat, bug
+ #476532, move myesconsargs setup to src_configure, drop debug useflag that
+ only adds debug cflags. Use correct order in the ffmpeg/libav dep since
+ upstream uses ffmpeg.
12 Aug 2013; Alexis Ballier <aballier@gentoo.org> -ffmpeg2theora-0.28.ebuild,
-ffmpeg2theora-0.28-r1.ebuild, -files/ffmpeg2theora-0.28-ffmpeg-0.10.patch:
diff --git a/media-video/ffmpeg2theora/ffmpeg2theora-0.29-r1.ebuild b/media-video/ffmpeg2theora/ffmpeg2theora-0.29-r1.ebuild
new file mode 100644
index 000000000000..9ec4a2c0f9ae
--- /dev/null
+++ b/media-video/ffmpeg2theora/ffmpeg2theora-0.29-r1.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-video/ffmpeg2theora/ffmpeg2theora-0.29-r1.ebuild,v 1.1 2013/08/12 17:07:25 aballier Exp $
+
+EAPI=4
+inherit eutils toolchain-funcs scons-utils
+
+DESCRIPTION="A simple converter to create Ogg Theora files."
+HOMEPAGE="http://www.v2v.cc/~j/ffmpeg2theora/"
+SRC_URI="http://www.v2v.cc/~j/${PN}/downloads/${P}.tar.bz2"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="kate"
+
+RDEPEND="
+ || ( media-video/ffmpeg:0 media-libs/libpostproc <media-video/libav-0.8.2-r1 )
+ >=virtual/ffmpeg-0.10
+ >=media-libs/libvorbis-1.1
+ >=media-libs/libogg-1.1
+ >=media-libs/libtheora-1.1[encode]
+ kate? ( >=media-libs/libkate-0.3.7 )"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig"
+
+src_prepare() {
+ epatch "${FILESDIR}/${P}-swr.patch" \
+ "${FILESDIR}/${P}-ffmpeg2.patch"
+}
+
+src_configure() {
+ myesconsargs=(
+ APPEND_CCFLAGS="${CFLAGS}"
+ APPEND_LINKFLAGS="${LDFLAGS}"
+ prefix=/usr
+ mandir=PREFIX/share/man
+ libkate=$(usex kate 1 0)
+ )
+}
+
+src_compile() {
+ escons
+}
+
+src_install() {
+ escons destdir="${D}" install
+ dodoc AUTHORS ChangeLog README subtitles.txt TODO
+}
diff --git a/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-ffmpeg2.patch b/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-ffmpeg2.patch
new file mode 100644
index 000000000000..a9ca9042d2f6
--- /dev/null
+++ b/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-ffmpeg2.patch
@@ -0,0 +1,40 @@
+commit d3435a6a83dc656379de9e6523ecf8d565da6ca6
+Author: Jan Gerber <j@xiph.org>
+Date: Sun May 26 15:25:42 2013 +0200
+
+ don't use deprecated AVCODEC_MAX_AUDIO_FRAME_SIZE
+
+diff --git a/src/ffmpeg2theora.c b/src/ffmpeg2theora.c
+index cde63b9..8bebf28 100644
+--- a/src/ffmpeg2theora.c
++++ b/src/ffmpeg2theora.c
+@@ -47,6 +47,9 @@
+ #include "ffmpeg2theora.h"
+ #include "avinfo.h"
+
++#define MAX_AUDIO_FRAME_SIZE 192000 // 1 second of 48khz 32bit audio
++
++
+ #define LENGTH(x) (sizeof(x) / sizeof(*x))
+
+ enum {
+@@ -1069,8 +1072,8 @@ void ff2theora_output(ff2theora this) {
+ int first = 1;
+ int audio_eos = 0, video_eos = 0, audio_done = 0, video_done = 0;
+ int ret;
+- int16_t *audio_buf=av_malloc(4*AVCODEC_MAX_AUDIO_FRAME_SIZE);
+- int16_t *resampled=av_malloc(4*AVCODEC_MAX_AUDIO_FRAME_SIZE);
++ int16_t *audio_buf=av_malloc(4*MAX_AUDIO_FRAME_SIZE);
++ int16_t *resampled=av_malloc(4*MAX_AUDIO_FRAME_SIZE);
+ int16_t *audio_p=NULL;
+ int no_frames;
+ int no_samples;
+@@ -1531,7 +1534,7 @@ void ff2theora_output(ff2theora this) {
+ while((audio_eos && !audio_done) || avpkt.size > 0 ) {
+ int samples=0;
+ int samples_out=0;
+- int data_size = 4*AVCODEC_MAX_AUDIO_FRAME_SIZE;
++ int data_size = 4*MAX_AUDIO_FRAME_SIZE;
+ int bytes_per_sample = av_get_bytes_per_sample(aenc->sample_fmt);
+
+ if (avpkt.size > 0) {
diff --git a/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-swr.patch b/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-swr.patch
new file mode 100644
index 000000000000..b1117a87ea6f
--- /dev/null
+++ b/media-video/ffmpeg2theora/files/ffmpeg2theora-0.29-swr.patch
@@ -0,0 +1,24 @@
+commit a72baecd4dc7b01c0785b481460dde0fbab9a90a
+Author: Jan Gerber <j@xiph.org>
+Date: Fri Nov 23 20:21:54 2012 +0100
+
+ only depend on libswresample for local branch
+
+ libav does not have libswresample so its not in ubuntu.
+
+diff --git a/SConstruct b/SConstruct
+index 90520c3..01d234a 100644
+--- a/SConstruct
++++ b/SConstruct
+@@ -152,10 +152,10 @@ if not env.GetOption('clean'):
+ "libavcodec >= 52.30.0",
+ "libpostproc",
+ "libswscale",
+- "libswresample",
+ "libavutil",
+ ]
+ if os.path.exists("./ffmpeg"):
++ FFMPEG_LIBS.append('libswresample')
+ pkg_path = list(set(map(os.path.dirname, glob('./ffmpeg/*/*.pc'))))
+ pkg_path.append(os.environ.get('PKG_CONFIG_PATH', ''))
+ os.environ['PKG_CONFIG_PATH'] = ':'.join(pkg_path)