diff options
author | Alexis Ballier <aballier@gentoo.org> | 2013-08-06 22:32:44 +0000 |
---|---|---|
committer | Alexis Ballier <aballier@gentoo.org> | 2013-08-06 22:32:44 +0000 |
commit | 300a969d7a483dd3c2d5484355171d0fd1e524b5 (patch) | |
tree | ffbae1f96bdb9d9991e3a9b86f09c97008257a91 /media-libs/libquicktime | |
parent | Fix EPREFIX handling (thanks Leho Kraav, bug 465226), version bump. (diff) | |
download | gentoo-2-300a969d7a483dd3c2d5484355171d0fd1e524b5.tar.gz gentoo-2-300a969d7a483dd3c2d5484355171d0fd1e524b5.tar.bz2 gentoo-2-300a969d7a483dd3c2d5484355171d0fd1e524b5.zip |
backport upstream fixes to build against ffmpeg 2, bug #476498
(Portage version: 2.2.0_alpha194/cvs/Linux x86_64, signed Manifest commit with key 160F534A)
Diffstat (limited to 'media-libs/libquicktime')
-rw-r--r-- | media-libs/libquicktime/ChangeLog | 6 | ||||
-rw-r--r-- | media-libs/libquicktime/files/libquicktime-1.2.4-ffmpeg2.patch | 98 | ||||
-rw-r--r-- | media-libs/libquicktime/libquicktime-1.2.4.ebuild | 5 |
3 files changed, 106 insertions, 3 deletions
diff --git a/media-libs/libquicktime/ChangeLog b/media-libs/libquicktime/ChangeLog index 47e9532bc29d..e8c57167eda7 100644 --- a/media-libs/libquicktime/ChangeLog +++ b/media-libs/libquicktime/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for media-libs/libquicktime # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/libquicktime/ChangeLog,v 1.192 2013/04/04 09:10:37 aballier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/libquicktime/ChangeLog,v 1.193 2013/08/06 22:32:44 aballier Exp $ + + 06 Aug 2013; Alexis Ballier <aballier@gentoo.org> libquicktime-1.2.4.ebuild, + +files/libquicktime-1.2.4-ffmpeg2.patch: + backport upstream fixes to build against ffmpeg 2, bug #476498 04 Apr 2013; Alexis Ballier <aballier@gentoo.org> -libquicktime-1.2.3-r1.ebuild: diff --git a/media-libs/libquicktime/files/libquicktime-1.2.4-ffmpeg2.patch b/media-libs/libquicktime/files/libquicktime-1.2.4-ffmpeg2.patch new file mode 100644 index 000000000000..7add44220a2b --- /dev/null +++ b/media-libs/libquicktime/files/libquicktime-1.2.4-ffmpeg2.patch @@ -0,0 +1,98 @@ +Extracted from upstream CVS. +https://bugs.gentoo.org/show_bug.cgi?id=476498 + +Index: libquicktime-1.2.4/plugins/ffmpeg/audio.c +=================================================================== +--- libquicktime-1.2.4.orig/plugins/ffmpeg/audio.c ++++ libquicktime-1.2.4/plugins/ffmpeg/audio.c +@@ -45,6 +45,11 @@ + #define ENCODE_AUDIO 1 + #endif + ++#ifndef AVCODEC_MAX_AUDIO_FRAME_SIZE ++/* from libavcodec/avcodec.h dated Dec 23 2012 */ ++#define AVCODEC_MAX_AUDIO_FRAME_SIZE 192000 // 1 second of 48khz 32bit audio ++#endif ++ + /* The following code was ported from gmerlin_avdecoder (http://gmerlin.sourceforge.net) */ + + /* MPEG Audio header parsing code */ +Index: libquicktime-1.2.4/plugins/ffmpeg/params.c +=================================================================== +--- libquicktime-1.2.4.orig/plugins/ffmpeg/params.c ++++ libquicktime-1.2.4/plugins/ffmpeg/params.c +@@ -101,6 +101,17 @@ typedef struct + } \ + } + ++#define PARAM_DICT_INT(name, dict_name) \ ++ { \ ++ if(!strcasecmp(name, key)) \ ++ { \ ++ char buf[128]; \ ++ snprintf(buf, sizeof(buf), "%d", *(int*)value); \ ++ av_dict_set(options, dict_name, buf, 0); \ ++ found = 1; \ ++ } \ ++ } ++ + #define PARAM_DICT_FLAG(name, dict_name) \ + { \ + if(!strcasecmp(name, key)) \ +@@ -202,8 +213,15 @@ void lqt_ffmpeg_set_parameter(AVCodecCon + PARAM_INT("ff_max_b_frames",max_b_frames); + PARAM_FLOAT("ff_b_quant_factor",b_quant_factor); + PARAM_INT("ff_b_frame_strategy",b_frame_strategy); ++ ++#if LIBAVCODEC_VERSION_MAJOR >= 55 ++ PARAM_DICT_INT("ff_luma_elim_threshold","luma_elim_threshold"); ++ PARAM_DICT_INT("ff_chroma_elim_threshold","chroma_elim_threshold"); ++#else + PARAM_INT("ff_luma_elim_threshold",luma_elim_threshold); + PARAM_INT("ff_chroma_elim_threshold",chroma_elim_threshold); ++#endif ++ + PARAM_INT("ff_strict_std_compliance",strict_std_compliance); + PARAM_QP2LAMBDA("ff_b_quant_offset",b_quant_offset); + PARAM_INT("ff_rc_min_rate",rc_min_rate); +@@ -241,8 +259,15 @@ void lqt_ffmpeg_set_parameter(AVCodecCon + PARAM_QP2LAMBDA("ff_lmax", lmax); + PARAM_INT("ff_noise_reduction",noise_reduction); + PARAM_INT_SCALE("ff_rc_initial_buffer_occupancy",rc_initial_buffer_occupancy,1000); ++ ++#if LIBAVCODEC_VERSION_MAJOR >= 55 ++ PARAM_DICT_INT("ff_inter_threshold","inter_threshold"); ++ PARAM_DICT_INT("ff_quantizer_noise_shaping","quantizer_noise_shaping"); ++#else + PARAM_INT("ff_inter_threshold",inter_threshold); + PARAM_INT("ff_quantizer_noise_shaping",quantizer_noise_shaping); ++#endif ++ + PARAM_INT("ff_thread_count",thread_count); + PARAM_INT("ff_me_threshold",me_threshold); + PARAM_INT("ff_mb_threshold",mb_threshold); +@@ -272,8 +297,16 @@ void lqt_ffmpeg_set_parameter(AVCodecCon + PARAM_FLAG("ff_flag_bitexact",CODEC_FLAG_BITEXACT); + PARAM_FLAG("ff_flag_ac_pred",CODEC_FLAG_AC_PRED); + // PARAM_FLAG("ff_flag_h263p_umv",CODEC_FLAG_H263P_UMV); // Unused ++ ++#if LIBAVCODEC_VERSION_MAJOR >= 55 ++ PARAM_DICT_FLAG("ff_flag_cbp_rd","cbp_rd"); ++ PARAM_DICT_FLAG("ff_flag_qp_rd","qp_rd"); ++ PARAM_DICT_FLAG("ff_flag2_strict_gop","strict_gop"); ++#else + PARAM_FLAG("ff_flag_cbp_rd",CODEC_FLAG_CBP_RD); + PARAM_FLAG("ff_flag_qp_rd",CODEC_FLAG_QP_RD); ++ PARAM_FLAG2("ff_flag2_strict_gop",CODEC_FLAG2_STRICT_GOP); ++#endif + + #if LIBAVCODEC_VERSION_MAJOR >= 54 + PARAM_DICT_FLAG("ff_flag_h263p_aiv", "aiv"); +@@ -288,7 +321,6 @@ void lqt_ffmpeg_set_parameter(AVCodecCon + PARAM_FLAG("ff_flag_loop_filter",CODEC_FLAG_LOOP_FILTER); + PARAM_FLAG("ff_flag_closed_gop",CODEC_FLAG_CLOSED_GOP); + PARAM_FLAG2("ff_flag2_fast",CODEC_FLAG2_FAST); +- PARAM_FLAG2("ff_flag2_strict_gop",CODEC_FLAG2_STRICT_GOP); + PARAM_ENUM("ff_coder_type",coder_type,coder_type); + + } diff --git a/media-libs/libquicktime/libquicktime-1.2.4.ebuild b/media-libs/libquicktime/libquicktime-1.2.4.ebuild index cb20e829de0d..36bd95a863a0 100644 --- a/media-libs/libquicktime/libquicktime-1.2.4.ebuild +++ b/media-libs/libquicktime/libquicktime-1.2.4.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/libquicktime/libquicktime-1.2.4.ebuild,v 1.11 2013/02/02 22:49:46 ago Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/libquicktime/libquicktime-1.2.4.ebuild,v 1.12 2013/08/06 22:32:44 aballier Exp $ EAPI=4 inherit libtool eutils @@ -51,7 +51,8 @@ REQUIRED_USE="opengl? ( X )" DOCS="ChangeLog README TODO" src_prepare() { - epatch "${FILESDIR}"/${P}+libav-9.patch + epatch "${FILESDIR}"/${P}+libav-9.patch \ + "${FILESDIR}"/${P}-ffmpeg2.patch elibtoolize # Required for .so versioning on g/fbsd } |