From 3862479174f367317f91abe3ba15bdaf361075d8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20R=C4=99korajski?= Date: Wed, 28 Aug 2013 21:15:08 +0200 Subject: [PATCH] - fix building qith ffmpeg2 --- cinelerra-cv-ffmpeg2.patch | 218 +++++++++++++++++++++++++++++++++++++ cinelerra-cv.spec | 2 + 2 files changed, 220 insertions(+) create mode 100644 cinelerra-cv-ffmpeg2.patch diff --git a/cinelerra-cv-ffmpeg2.patch b/cinelerra-cv-ffmpeg2.patch new file mode 100644 index 0000000..01680ac --- /dev/null +++ b/cinelerra-cv-ffmpeg2.patch @@ -0,0 +1,218 @@ +https://bugs.gentoo.org/show_bug.cgi?id=479394 +By Helmut Jarausch + +--- cinelerra/ffmpeg.h.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ cinelerra/ffmpeg.h 2013-08-01 12:58:12.342474136 +0200 +@@ -26,7 +26,7 @@ + static int convert_cmodel_transfer(VFrame *frame_in,VFrame *frame_out); + static int init_picture_from_frame(AVPicture *picture, VFrame *frame); + +- static CodecID codec_id(char *codec_string); ++ static AVCodecID codec_id(char *codec_string); + + private: + static PixelFormat color_model_to_pix_fmt(int color_model); +--- cinelerra/ffmpeg.C.ORIG 2013-08-01 11:24:43.794419246 +0200 ++++ cinelerra/ffmpeg.C 2013-08-01 12:57:48.121473899 +0200 +@@ -25,7 +25,7 @@ + + avcodec_register_all(); + +- CodecID id = codec_id(codec_string); ++ AVCodecID id = codec_id(codec_string); + codec = avcodec_find_decoder(id); + if (codec == NULL) { + printf("FFMPEG::init no decoder for '%s'", codec_string); +@@ -51,7 +51,7 @@ + } + + +-CodecID FFMPEG::codec_id(char *codec_string) { ++AVCodecID FFMPEG::codec_id(char *codec_string) { + #define CODEC_IS(x) (! strncmp(codec_string, x, 4)) + + if (CODEC_IS(QUICKTIME_DV) || +--- quicktime/ffmpeg/ffmpeg.c.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/ffmpeg.c 2013-08-01 12:57:59.025474005 +0200 +@@ -2663,7 +2663,7 @@ + return 0; + } + +-static enum CodecID find_codec_or_die(const char *name, int type, int encoder) ++static enum AVCodecID find_codec_or_die(const char *name, int type, int encoder) + { + const char *codec_string = encoder ? "encoder" : "decoder"; + AVCodec *codec; +--- quicktime/ffmpeg/libavformat/electronicarts.c.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/libavformat/electronicarts.c 2013-08-01 13:00:57.855475755 +0200 +@@ -49,11 +49,11 @@ + typedef struct EaDemuxContext { + int big_endian; + +- enum CodecID video_codec; ++ enum AVCodecID video_codec; + AVRational time_base; + int video_stream_index; + +- enum CodecID audio_codec; ++ enum AVCodecID audio_codec; + int audio_stream_index; + int audio_frame_counter; + +--- quicktime/ffmpeg/libavformat/img2.c.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/libavformat/img2.c 2013-08-01 12:59:21.408474812 +0200 +@@ -34,7 +34,7 @@ + } VideoData; + + typedef struct { +- enum CodecID id; ++ enum AVCodecID id; + const char *str; + } IdStrMap; + +@@ -97,7 +97,7 @@ + } + return -1; + } +-static enum CodecID av_str2id(const IdStrMap *tags, const char *str) ++static enum AVCodecID av_str2id(const IdStrMap *tags, const char *str) + { + str= strrchr(str, '.'); + if(!str) return CODEC_ID_NONE; +@@ -175,7 +175,7 @@ + return 0; + } + +-enum CodecID av_guess_image2_codec(const char *filename){ ++enum AVCodecID av_guess_image2_codec(const char *filename){ + return av_str2id(img_tags, filename); + } + +--- quicktime/ffmpeg/libavformat/matroskadec.c.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/libavformat/matroskadec.c 2013-08-01 12:59:57.556475165 +0200 +@@ -2476,7 +2476,7 @@ + AVStream *st; + + for (i = 0; i < matroska->num_tracks; i++) { +- enum CodecID codec_id = CODEC_ID_NONE; ++ enum AVCodecID codec_id = CODEC_ID_NONE; + uint8_t *extradata = NULL; + int extradata_size = 0; + int extradata_offset = 0; +@@ -2495,7 +2495,7 @@ + } + } + +- /* Set the FourCC from the CodecID. */ ++ /* Set the FourCC from the AVCodecID. */ + /* This is the MS compatibility mode which stores a + * BITMAPINFOHEADER in the CodecPrivate. */ + if (!strcmp(track->codec_id, +@@ -2600,7 +2600,7 @@ + + if (codec_id == CODEC_ID_NONE) { + av_log(matroska->ctx, AV_LOG_INFO, +- "Unknown/unsupported CodecID %s.\n", ++ "Unknown/unsupported AVCodecID %s.\n", + track->codec_id); + } + +--- quicktime/ffmpeg/libavformat/matroska.h.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/libavformat/matroska.h 2013-08-01 13:00:22.218475407 +0200 +@@ -220,12 +220,12 @@ + + typedef struct CodecTags{ + char str[16]; +- enum CodecID id; ++ enum AVCodecID id; + }CodecTags; + + typedef struct CodecMime{ + char str[32]; +- enum CodecID id; ++ enum AVCodecID id; + }CodecMime; + + #define MATROSKA_CODEC_ID_VIDEO_VFW_FOURCC "V_MS/VFW/FOURCC" +--- quicktime/ffmpeg/libavformat/mov.c.ORIG 2012-07-06 22:40:26.000000000 +0200 ++++ quicktime/ffmpeg/libavformat/mov.c 2013-08-01 12:59:33.935474934 +0200 +@@ -678,7 +678,7 @@ + + for(pseudo_stream_id=0; pseudo_stream_id= 1.2.1 BuildRequires: OpenGL-GLU-devel @@ -105,6 +106,7 @@ Wersja społecznościowa. #%patch2 -p1 %patch3 -p1 %patch4 -p1 +%patch5 -p0 find -name Makefile.am | xargs %{__sed} -i -e 's#^LIBTOOL =.*##g' -- 2.43.0