src/videostream.cpp: In member function ‘virtual int VideoStream::encodeData(AVFrame*)’: src/videostream.cpp:362:23: warning: ‘void av_init_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations] 362 | av_init_packet(&pkt); | ~~~~~~~~~~~~~~^~~~~~ In file included from /usr/include/libavformat/avformat.h:316, from src/abstractstream.h:27, from src/videostream.h:23, from src/videostream.cpp:37: /usr/include/libavcodec/packet.h:506:6: note: declared here 506 | void av_init_packet(AVPacket *pkt); | ^~~~~~~~~~~~~~ src/mediawriterffmpeg.cpp: In constructor ‘MediaWriterFFmpegGlobal::MediaWriterFFmpegGlobal()’: src/mediawriterffmpeg.cpp:1245:5: error: ‘av_register_all’ was not declared in this scope 1245 | av_register_all(); | ^~~~~~~~~~~~~~~ src/mediawriterffmpeg.cpp:1246:5: error: ‘avcodec_register_all’ was not declared in this scope 1246 | avcodec_register_all(); | ^~~~~~~~~~~~~~~~~~~~ src/mediawriterffmpeg.cpp: In member function ‘SupportedCodecsType MediaWriterFFmpegGlobal::initSupportedCodecs()’: src/mediawriterffmpeg.cpp:1451:28: error: ‘av_oformat_next’ was not declared in this scope; did you mean ‘av_opt_next’? 1451 | while ((outputFormat = av_oformat_next(outputFormat))) { | ^~~~~~~~~~~~~~~ | av_opt_next src/mediawriterffmpeg.cpp:1454:25: error: ‘av_codec_next’ was not declared in this scope; did you mean ‘av_opt_next’? 1454 | while ((codec = av_codec_next(codec))) { | ^~~~~~~~~~~~~ | av_opt_next src/mediawriterffmpeg.cpp: In member function ‘QMap<QString, QMap<QString, QVariant> > MediaWriterFFmpegGlobal::initCodecDefaults()’: src/mediawriterffmpeg.cpp:1541:23: error: ‘av_codec_next’ was not declared in this scope; did you mean ‘av_opt_next’? 1541 | for (auto codec = av_codec_next(nullptr); | ^~~~~~~~~~~~~ | av_opt_next make[4]: *** [Makefile:801: debug/Qt5.15.2/x86_64-pc-linux-gnu-gpp/x86_64/obj/mediawriterffmpeg.o] Error 1 make[4]: *** Waiting for unfinished jobs.... src/abstractstream.cpp: In constructor ‘AbstractStream::AbstractStream(const AVFormatContext*, uint, int, const QVariantMap&, const QMap<QString, QMap<QString, QVariant> >&, MediaWriterFFmpeg*, QObject*)’: src/abstractstream.cpp:104:50: error: invalid conversion from ‘const AVCodec*’ to ‘AVCodec*’ [-fpermissive] 104 | AVCodec *codec = avcodec_find_encoder_by_name(codecName.toStdString().c_str()); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | const AVCodec* make[4]: *** [Makefile:816: debug/Qt5.15.2/x86_64-pc-linux-gnu-gpp/x86_64/obj/abstractstream.o] Error 1 make[4]: Leaving directory '/var/tmp/portage/media-video/webcamoid-8.7.1-r1/work/webcamoid-8.7.1/libAvKys/Plugins/MultiSink/src/ffmpeg' make[3]: *** [Makefile:92: sub-src-ffmpeg-make_first-ordered] Error 2 make[3]: Leaving directory '/var/tmp/portage/media-video/webcamoid-8.7.1-r1/work/webcamoid-8.7.1/libAvKys/Plugins/MultiSink' Reproducible: Always
Created attachment 766093 [details] build.log.gz
Created attachment 766094 [details] emerge-info.txt
Compiles fine with: * USE=ffmpeg and ffmpeg-4.4.1 * USE=-ffmpeg and ffmpeg-5.0
Note that this appears to be fixed in latest master, including the most recent 9.0.0 release. Probably not worth attempting to backport, so let's wait for Maintainer Needed to get the latest release in the tree ;)
see https://bugs.gentoo.org/833518