diff options
author | Alexis Ballier <aballier@gentoo.org> | 2013-02-08 21:39:11 +0000 |
---|---|---|
committer | Alexis Ballier <aballier@gentoo.org> | 2013-02-08 21:39:11 +0000 |
commit | bfda094700fa9e020969a4bb2d1afdda2b6e551d (patch) | |
tree | 218c7ac4859cd357ba4cd26db342a838f311d363 /media-video | |
parent | Document the src_unpack() function. Requested in bug #456160. (diff) | |
download | historical-bfda094700fa9e020969a4bb2d1afdda2b6e551d.tar.gz historical-bfda094700fa9e020969a4bb2d1afdda2b6e551d.tar.bz2 historical-bfda094700fa9e020969a4bb2d1afdda2b6e551d.zip |
fix build with recent ffmpeg versions, bug #456232
Package-Manager: portage-2.2.0_alpha161/cvs/Linux x86_64
Manifest-Sign-Key: 0x160F534A
Diffstat (limited to 'media-video')
-rw-r--r-- | media-video/vdr2jpeg/ChangeLog | 8 | ||||
-rw-r--r-- | media-video/vdr2jpeg/Manifest | 23 | ||||
-rw-r--r-- | media-video/vdr2jpeg/files/vdr2jpeg-0.1.9-ffmpeg1.patch | 238 | ||||
-rw-r--r-- | media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild | 7 |
4 files changed, 265 insertions, 11 deletions
diff --git a/media-video/vdr2jpeg/ChangeLog b/media-video/vdr2jpeg/ChangeLog index e749f52eb405..bf290656ec5e 100644 --- a/media-video/vdr2jpeg/ChangeLog +++ b/media-video/vdr2jpeg/ChangeLog @@ -1,6 +1,10 @@ # ChangeLog for media-video/vdr2jpeg -# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/vdr2jpeg/ChangeLog,v 1.27 2012/05/05 08:58:50 jdhore Exp $ +# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/media-video/vdr2jpeg/ChangeLog,v 1.28 2013/02/08 21:39:04 aballier Exp $ + + 08 Feb 2013; Alexis Ballier <aballier@gentoo.org> vdr2jpeg-0.1.9.ebuild, + +files/vdr2jpeg-0.1.9-ffmpeg1.patch: + fix build with recent ffmpeg versions, bug #456232 05 May 2012; Jeff Horelick <jdhore@gentoo.org> vdr2jpeg-0.1.9.ebuild: dev-util/pkgconfig -> virtual/pkgconfig diff --git a/media-video/vdr2jpeg/Manifest b/media-video/vdr2jpeg/Manifest index 9201dec36662..0ce473ceb091 100644 --- a/media-video/vdr2jpeg/Manifest +++ b/media-video/vdr2jpeg/Manifest @@ -1,6 +1,17 @@ -AUX vdr2jpeg-0.1.0-gcc43.patch 1252 RMD160 2f0007fe688eb966b8860d5398bd49b42264d1d8 SHA1 1122a3b6bc548620c386c86d952558a756706d5a SHA256 0569cdae060c33eac4b6f9afd0e473126409d749b36db44084ded97fbfcc1c57 -AUX vdr2jpeg-0.1.9-ffmpeg.patch 13036 RMD160 88b42812b0cdd457ac5bc2eb2e150948071888b8 SHA1 fe24f9eac0764a0b347ac23d7301bfec019a1a67 SHA256 7e476ffb59c6ee464360ec8ad02413da5b0d4adc7959a6ea568c4ecd121cfef3 -DIST vdr2jpeg-0.1.9.tgz 31160 RMD160 b0d23fb734a1dd33f862dc8bc52ba75dba7636cf SHA1 0dcd3fa225c4eca4406f9cba9e639c76b8f298da SHA256 869250e411def669aa89170ceff6bfbfd08c522bee9a8967799b4af60010ea79 -EBUILD vdr2jpeg-0.1.9.ebuild 863 RMD160 c6a3b3c98576bc12e85264b04f107c54bd78a891 SHA1 4818f87fe18f29a3cb6185479739300cf8fa0b22 SHA256 5403659f7f353e3d54a39c4992debf9af133a0d9bb86bef2b2239646bbdee72f -MISC ChangeLog 5028 RMD160 f4a9c0b72979ec7de2db1603706ba2453fc8741f SHA1 b5901f19c13793c4b78e434b123f5e5a7ac4b58d SHA256 6724c1d0a3231c72e2c068f6d0fe6b895e27678850e036145e4c17c86faeb5e3 -MISC metadata.xml 419 RMD160 bd2a9a036df1d8bca95a8a85af2f099919526ff6 SHA1 531deb1056f4eb7cb3190c551d78156a20b564c4 SHA256 da5fe630b58a0c3d2bc786901eda3cb8c875db655389a608438a6af30fa7a306 +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + +AUX vdr2jpeg-0.1.0-gcc43.patch 1252 SHA256 0569cdae060c33eac4b6f9afd0e473126409d749b36db44084ded97fbfcc1c57 SHA512 d2ad0b95b098d7c07583ae34af7133389e67117e55031d5a6151887bbb1d2f7f5f8596f34e8865c0a5eba5a71bdd77e299c518fdc9022f3482c97f0ceddd70e9 WHIRLPOOL 68816b149be0630c996f0c849bfd61d39c5c2e16a9d3ad6ddbfcf49c34fb02d330906bc12d7cd9219e68178f874e23e18c638e2b0fb6ddfd2ac2801c7fd9b01a +AUX vdr2jpeg-0.1.9-ffmpeg.patch 13036 SHA256 7e476ffb59c6ee464360ec8ad02413da5b0d4adc7959a6ea568c4ecd121cfef3 SHA512 0a7d261dffe1960bb69366b0645b0f5543a2ee82f821f34b3d70606689e971e29981ea5888870e0de9515da5e7419f6a919fc9ac9d82043cff587f0399de1070 WHIRLPOOL a0af8389c08cc6b8f79849ace9e41e5abe59812a27e3b12a0f4a7eabaa074a21ba24c5200bbc719a0cc6f2503e26ba7b2ec330ce6bfec301050b63141d778b3a +AUX vdr2jpeg-0.1.9-ffmpeg1.patch 8787 SHA256 4865aa2d9a9df25edee5dd270beeb9b0575360239a0720ce0bf346e52880d49a SHA512 d7ab3a5d5dff70d914036da98c42fa6931e71f54b88580bcfac84a81a2c256811d8c59e25b55e3bf3f2cfed1d6c3997c68e24b81b9d5ac7bc0c13b97693a5ee3 WHIRLPOOL 2b70797f0b25dc52e07e397d8217105d860f279106c37c4b42c365c27394773d27272fc5fe8f383b1db64597d44d5bedaea7c0d88980a615d59daab165265b88 +DIST vdr2jpeg-0.1.9.tgz 31160 SHA256 869250e411def669aa89170ceff6bfbfd08c522bee9a8967799b4af60010ea79 SHA512 e2309fd08591d5efa08246c2ecde70811036ea293e21f7e5ae989af5acef5e795216cbc31455d2f0b65de575a876863efe55ddf4397ab4eadf3d67a627579d99 WHIRLPOOL 1009060f15563d1b0c4d75f2e965f188efcc021cb28a12a7750096b2aa32e5d83fc8601b6246f29c35f87df39b1cf64f34be180b13275442a80d38301a3e03b1 +EBUILD vdr2jpeg-0.1.9.ebuild 902 SHA256 c040ae6a0446a03b6b9f932c79145e5af29a0c5c3b2f78eef6506b34ae64510c SHA512 39e05766cae769b38e48aca2911ad8caeb6bc671ae8990624f878a35470882c1e84f752f01bdde1782955b753e448ba692eef11ebcc7bb11a62d01331f1858d8 WHIRLPOOL 0e38932b41871f8d66143006e1277ca5be951cf485d455fd82304fff30f1e014c7f41d51b8ab4764dbadc5942eaff9bc27e8775f01d460da4b1e36e8d3c31fc7 +MISC ChangeLog 5198 SHA256 705700c16ea8ab9f696414fe6865a38d6b2ee18a5d710400e6b0309e7c57f86c SHA512 fd562a5dc4eeef8d683401303a217d0d1b23a853fc28184ea852b0ba39f5ab7c64bbd54e6c99ae4126e51cb217e43058dbf4d799676f01aba9015740f3b4ef59 WHIRLPOOL 7c8c0a3a052907313d16df46724be3476d566f24841f9dd3a6dd5695f3dbe16eab797a470150350184754ced7f4baf3dfb9249edb776375eb3d0825571e98e1a +MISC metadata.xml 419 SHA256 da5fe630b58a0c3d2bc786901eda3cb8c875db655389a608438a6af30fa7a306 SHA512 4de6439a4b9718af0ea2edd72451165180c94202c07b43ae193d7dbdb864e5b1560cfe96fcb6b732e5304df920e89c0dfe1c448f9c617d0e4201486fe1dd0e45 WHIRLPOOL f033c8874817cba8d7edfee65f01ffdbc4fbd9f9a7a28f35902c5e7ce412e9cb069c621830cf610583edd2f9d3baad0435cfa41dd3d7aad4e0bfbb9f2b3c14b9 +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.19 (GNU/Linux) + +iEYEAREIAAYFAlEVcHkACgkQvFcC4BYPU0qY3gCfVKhzWuTCceoaLlfdznIW1IPR +LT8AoI7ym0XY2khC5ob5NJJG17C4+Cm/ +=ben6 +-----END PGP SIGNATURE----- diff --git a/media-video/vdr2jpeg/files/vdr2jpeg-0.1.9-ffmpeg1.patch b/media-video/vdr2jpeg/files/vdr2jpeg-0.1.9-ffmpeg1.patch new file mode 100644 index 000000000000..4d032d89235e --- /dev/null +++ b/media-video/vdr2jpeg/files/vdr2jpeg-0.1.9-ffmpeg1.patch @@ -0,0 +1,238 @@ +Index: vdr2jpeg-0.1.9/ffm.cpp +=================================================================== +--- vdr2jpeg-0.1.9.orig/ffm.cpp ++++ vdr2jpeg-0.1.9/ffm.cpp +@@ -22,6 +22,7 @@ + extern "C" { + #include <libavutil/avutil.h> + #include <libavutil/mathematics.h> ++#include <libavutil/pixdesc.h> + #include <libavcodec/avcodec.h> + #include <libavformat/avformat.h> + #include <libswscale/swscale.h> +@@ -55,14 +56,12 @@ static int video_qdiff = 3; + static const char *video_rc_eq="tex^qComp"; + static int me_method = ME_EPZS; + +-static int same_quality = 1; + + static int top_field_first = -1; + + + + +-static float mux_preload= 0.5; + static float mux_max_delay= 0.7; + + static int64_t input_ts_offset = 0; +@@ -150,7 +149,7 @@ static bool do_video_out(AVFormatContext + int *frame_size) + { + int nb_frames, i, ret; +- AVFrame *final_picture, *formatted_picture, *resampling_dst, *padding_src; ++ AVFrame *final_picture, *formatted_picture, *resampling_dst; + AVFrame picture_crop_temp, picture_pad_temp; + AVCodecContext *enc, *dec; + +@@ -195,11 +194,9 @@ static bool do_video_out(AVFormatContext + } + + final_picture = formatted_picture; +- padding_src = formatted_picture; + resampling_dst = &ost->pict_tmp; + + if (ost->video_resample) { +- padding_src = NULL; + final_picture = &ost->pict_tmp; + sws_scale(ost->img_resample_ctx, formatted_picture->data, formatted_picture->linesize, + 0, ost->resample_height, resampling_dst->data, resampling_dst->linesize); +@@ -242,10 +239,7 @@ static bool do_video_out(AVFormatContext + + /* handles sameq here. This is not correct because it may + not be a global option */ +- if (same_quality) { +- big_picture.quality = (int)ist->st->quality; +- }else +- big_picture.quality = (int)ost->st->quality; ++ big_picture.quality = ist->st->codec->global_quality; + big_picture.pict_type = (AVPictureType) 0; + // big_picture.pts = AV_NOPTS_VALUE; + big_picture.pts= ost->sync_opts; +@@ -328,7 +322,7 @@ static int output_packet(AVInputStream * + + ret = avcodec_decode_video2(ist->st->codec, + &picture, &got_picture, &pkt); +- ist->st->quality= picture.quality; ++ ist->st->codec->global_quality= picture.quality; + if (ret < 0) + goto fail_decode; + if (!got_picture) { +@@ -618,31 +612,6 @@ static bool av_encode(AVFormatContext ** + codec = ost->st->codec; + icodec = ist->st->codec; + +- if (ost->st->stream_copy) { +- /* if stream_copy is selected, no need to decode or encode */ +- codec->codec_id = icodec->codec_id; +- codec->codec_type = icodec->codec_type; +- if(!codec->codec_tag) codec->codec_tag = icodec->codec_tag; +- codec->bit_rate = icodec->bit_rate; +- codec->extradata= icodec->extradata; +- codec->extradata_size= icodec->extradata_size; +- if(av_q2d(icodec->time_base) > av_q2d(ist->st->time_base) && av_q2d(ist->st->time_base) < 1.0/1000) +- codec->time_base = icodec->time_base; +- else +- codec->time_base = ist->st->time_base; +- switch(codec->codec_type) { +- case AVMEDIA_TYPE_VIDEO: +- codec->pix_fmt = icodec->pix_fmt; +- codec->width = icodec->width; +- codec->height = icodec->height; +- codec->has_b_frames = icodec->has_b_frames; +- break; +- case AVMEDIA_TYPE_SUBTITLE: +- break; +- default: +- return false; +- } +- } else { + switch(codec->codec_type) { + case AVMEDIA_TYPE_VIDEO: + ost->video_resample = ((codec->width != icodec->width) || +@@ -675,7 +644,6 @@ static bool av_encode(AVFormatContext ** + default: + return false; + } +- } + if(codec->codec_type == AVMEDIA_TYPE_VIDEO){ + int size= codec->width * codec->height; + bit_buffer_size= FFMAX(bit_buffer_size, 4*size); +@@ -690,7 +658,7 @@ static bool av_encode(AVFormatContext ** + /* dump the file output parameters - cannot be done before in case + of stream copy */ + for(i=0;i<nb_output_files;i++) { +- dump_format(output_files[i], i, output_files[i]->filename, 1); ++ av_dump_format(output_files[i], i, output_files[i]->filename, 1); + } + + /* open each encoder */ +@@ -749,7 +717,7 @@ static bool av_encode(AVFormatContext ** + /* open files and write file headers */ + for(i=0;i<nb_output_files;i++) { + os = output_files[i]; +- if (av_write_header(os) < 0) { ++ if (avformat_write_header(os,NULL) < 0) { + fprintf(stderr, "Could not write header for output file #%d (incorrect codec parameters ?)\n", i); + ret = false; //AVERROR(EINVAL); + goto fail; +@@ -941,36 +909,32 @@ void print_error(const char *filename, i + static bool opt_input_file(const char *filename) + { + AVFormatContext *ic; +- AVFormatParameters params, *ap = ¶ms; + int err, ret, rfps, rfps_base; + unsigned int i; + int64_t timestamp; ++ AVDictionary *opts = NULL; ++ char buf[1024]; + + /* get default parameters from command line */ + ic = avformat_alloc_context(); + +- memset(ap, 0, sizeof(*ap)); +- ap->prealloced_context = 1; +- ap->time_base.den = frame_rate; +- ap->time_base.num = frame_rate_base; +- ap->width = frame_width + 0 + 0; +- ap->height = frame_height + 0 + 0; +- ap->pix_fmt = frame_pix_fmt; +- ap->channel = 0; +- ap->standard = 0; ++ snprintf(buf, sizeof(buf), "%d/%d", frame_rate, frame_rate_base); ++ av_dict_set(&opts, "framerate", buf, 0); ++ snprintf(buf, sizeof(buf), "%dx%d", frame_width, frame_height); ++ av_dict_set(&opts, "video_size", buf, 0); ++ av_dict_set(&opts, "pixel_format", av_get_pix_fmt_name(frame_pix_fmt), 0); ++ + ic->video_codec_id = CODEC_ID_NONE; + if(pgmyuv_compatibility_hack) + ic->video_codec_id= CODEC_ID_PGMYUV; + + /* open the input file with generic libav function */ +- err = av_open_input_file(&ic, filename, file_iformat, 0, ap); ++ err = avformat_open_input(&ic, filename, file_iformat, &opts); + if (err < 0) { + print_error(filename, err); + return 0; + } + +- ic->loop_input = 0; +- + /* If not enough info to get the stream parameters, we decode the + first frames to get it. (used in mpeg case for example) */ + ret = av_find_stream_info(ic); +@@ -1027,7 +991,7 @@ static bool opt_input_file(const char *f + input_files_ts_offset[nb_input_files] = input_ts_offset - timestamp; + /* dump the file content */ + if (verbose >= 0) +- dump_format(ic, nb_input_files, filename, 0); ++ av_dump_format(ic, nb_input_files, filename, 0); + + nb_input_files++; + file_iformat = NULL; +@@ -1133,11 +1097,8 @@ static bool new_video_stream(AVFormatCon + + /* if (intra_only) + video_enc->gop_size = 0;*/ +- if (same_quality) { + video_enc->flags |= CODEC_FLAG_QSCALE; +- st->quality = FF_QP2LAMBDA; +- video_enc->global_quality= (int)st->quality; +- } ++ video_enc->global_quality= FF_QP2LAMBDA; + + video_enc->max_qdiff = video_qdiff; + video_enc->rc_eq = video_rc_eq; +@@ -1187,7 +1148,6 @@ static bool opt_output_file(const char * + { + AVFormatContext *oc; + int use_video, input_has_video = 0; +- AVFormatParameters params, *ap = ¶ms; + + oc = avformat_alloc_context(); + +@@ -1219,8 +1179,6 @@ static bool opt_output_file(const char * + return false; + } + +- oc->timestamp = 0; +- + } + + output_files[nb_output_files++] = oc; +@@ -1233,16 +1191,7 @@ static bool opt_output_file(const char * + } + } + +- memset(ap, 0, sizeof(*ap)); +- if (av_set_parameters(oc, ap) < 0) { +- fprintf(stderr, "%s: Invalid encoding parameters\n", +- oc->filename); +- return false; +- } +- +- oc->preload= (int)(mux_preload*AV_TIME_BASE); + oc->max_delay= (int)(mux_max_delay*AV_TIME_BASE); +- oc->loop_output = AVFMT_NOOUTPUTLOOP; + + /* reset some options */ + file_oformat = NULL; +@@ -1323,7 +1272,7 @@ bool decode (const char* szMPVfile, /* c + AVFormatContext *s = output_files[i]; + + if (!(s->oformat->flags & AVFMT_NOFILE)) +- url_fclose(s->pb); ++ avio_close(s->pb); + for(j=0;j<s->nb_streams;j++) + av_free(s->streams[j]); + av_free(s); diff --git a/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild b/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild index 24eab4d166e6..e2ac17e9198a 100644 --- a/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild +++ b/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild,v 1.6 2012/05/05 08:58:50 jdhore Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-video/vdr2jpeg/vdr2jpeg-0.1.9.ebuild,v 1.7 2013/02/08 21:39:04 aballier Exp $ EAPI=4 @@ -29,7 +29,8 @@ src_prepare() { -e "s:usr/local:usr:" \ -e "s:-o vdr2jpeg:\$(LDFLAGS) -o vdr2jpeg:" \ Makefile || die - epatch "${FILESDIR}/${P}-ffmpeg.patch" + epatch "${FILESDIR}/${P}-ffmpeg.patch" \ + "${FILESDIR}/${P}-ffmpeg1.patch" } src_install() { |