diff options
author | Peter Alfredsen <loki_val@gentoo.org> | 2008-10-14 14:31:57 +0000 |
---|---|---|
committer | Peter Alfredsen <loki_val@gentoo.org> | 2008-10-14 14:31:57 +0000 |
commit | fc54bdf645a78602c1eaeb6acfc19711e2e287b8 (patch) | |
tree | ba23500857fb53f3eb95d20243fa2938b16a770e /media-plugins | |
parent | Sparc stable, Bug #241340 --- using '-i' flag because on non-sparc problems. (diff) | |
download | gentoo-2-fc54bdf645a78602c1eaeb6acfc19711e2e287b8.tar.gz gentoo-2-fc54bdf645a78602c1eaeb6acfc19711e2e287b8.tar.bz2 gentoo-2-fc54bdf645a78602c1eaeb6acfc19711e2e287b8.zip |
Bump to 0.10.5, take maintainership since it seems I'm stuck with it.
(Portage version: 2.2_rc12/cvs/Linux 2.6.27-rc8 x86_64)
Diffstat (limited to 'media-plugins')
6 files changed, 403 insertions, 1 deletions
diff --git a/media-plugins/gst-plugins-ffmpeg/ChangeLog b/media-plugins/gst-plugins-ffmpeg/ChangeLog index eab3ed49da2d..3c3d54bf1505 100644 --- a/media-plugins/gst-plugins-ffmpeg/ChangeLog +++ b/media-plugins/gst-plugins-ffmpeg/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for media-plugins/gst-plugins-ffmpeg # Copyright 2000-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-plugins/gst-plugins-ffmpeg/ChangeLog,v 1.86 2008/06/25 20:13:38 loki_val Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-plugins/gst-plugins-ffmpeg/ChangeLog,v 1.87 2008/10/14 14:31:57 loki_val Exp $ + +*gst-plugins-ffmpeg-0.10.5 (14 Oct 2008) + + 14 Oct 2008; Peter Alfredsen <loki_val@gentoo.org> + +files/0.10.5/lavc.patch, +files/0.10.5/offset.patch, + +files/0.10.5/system-ffmpeg-warning.patch, metadata.xml, + +gst-plugins-ffmpeg-0.10.5.ebuild: + Bump to 0.10.5, take maintainership since it seems I'm stuck with it. 25 Jun 2008; Peter Alfredsen <loki_val@gentoo.org> +files/0.10.4/system-ffmpeg-warning.patch, diff --git a/media-plugins/gst-plugins-ffmpeg/files/0.10.5/lavc.patch b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/lavc.patch new file mode 100644 index 000000000000..9729ac9f37ac --- /dev/null +++ b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/lavc.patch @@ -0,0 +1,233 @@ +Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcfg.c +=================================================================== +--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegcfg.c ++++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcfg.c +@@ -272,7 +272,9 @@ gst_ffmpeg_flags_get_type (void) + {CODEC_FLAG_GRAY, "Only decode/encode grayscale", "gray"}, + {CODEC_FLAG_NORMALIZE_AQP, + "Normalize Adaptive Quantization (masking, etc)", "aqp"}, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + {CODEC_FLAG_TRELLIS_QUANT, "Trellis Quantization", "trellis"}, ++#endif + {CODEC_FLAG_GLOBAL_HEADER, + "Global headers in extradata instead of every keyframe", + "global-headers"}, +@@ -669,6 +671,11 @@ gst_ffmpeg_cfg_init () + "Prediction Method", + GST_TYPE_FFMPEG_PRED_METHOD, FF_PRED_LEFT, G_PARAM_READWRITE); + gst_ffmpeg_add_pspec (pspec, config.prediction_method, FALSE, huffyuv, NULL); ++#if LIBAVCODEC_VERSION_INT >= ((52<<16)+(0<<8)+0) ++ pspec = g_param_spec_int ("trellis", "Trellis Quantization", ++ "Trellis RD quantization", 0, 1, 1, G_PARAM_READWRITE); ++ gst_ffmpeg_add_pspec (pspec, config.trellis, FALSE, mpeg, NULL); ++#endif + } + + /* ==== END CONFIGURATION SECTION ==== */ +Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcodecmap.c +=================================================================== +--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegcodecmap.c ++++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcodecmap.c +@@ -332,7 +332,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "depth", G_TYPE_INT, context->bits_per_sample, NULL); ++#else ++ "depth", G_TYPE_INT, context->bits_per_coded_sample, NULL); ++#endif + } + break; + +@@ -511,7 +515,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + caps = gst_ff_vid_caps_new (context, codec_id, "video/x-huffyuv", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "bpp", G_TYPE_INT, context->bits_per_sample, NULL); ++#else ++ "bpp", G_TYPE_INT, context->bits_per_coded_sample, NULL); ++#endif + } + break; + +@@ -627,7 +635,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + "layout", G_TYPE_STRING, "microsoft", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL); ++#else ++ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL); ++#endif + } else { + gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 1, 64, NULL); + } +@@ -638,7 +650,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + "layout", G_TYPE_STRING, "quicktime", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL); ++#else ++ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL); ++#endif + } else { + gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 1, 64, NULL); + } +@@ -688,7 +704,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + caps = gst_ff_vid_caps_new (context, codec_id, "video/x-camtasia", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL); ++#else ++ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL); ++#endif + } else { + gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 8, 32, NULL); + } +@@ -1026,7 +1046,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + caps = gst_ff_aud_caps_new (context, codec_id, "audio/x-alac", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "samplesize", G_TYPE_INT, context->bits_per_sample, NULL); ++#else ++ "samplesize", G_TYPE_INT, context->bits_per_coded_sample, NULL); ++#endif + } + break; + +@@ -1049,7 +1073,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID + caps = gst_ff_aud_caps_new (context, codec_id, "audio/x-tta", NULL); + if (context) { + gst_caps_set_simple (caps, ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + "samplesize", G_TYPE_INT, context->bits_per_sample, NULL); ++#else ++ "samplesize", G_TYPE_INT, context->bits_per_coded_sample, NULL); ++#endif + } + break; + case CODEC_ID_VORBIS: +@@ -1416,7 +1444,11 @@ gst_ffmpeg_caps_to_pixfmt (const GstCaps + + gst_structure_get_int (structure, "width", &context->width); + gst_structure_get_int (structure, "height", &context->height); ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + gst_structure_get_int (structure, "bpp", &context->bits_per_sample); ++#else ++ gst_structure_get_int (structure, "bpp", &context->bits_per_coded_sample); ++#endif + + fps = gst_structure_get_value (structure, "framerate"); + if (fps != NULL && GST_VALUE_HOLDS_FRACTION (fps)) { +@@ -1647,7 +1679,11 @@ gst_ffmpeg_caps_with_codecid (enum Codec + gint depth; + + if (gst_structure_get_int (str, "depth", &depth)) { ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + context->bits_per_sample = depth; ++#else ++ context->bits_per_coded_sample = depth; ++#endif + } else { + GST_WARNING ("No depth field in caps %" GST_PTR_FORMAT, caps); + } +@@ -1680,7 +1716,11 @@ gst_ffmpeg_caps_with_codecid (enum Codec + context->bit_rate = bitrate; + } + case CODEC_ID_ALAC: ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + gst_structure_get_int (str, "samplesize", &context->bits_per_sample); ++#else ++ gst_structure_get_int (str, "samplesize", &context->bits_per_coded_sample); ++#endif + break; + + case CODEC_ID_DVVIDEO: +Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegdec.c +=================================================================== +--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegdec.c ++++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegdec.c +@@ -696,7 +696,11 @@ gst_ffmpegdec_setcaps (GstPad * pad, Gst + + /* workaround encoder bugs */ + ffmpegdec->context->workaround_bugs |= FF_BUG_AUTODETECT; ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + ffmpegdec->context->error_resilience = 1; ++#else ++ ffmpegdec->context->error_recognition = 1; ++#endif + + /* for slow cpus */ + ffmpegdec->context->lowres = ffmpegdec->lowres; +@@ -2423,7 +2427,7 @@ gst_ffmpegdec_register (GstPlugin * plug + AVCodec *in_plugin; + gint rank; + +- in_plugin = first_avcodec; ++ in_plugin = av_codec_next(NULL); + + GST_LOG ("Registering decoders"); + +@@ -2545,7 +2549,7 @@ gst_ffmpegdec_register (GstPlugin * plug + gst_caps_unref (sinkcaps); + if (srccaps) + gst_caps_unref (srccaps); +- in_plugin = in_plugin->next; ++ in_plugin = av_codec_next(in_plugin); + } + + GST_LOG ("Finished Registering decoders"); +Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegenc.c +=================================================================== +--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegenc.c ++++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegenc.c +@@ -306,8 +306,8 @@ gst_ffmpegenc_getcaps (GstPad * pad) + /* set some default properties */ + ctx->width = DEFAULT_WIDTH; + ctx->height = DEFAULT_HEIGHT; +- ctx->time_base.num = DEFAULT_FRAME_RATE_BASE; +- ctx->time_base.den = 25 * DEFAULT_FRAME_RATE_BASE; ++ ctx->time_base.num = 1; ++ ctx->time_base.den = 25; + ctx->bit_rate = DEFAULT_VIDEO_BITRATE; + /* makes it silent */ + ctx->strict_std_compliance = -1; +@@ -391,7 +391,9 @@ gst_ffmpegenc_setcaps (GstPad * pad, Gst + + /* RTP payload used for GOB production (for Asterisk) */ + if (ffmpegenc->rtp_payload_size) { ++#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0) + ffmpegenc->context->rtp_mode = 1; ++#endif + ffmpegenc->context->rtp_payload_size = ffmpegenc->rtp_payload_size; + } + +@@ -944,13 +946,13 @@ gst_ffmpegenc_register (GstPlugin * plug + GType type; + AVCodec *in_plugin; + +- in_plugin = first_avcodec; + + GST_LOG ("Registering encoders"); + + /* build global ffmpeg param/property info */ + gst_ffmpeg_cfg_init (); + ++ in_plugin = av_codec_next(NULL); + while (in_plugin) { + gchar *type_name; + GstCaps *srccaps = NULL, *sinkcaps = NULL; +@@ -1027,7 +1029,7 @@ gst_ffmpegenc_register (GstPlugin * plug + gst_caps_unref (sinkcaps); + if (srccaps) + gst_caps_unref (srccaps); +- in_plugin = in_plugin->next; ++ in_plugin = av_codec_next(in_plugin); + } + + GST_LOG ("Finished registering encoders"); diff --git a/media-plugins/gst-plugins-ffmpeg/files/0.10.5/offset.patch b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/offset.patch new file mode 100644 index 000000000000..63b8c2271bf8 --- /dev/null +++ b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/offset.patch @@ -0,0 +1,15 @@ +Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegprotocol.c +=================================================================== +--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegprotocol.c ++++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegprotocol.c +@@ -175,8 +175,8 @@ gst_ffmpegdata_write (URLContext * h, un + return size; + } + +-static offset_t +-gst_ffmpegdata_seek (URLContext * h, offset_t pos, int whence) ++static int64_t ++gst_ffmpegdata_seek (URLContext * h, int64_t pos, int whence) + { + GstProtocolInfo *info; + guint64 newpos; diff --git a/media-plugins/gst-plugins-ffmpeg/files/0.10.5/system-ffmpeg-warning.patch b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/system-ffmpeg-warning.patch new file mode 100644 index 000000000000..e44173737d73 --- /dev/null +++ b/media-plugins/gst-plugins-ffmpeg/files/0.10.5/system-ffmpeg-warning.patch @@ -0,0 +1,72 @@ +diff -NrU5 gst-ffmpeg-0.10.5.orig/configure gst-ffmpeg-0.10.5/configure +--- gst-ffmpeg-0.10.5.orig/configure 2008-10-14 15:37:05.000000000 +0200 ++++ gst-ffmpeg-0.10.5/configure 2008-10-14 15:38:00.000000000 +0200 +@@ -17231,68 +17231,10 @@ + _ACEOF + + HAVE_FFMPEG_UNINSTALLED=0 + { $as_echo "$as_me:$LINENO: Using system-installed FFMpeg code" >&5 + $as_echo "$as_me: Using system-installed FFMpeg code" >&6;} +- { $as_echo "$as_me:$LINENO: WARNING: +- ====================================================================== +- WARNING: you have chosen to build gst-ffmpeg against a random +- external version of ffmpeg instead of building it against the tested +- internal ffmpeg snapshot that is included with gst-ffmpeg. +- +- This is a very bad idea. So bad in fact that words cannot express +- just how bad it is. Suffice to say that it is BAD. +- +- The GStreamer developers cannot and will not support a gst-ffmpeg +- built this way. Any bug reports that indicate there is an external +- version of ffmpeg involved will be closed immediately without further +- investigation. +- +- The reason such a setup can't be supported is that the ffmpeg API +- and ABI is in constant flux, yet there aren't any official releases +- of the ffmpeg library to develop against. This makes it impossible +- to guarantee that gst-ffmpeg will work reliably, or even compile, +- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles +- and superficially appears to work fine against your chosen external +- ffmpeg version, that might just not be the case on other systems, or +- even the same system at a later time, or when using decoders, +- encoders, demuxers or muxers that have not been tested. +- +- Please do not create or distribute binary packages of gst-ffmpeg +- that link against an external ffmpeg. Thank you! +- ====================================================================== +- " >&5 +-$as_echo "$as_me: WARNING: +- ====================================================================== +- WARNING: you have chosen to build gst-ffmpeg against a random +- external version of ffmpeg instead of building it against the tested +- internal ffmpeg snapshot that is included with gst-ffmpeg. +- +- This is a very bad idea. So bad in fact that words cannot express +- just how bad it is. Suffice to say that it is BAD. +- +- The GStreamer developers cannot and will not support a gst-ffmpeg +- built this way. Any bug reports that indicate there is an external +- version of ffmpeg involved will be closed immediately without further +- investigation. +- +- The reason such a setup can't be supported is that the ffmpeg API +- and ABI is in constant flux, yet there aren't any official releases +- of the ffmpeg library to develop against. This makes it impossible +- to guarantee that gst-ffmpeg will work reliably, or even compile, +- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles +- and superficially appears to work fine against your chosen external +- ffmpeg version, that might just not be the case on other systems, or +- even the same system at a later time, or when using decoders, +- encoders, demuxers or muxers that have not been tested. +- +- Please do not create or distribute binary packages of gst-ffmpeg +- that link against an external ffmpeg. Thank you! +- ====================================================================== +- " >&2;} +- +- sleep 15 + else + + source "$srcdir/ffmpegrev" + + { $as_echo "$as_me:$LINENO: Using ffmpeg revision $FFMPEG_REVISION" >&5 diff --git a/media-plugins/gst-plugins-ffmpeg/gst-plugins-ffmpeg-0.10.5.ebuild b/media-plugins/gst-plugins-ffmpeg/gst-plugins-ffmpeg-0.10.5.ebuild new file mode 100644 index 000000000000..0c26cb1952e4 --- /dev/null +++ b/media-plugins/gst-plugins-ffmpeg/gst-plugins-ffmpeg-0.10.5.ebuild @@ -0,0 +1,70 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-plugins/gst-plugins-ffmpeg/gst-plugins-ffmpeg-0.10.5.ebuild,v 1.1 2008/10/14 14:31:57 loki_val Exp $ + +inherit flag-o-matic eutils base + +PD=${FILESDIR}/${PV} +MY_PN=${PN/-plugins} +MY_P=${MY_PN}-${PV} + +# Create a major/minor combo for SLOT +PVP=(${PV//[-\._]/ }) +SLOT=${PVP[0]}.${PVP[1]} +#SLOT=0.10 + +DESCRIPTION="FFmpeg based gstreamer plugin" +HOMEPAGE="http://gstreamer.freedesktop.org/modules/gst-ffmpeg.html" +SRC_URI="http://gstreamer.freedesktop.org/src/${MY_PN}/${MY_P}.tar.bz2" + +LICENSE="GPL-2" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" +IUSE="" + +S=${WORKDIR}/${MY_P} + +RDEPEND=">=media-libs/gstreamer-0.10.4 + >=media-libs/gst-plugins-base-0.10.4 + >=dev-libs/liboil-0.3.6 + >=media-video/ffmpeg-0.4.9_p20081014" +DEPEND="${RDEPEND} + dev-util/pkgconfig" + +PATCHES=( "${PD}/offset.patch" + "${PD}/lavc.patch" + "${PD}/system-ffmpeg-warning.patch" + ) + +src_unpack() { + unpack ${A} + cd "${S}" + base_src_unpack autopatch + sed -i \ + -e 's,ffmpeg/avformat.h,libavformat/avformat.h,' \ + -e 's,ffmpeg/avcodec.h,libavcodec/avcodec.h,' \ + -e 's,ffmpeg/swscale.h,libswscale/swscale.h,' \ + -e 's,postproc/postprocess.h,libpostproc/postprocess.h,' \ + ext/ffmpeg/gst* \ + ext/libpostproc/gstpostproc.c \ + || die "404. No files found." +} + +src_compile() { + # Restrictions taken from the mplayer ebuild + # See bug #64262 for more info + # let's play the filtration game! + filter-flags -fPIE -fPIC -fstack-protector -fforce-addr -momit-leaf-frame-pointer -msse2 -msse3 -falign-functions -fweb + # ugly optimizations cause MPlayer to cry on x86 systems! + if use x86 ; then + replace-flags -O0 -O2 + replace-flags -O3 -O2 + fi + + econf --with-system-ffmpeg + emake || die "emake failed." +} + +src_install() { + emake DESTDIR="${D}" install || die "emake install failed." + dodoc AUTHORS ChangeLog NEWS README TODO +} diff --git a/media-plugins/gst-plugins-ffmpeg/metadata.xml b/media-plugins/gst-plugins-ffmpeg/metadata.xml index 3abe2ca2733e..a8473f337e5b 100644 --- a/media-plugins/gst-plugins-ffmpeg/metadata.xml +++ b/media-plugins/gst-plugins-ffmpeg/metadata.xml @@ -3,4 +3,8 @@ <pkgmetadata> <herd>gstreamer</herd> <herd>gnome</herd> +<maintainer> + <email>loki_val@gentoo.org</email> + <name>Peter Alfredsen</name> +</maintainer> </pkgmetadata> |