diff options
author | Alexis Ballier <aballier@gentoo.org> | 2011-05-16 21:51:47 +0000 |
---|---|---|
committer | Alexis Ballier <aballier@gentoo.org> | 2011-05-16 21:51:47 +0000 |
commit | 45651b7f31703c4be02a28dbe65a88b3f6192a59 (patch) | |
tree | 3943168e9a80051db6acea570f9387d42354b581 /media-sound/sox | |
parent | version bump (diff) | |
download | gentoo-2-45651b7f31703c4be02a28dbe65a88b3f6192a59.tar.gz gentoo-2-45651b7f31703c4be02a28dbe65a88b3f6192a59.tar.bz2 gentoo-2-45651b7f31703c4be02a28dbe65a88b3f6192a59.zip |
fix build with ffmpeg git
(Portage version: 2.2.0_alpha33/cvs/Linux x86_64)
Diffstat (limited to 'media-sound/sox')
-rw-r--r-- | media-sound/sox/ChangeLog | 6 | ||||
-rw-r--r-- | media-sound/sox/files/sox-14.3.2-ffmpeg.patch | 40 | ||||
-rw-r--r-- | media-sound/sox/sox-14.3.2.ebuild | 3 |
3 files changed, 47 insertions, 2 deletions
diff --git a/media-sound/sox/ChangeLog b/media-sound/sox/ChangeLog index e1d60cfe1b55..438fbc738c65 100644 --- a/media-sound/sox/ChangeLog +++ b/media-sound/sox/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for media-sound/sox # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-sound/sox/ChangeLog,v 1.124 2011/04/03 11:07:44 scarabeus Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/sox/ChangeLog,v 1.125 2011/05/16 21:51:47 aballier Exp $ + + 16 May 2011; Alexis Ballier <aballier@gentoo.org> sox-14.3.2.ebuild, + +files/sox-14.3.2-ffmpeg.patch: + fix build with ffmpeg git 03 Apr 2011; Tomáš Chvátal <scarabeus@gentoo.org> sox-14.3.0.ebuild, sox-14.3.1.ebuild, sox-14.3.2.ebuild: diff --git a/media-sound/sox/files/sox-14.3.2-ffmpeg.patch b/media-sound/sox/files/sox-14.3.2-ffmpeg.patch new file mode 100644 index 000000000000..5289b9b471d3 --- /dev/null +++ b/media-sound/sox/files/sox-14.3.2-ffmpeg.patch @@ -0,0 +1,40 @@ +Index: sox-14.3.2/src/ffmpeg.c +=================================================================== +--- sox-14.3.2.orig/src/ffmpeg.c ++++ sox-14.3.2/src/ffmpeg.c +@@ -91,7 +91,7 @@ static int stream_component_open(priv_t + + if (!codec || avcodec_open(enc, codec) < 0) + return -1; +- if (enc->codec_type != CODEC_TYPE_AUDIO) { ++ if (enc->codec_type != AVMEDIA_TYPE_AUDIO) { + lsx_fail("ffmpeg CODEC %x is not an audio CODEC", enc->codec_type); + return -1; + } +@@ -182,7 +182,7 @@ static int startread(sox_format_t * ft) + /* Find audio stream (FIXME: allow different stream to be selected) */ + for (i = 0; (unsigned)i < ffmpeg->ctxt->nb_streams; i++) { + AVCodecContext *enc = ffmpeg->ctxt->streams[i]->codec; +- if (enc->codec_type == CODEC_TYPE_AUDIO && ffmpeg->audio_index < 0) { ++ if (enc->codec_type == AVMEDIA_TYPE_AUDIO && ffmpeg->audio_index < 0) { + ffmpeg->audio_index = i; + break; + } +@@ -273,7 +273,7 @@ static AVStream *add_audio_stream(sox_fo + + c = st->codec; + c->codec_id = codec_id; +- c->codec_type = CODEC_TYPE_AUDIO; ++ c->codec_type = AVMEDIA_TYPE_AUDIO; + + /* put sample parameters */ + c->bit_rate = 256000; /* FIXME: allow specification */ +@@ -423,7 +423,7 @@ static size_t write_samples(sox_format_t + av_init_packet(&pkt); + pkt.size = avcodec_encode_audio(c, ffmpeg->audio_buf_aligned, AVCODEC_MAX_AUDIO_FRAME_SIZE, ffmpeg->samples); + pkt.pts = av_rescale_q(c->coded_frame->pts, c->time_base, ffmpeg->audio_st->time_base); +- pkt.flags |= PKT_FLAG_KEY; ++ pkt.flags |= AV_PKT_FLAG_KEY; + pkt.stream_index = ffmpeg->audio_st->index; + pkt.data = ffmpeg->audio_buf_aligned; + diff --git a/media-sound/sox/sox-14.3.2.ebuild b/media-sound/sox/sox-14.3.2.ebuild index 9079df4e18bd..f4973e07b718 100644 --- a/media-sound/sox/sox-14.3.2.ebuild +++ b/media-sound/sox/sox-14.3.2.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-sound/sox/sox-14.3.2.ebuild,v 1.3 2011/04/03 11:07:44 scarabeus Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/sox/sox-14.3.2.ebuild,v 1.4 2011/05/16 21:51:47 aballier Exp $ EAPI=2 inherit eutils flag-o-matic @@ -36,6 +36,7 @@ DEPEND="${RDEPEND} src_prepare() { epatch "${FILESDIR}"/${P}-uclibc.patch + epatch "${FILESDIR}"/${P}-ffmpeg.patch } src_configure() { |