Fails to build with ffmpeg 5.0
gegl is incompatible with ffmpeg API changes that made it into the 5.0 release.
../operations/external/ff-load.c:143:47: error: no member named 'codec' in 'struct AVStream'
if (p->video_stream && p->video_stream->codec)
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:144:9: warning: implicit declaration of function 'avcodec_close' is invalid in C99 [-Wimplicit-function-declaration]
avcodec_close (p->video_stream->codec);
^
../operations/external/ff-load.c:144:41: error: no member named 'codec' in 'struct AVStream'
avcodec_close (p->video_stream->codec);
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:145:47: error: no member named 'codec' in 'struct AVStream'
if (p->audio_stream && p->audio_stream->codec)
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:146:41: error: no member named 'codec' in 'struct AVStream'
avcodec_close (p->audio_stream->codec);
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:205:7: warning: implicit declaration of function 'avcodec_flush_buffers' is invalid in C99 [-Wimplicit-function-declaration]
avcodec_flush_buffers (p->audio_stream->codec);
^
../operations/external/ff-load.c:205:47: error: no member named 'codec' in 'struct AVStream'
avcodec_flush_buffers (p->audio_stream->codec);
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:224:27: warning: implicit declaration of function 'avcodec_decode_audio4' is invalid in C99 [-Wimplicit-function-declaration]
decoded_bytes = avcodec_decode_audio4(p->audio_stream->codec,
^
../operations/external/ff-load.c:224:66: error: no member named 'codec' in 'struct AVStream'
decoded_bytes = avcodec_decode_audio4(p->audio_stream->codec,
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:242:27: error: use of undeclared identifier 'AV_CH_LAYOUT_STEREO'
AV_CH_LAYOUT_STEREO, samples_left);
^
../operations/external/ff-load.c:244:41: error: no member named 'codec' in 'struct AVStream'
switch (p->audio_stream->codec->sample_fmt)
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:328:66: error: no member named 'codec' in 'struct AVStream'
, AV_TIME_BASE_Q, p->video_stream->time_base) / p->video_stream->codec->ticks_per_frame;
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:333:7: warning: implicit declaration of function 'avcodec_flush_buffers' is invalid in C99 [-Wimplicit-function-declaration]
avcodec_flush_buffers (p->video_stream->codec);
^
../operations/external/ff-load.c:333:47: error: no member named 'codec' in 'struct AVStream'
avcodec_flush_buffers (p->video_stream->codec);
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:357:27: warning: implicit declaration of function 'avcodec_decode_video2' is invalid in C99 [-Wimplicit-function-declaration]
decoded_bytes = avcodec_decode_video2 (
^
../operations/external/ff-load.c:358:35: error: no member named 'codec' in 'struct AVStream'
p->video_stream->codec, p->lavc_frame,
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:371:55: error: no member named 'cur_dts' in 'struct AVStream'
p->lavc_frame->pts = (p->video_stream->cur_dts -
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:372:55: error: no member named 'first_dts' in 'struct AVStream'
p->video_stream->first_dts);
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:468:26: warning: assigning to 'AVCodec *' (aka 'struct AVCodec *') from 'const AVCodec *' (aka 'const struct AVCodec *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
p->video_codec = avcodec_find_decoder (p->video_stream->codecpar->codec_id);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-load.c:471:28: error: no member named 'codec' in 'struct AVStream'
p->video_stream->codec->err_recognition = AV_EF_IGNORE_ERR |
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:471:53: error: use of undeclared identifier 'AV_EF_IGNORE_ERR'
p->video_stream->codec->err_recognition = AV_EF_IGNORE_ERR |
^
../operations/external/ff-load.c:472:53: error: use of undeclared identifier 'AV_EF_BITSTREAM'
AV_EF_BITSTREAM |
^
../operations/external/ff-load.c:473:53: error: use of undeclared identifier 'AV_EF_BUFFER'
AV_EF_BUFFER;
^
../operations/external/ff-load.c:474:28: error: no member named 'codec' in 'struct AVStream'
p->video_stream->codec->workaround_bugs = FF_BUG_AUTODETECT;
~~~~~~~~~~~~~~~ ^
../operations/external/ff-load.c:474:53: error: use of undeclared identifier 'FF_BUG_AUTODETECT'
p->video_stream->codec->workaround_bugs = FF_BUG_AUTODETECT;
^
../operations/external/ff-load.c:477:15: warning: implicit declaration of function 'avcodec_open2' is invalid in C99 [-Wimplicit-function-declaration]
if (avcodec_open2 (p->video_stream->codec, p->video_codec, NULL) < 0)
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
../operations/external/ff-save.c:250:7: warning: implicit declaration of function 'av_register_all' is invalid in C99 [-Wimplicit-function-declaration]
av_register_all ();
^
../operations/external/ff-save.c:251:7: warning: implicit declaration of function 'avcodec_register_all' is invalid in C99 [-Wimplicit-function-declaration]
avcodec_register_all ();
^
../operations/external/ff-save.c:295:11: error: no member named 'codec' in 'struct AVStream'
c = st->codec;
~~ ^
../operations/external/ff-save.c:313:11: error: no member named 'codec' in 'struct AVStream'
c = st->codec;
~~ ^
../operations/external/ff-save.c:316:9: warning: assigning to 'AVCodec *' (aka 'struct AVCodec *') from 'const AVCodec *' (aka 'const struct AVCodec *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
codec = avcodec_find_encoder (c->codec_id);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-save.c:337:23: error: use of undeclared identifier 'AV_CH_LAYOUT_STEREO'
c->channel_layout = AV_CH_LAYOUT_STEREO;
^
../operations/external/ff-save.c:396:29: error: no member named 'codec' in 'struct AVStream'
AVCodecContext *c = st->codec;
~~ ^
../operations/external/ff-save.c:473:11: warning: implicit declaration of function 'avcodec_encode_audio2' is invalid in C99 [-Wimplicit-function-declaration]
ret = avcodec_encode_audio2 (c, &pkt, frame, &got_packet);
^
../operations/external/ff-save.c:480:39: error: no member named 'codec' in 'struct AVStream'
av_packet_rescale_ts (&pkt, st->codec->time_base, st->time_base);
~~ ^
../operations/external/ff-save.c:495:27: error: no member named 'codec' in 'struct AVStream'
AVCodecContext *c = st->codec;
~~ ^
../operations/external/ff-save.c:552:22: error: no member named 'codec' in 'struct AVStream'
avcodec_close (st->codec);
~~ ^
../operations/external/ff-save.c:572:11: error: no member named 'codec' in 'struct AVStream'
c = st->codec;
~~ ^
../operations/external/ff-save.c:659:10: warning: implicit declaration of function 'avpicture_get_size' is invalid in C99 [-Wimplicit-function-declaration]
size = avpicture_get_size (pix_fmt, width + 1, height + 1);
^
../operations/external/ff-save.c:666:3: warning: implicit declaration of function 'avpicture_fill' is invalid in C99 [-Wimplicit-function-declaration]
avpicture_fill ((AVPicture *) picture, picture_buf, pix_fmt, width, height);
^
../operations/external/ff-save.c:666:31: error: expected expression
avpicture_fill ((AVPicture *) picture, picture_buf, pix_fmt, width, height);
^
../operations/external/ff-save.c:666:20: error: use of undeclared identifier 'AVPicture'; did you mean 'picture'?
avpicture_fill ((AVPicture *) picture, picture_buf, pix_fmt, width, height);
^~~~~~~~~
picture
../operations/external/ff-save.c:652:13: note: 'picture' declared here
AVFrame *picture;
^
../operations/external/ff-save.c:679:11: error: no member named 'codec' in 'struct AVStream'
c = st->codec;
~~ ^
../operations/external/ff-save.c:682:9: warning: assigning to 'AVCodec *' (aka 'struct AVCodec *') from 'const AVCodec *' (aka 'const struct AVCodec *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
codec = avcodec_find_encoder (c->codec_id);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-save.c:749:22: error: no member named 'codec' in 'struct AVStream'
avcodec_close (st->codec);
~~ ^
../operations/external/ff-save.c:781:11: error: no member named 'codec' in 'struct AVStream'
c = st->codec;
~~ ^
../operations/external/ff-save.c:848:18: warning: implicit declaration of function 'avcodec_encode_video2' is invalid in C99 [-Wimplicit-function-declaration]
out_size = avcodec_encode_video2(c, &pkt2, picture_ptr, &got_packet);
^
../operations/external/ff-save.c:850:41: error: no member named 'coded_frame' in 'struct AVCodecContext'
if (!out_size && got_packet && c->coded_frame)
~ ^
../operations/external/ff-save.c:852:14: error: no member named 'coded_frame' in 'struct AVCodecContext'
c->coded_frame->pts = pkt2.pts;
~ ^
../operations/external/ff-save.c:853:14: error: no member named 'coded_frame' in 'struct AVCodecContext'
c->coded_frame->key_frame = !!(pkt2.flags & AV_PKT_FLAG_KEY);
~ ^
../operations/external/ff-save.c:855:18: error: no member named 'coded_frame' in 'struct AVCodecContext'
c->coded_frame->pict_type = AV_PICTURE_TYPE_I;
~ ^
../operations/external/ff-save.c:875:18: error: no member named 'coded_frame' in 'struct AVCodecContext'
if (c->coded_frame->key_frame)
~ ^
../operations/external/ff-save.c:905:12: warning: assigning to 'AVOutputFormat *' (aka 'struct AVOutputFormat *') from 'const AVOutputFormat *' (aka 'const struct AVOutputFormat *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
p->fmt = av_guess_format (o->container_format, o->path, NULL);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-save.c:907:12: warning: assigning to 'AVOutputFormat *' (aka 'struct AVOutputFormat *') from 'const AVOutputFormat *' (aka 'const struct AVOutputFormat *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
p->fmt = av_guess_format (NULL, o->path, NULL);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-save.c:914:14: warning: assigning to 'AVOutputFormat *' (aka 'struct AVOutputFormat *') from 'const AVOutputFormat *' (aka 'const struct AVOutputFormat *') discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
p->fmt = av_guess_format ("mpeg", NULL, NULL);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../operations/external/ff-save.c:925:20: error: no member named 'filename' in 'struct AVFormatContext'
snprintf (p->oc->filename, sizeof (p->oc->filename), "%s", o->path);
~~~~~ ^
/usr/include/bits/stdio2.h:77:29: note: expanded from macro 'snprintf'
__builtin___snprintf_chk (str, len, __USE_FORTIFY_LEVEL - 1, \
^~~
fatal error: too many errors emitted, stopping now [-ferror-limit=]