marlam / bino

3D video player with support for 180°/360° video and Virtual Reality
https://bino3d.org
GNU General Public License v3.0
45 stars 14 forks source link

Does not compile with latest FFMPEG #9

Closed jose1711 closed 3 years ago

jose1711 commented 3 years ago

Compilation of the latest dev version on Arch Linux terminates with error due to FFMPEG changes:

make[4]: Leaving directory '/home/jose/tmp/bino-git/src/bino-git/src/base'
make[4]: Entering directory '/home/jose/tmp/bino-git/src/bino-git/src'
  CXX      media_data.o
  CXX      media_object.o
media_object.cpp: In constructor ‘media_object::media_object(bool)’:
media_object.cpp:348:21: warning: ‘void av_register_all()’ is deprecated [-Wdeprecated-declarations]
  348 |     av_register_all();
      |                     ^
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:2050:6: note: declared here
 2050 | void av_register_all(void);
      |      ^~~~~~~~~~~~~~~
media_object.cpp: In member function ‘void media_object::open(const string&, const device_request&)’:
media_object.cpp:886:70: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
  886 |         AVCodecContext *codec_ctx = _ffmpeg->format_ctx->streams[i]->codec;
      |                                                                      ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:886:70: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
  886 |         AVCodecContext *codec_ctx = _ffmpeg->format_ctx->streams[i]->codec;
      |                                                                      ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:886:70: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
  886 |         AVCodecContext *codec_ctx = _ffmpeg->format_ctx->streams[i]->codec;
      |                                                                      ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:908:60: error: ‘CODEC_CAP_DR1’ was not declared in this scope; did you mean ‘AV_CODEC_CAP_DR1’?
  908 |             if (lowres || (codec && (codec->capabilities & CODEC_CAP_DR1)))
      |                                                            ^~~~~~~~~~~~~
      |                                                            AV_CODEC_CAP_DR1
media_object.cpp:909:37: error: ‘CODEC_FLAG_EMU_EDGE’ was not declared in this scope
  909 |                 codec_ctx->flags |= CODEC_FLAG_EMU_EDGE;
      |                                     ^~~~~~~~~~~~~~~~~~~
media_object.cpp:950:98: warning: ‘int avpicture_get_size(AVPixelFormat, int, int)’ is deprecated [-Wdeprecated-declarations]
  950 |                         _ffmpeg->video_codec_ctxs[j]->width, _ffmpeg->video_codec_ctxs[j]->height));
      |                                                                                                  ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3739:5: note: declared here
 3739 | int avpicture_get_size(enum AVPixelFormat pix_fmt, int width, int height);
      |     ^~~~~~~~~~~~~~~~~~
media_object.cpp:953:105: warning: ‘int avpicture_fill(AVPicture*, const uint8_t*, AVPixelFormat, int, int)’ is deprecated [-Wdeprecated-declarations]
  953 |                     frame_fmt, _ffmpeg->video_codec_ctxs[j]->width, _ffmpeg->video_codec_ctxs[j]->height);
      |                                                                                                         ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3724:5: note: declared here
 3724 | int avpicture_fill(AVPicture *picture, const uint8_t *ptr,
      |     ^~~~~~~~~~~~~~
media_object.cpp:962:98: warning: ‘int avpicture_get_size(AVPixelFormat, int, int)’ is deprecated [-Wdeprecated-declarations]
  962 |                         _ffmpeg->video_codec_ctxs[j]->width, _ffmpeg->video_codec_ctxs[j]->height);
      |                                                                                                  ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3739:5: note: declared here
 3739 | int avpicture_get_size(enum AVPixelFormat pix_fmt, int width, int height);
      |     ^~~~~~~~~~~~~~~~~~
media_object.cpp:974:115: warning: ‘int avpicture_fill(AVPicture*, const uint8_t*, AVPixelFormat, int, int)’ is deprecated [-Wdeprecated-declarations]
  974 |                         AV_PIX_FMT_BGRA, _ffmpeg->video_codec_ctxs[j]->width, _ffmpeg->video_codec_ctxs[j]->height);
      |                                                                                                                   ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3724:5: note: declared here
 3724 | int avpicture_fill(AVPicture *picture, const uint8_t *ptr,
      |     ^~~~~~~~~~~~~~
media_object.cpp: In member function ‘virtual void read_thread::run()’:
media_object.cpp:1353:42: warning: ‘int av_dup_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1353 |                 if (av_dup_packet(&packet) < 0)
      |                                          ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:509:5: note: declared here
  509 | int av_dup_packet(AVPacket *pkt);
      |     ^~~~~~~~~~~~~
media_object.cpp:1382:46: warning: ‘int av_dup_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1382 |                     if (av_dup_packet(&packet) < 0)
      |                                              ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:509:5: note: declared here
  509 | int av_dup_packet(AVPacket *pkt);
      |     ^~~~~~~~~~~~~
media_object.cpp:1412:46: warning: ‘int av_dup_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1412 |                     if (av_dup_packet(&packet) < 0)
      |                                              ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:509:5: note: declared here
  509 | int av_dup_packet(AVPacket *pkt);
      |     ^~~~~~~~~~~~~
media_object.cpp:1428:35: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1428 |             av_free_packet(&packet);
      |                                   ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp: In member function ‘virtual void video_decode_thread::run()’:
media_object.cpp:1494:68: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1494 |             av_free_packet(&(_ffmpeg->video_packets[_video_stream]));
      |                                                                    ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:1502:61: warning: ‘int avcodec_decode_video2(AVCodecContext*, AVFrame*, int*, const AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1502 |                     &(_ffmpeg->video_packets[_video_stream]));
      |                                                             ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3073:5: note: declared here
 3073 | int avcodec_decode_video2(AVCodecContext *avctx, AVFrame *picture,
      |     ^~~~~~~~~~~~~~~~~~~~~
media_object.cpp:1534:73: warning: ‘void av_picture_copy(AVPicture*, const AVPicture*, AVPixelFormat, int, int)’ is deprecated [-Wdeprecated-declarations]
 1534 |                         _ffmpeg->video_codec_ctxs[_video_stream]->height);
      |                                                                         ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3745:6: note: declared here
 3745 | void av_picture_copy(AVPicture *dst, const AVPicture *src,
      |      ^~~~~~~~~~~~~~~
media_object.cpp: In member function ‘virtual void audio_decode_thread::run()’:
media_object.cpp:1656:60: warning: ‘int avcodec_decode_audio4(AVCodecContext*, AVFrame*, int*, const AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1656 |                         &audioframe, &got_frame, &tmppacket);
      |                                                            ^
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:3024:5: note: declared here
 3024 | int avcodec_decode_audio4(AVCodecContext *avctx, AVFrame *frame,
      |     ^~~~~~~~~~~~~~~~~~~~~
media_object.cpp:1716:35: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1716 |             av_free_packet(&packet);
      |                                   ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp: In member function ‘virtual void subtitle_decode_thread::run()’:
media_object.cpp:1806:39: warning: ‘AVPacket::convergence_duration’ is deprecated [-Wdeprecated-declarations]
 1806 |             int64_t duration = packet.convergence_duration * 1000000
      |                                       ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:384:13: note: declared here
  384 |     int64_t convergence_duration;
      |             ^~~~~~~~~~~~~~~~~~~~
media_object.cpp:1806:39: warning: ‘AVPacket::convergence_duration’ is deprecated [-Wdeprecated-declarations]
 1806 |             int64_t duration = packet.convergence_duration * 1000000
      |                                       ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:384:13: note: declared here
  384 |     int64_t convergence_duration;
      |             ^~~~~~~~~~~~~~~~~~~~
media_object.cpp:1806:39: warning: ‘AVPacket::convergence_duration’ is deprecated [-Wdeprecated-declarations]
 1806 |             int64_t duration = packet.convergence_duration * 1000000
      |                                       ^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:384:13: note: declared here
  384 |     int64_t convergence_duration;
      |             ^~~~~~~~~~~~~~~~~~~~
media_object.cpp:1855:72: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1855:72: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1855:72: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1855:77: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                             ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1855:77: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                             ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1855:77: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1855 |                     std::memcpy(&(box.images.back().palette[0]), rect->pict.data[1],
      |                                                                             ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1857:56: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1857:56: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1857:56: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                        ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1857:61: warning: ‘AVPicture::linesize’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                             ^~~~~~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2631:9: note: declared here
 2631 |     int linesize[AV_NUM_DATA_POINTERS];     ///< number of bytes per line
      |         ^~~~~~~~
media_object.cpp:1857:61: warning: ‘AVPicture::linesize’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                             ^~~~~~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2631:9: note: declared here
 2631 |     int linesize[AV_NUM_DATA_POINTERS];     ///< number of bytes per line
      |         ^~~~~~~~
media_object.cpp:1857:61: warning: ‘AVPicture::linesize’ is deprecated [-Wdeprecated-declarations]
 1857 |                     box.images.back().linesize = rect->pict.linesize[0];
      |                                                             ^~~~~~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2631:9: note: declared here
 2631 |     int linesize[AV_NUM_DATA_POINTERS];     ///< number of bytes per line
      |         ^~~~~~~~
media_object.cpp:1859:69: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                     ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1859:69: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                     ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1859:69: warning: ‘AVSubtitleRect::pict’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                     ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2671:15: note: declared here
 2671 |     AVPicture pict;
      |               ^~~~
media_object.cpp:1859:74: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                          ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1859:74: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                          ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1859:74: warning: ‘AVPicture::data’ is deprecated [-Wdeprecated-declarations]
 1859 |                     std::memcpy(&(box.images.back().data[0]), rect->pict.data[0],
      |                                                                          ^~~~
In file included from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/avcodec.h:2629:14: note: declared here
 2629 |     uint8_t *data[AV_NUM_DATA_POINTERS];    ///< pointers to the image data planes
      |              ^~~~
media_object.cpp:1892:31: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1892 |         av_free_packet(&packet);
      |                               ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp: In member function ‘void media_object::seek(int64_t)’:
media_object.cpp:1945:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1945 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->video_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1945:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1945 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->video_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1945:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1945 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->video_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1948:63: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1948 |             av_free_packet(&_ffmpeg->video_packet_queues[i][j]);
      |                                                               ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:1954:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1954 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->audio_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1954:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1954 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->audio_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1954:88: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1954 |         avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->audio_streams[i]]->codec);
      |                                                                                        ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1958:63: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1958 |             av_free_packet(&_ffmpeg->audio_packet_queues[i][j]);
      |                                                               ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:1964:73: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1964 |         if (_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec->codec_id != AV_CODEC_ID_TEXT)
      |                                                                         ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1964:73: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1964 |         if (_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec->codec_id != AV_CODEC_ID_TEXT)
      |                                                                         ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1964:73: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1964 |         if (_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec->codec_id != AV_CODEC_ID_TEXT)
      |                                                                         ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1967:95: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1967 |             avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec);
      |                                                                                               ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1967:95: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1967 |             avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec);
      |                                                                                               ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1967:95: warning: ‘AVStream::codec’ is deprecated [-Wdeprecated-declarations]
 1967 |             avcodec_flush_buffers(_ffmpeg->format_ctx->streams[_ffmpeg->subtitle_streams[i]]->codec);
      |                                                                                               ^~~~~
In file included from media_object.cpp:30:
/usr/include/libavformat/avformat.h:880:21: note: declared here
  880 |     AVCodecContext *codec;
      |                     ^~~~~
media_object.cpp:1972:66: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 1972 |             av_free_packet(&_ffmpeg->subtitle_packet_queues[i][j]);
      |                                                                  ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp: In member function ‘void media_object::close()’:
media_object.cpp:2070:71: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 2070 |                     av_free_packet(&_ffmpeg->video_packet_queues[i][j]);
      |                                                                       ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:2075:60: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 2075 |                 av_free_packet(&(_ffmpeg->video_packets[i]));
      |                                                            ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:2093:71: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 2093 |                     av_free_packet(&_ffmpeg->audio_packet_queues[i][j]);
      |                                                                       ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
media_object.cpp:2116:74: warning: ‘void av_free_packet(AVPacket*)’ is deprecated [-Wdeprecated-declarations]
 2116 |                     av_free_packet(&_ffmpeg->subtitle_packet_queues[i][j]);
      |                                                                          ^
In file included from /usr/include/libavcodec/bsf.h:30,
                 from /usr/include/libavcodec/avcodec.h:44,
                 from /usr/include/libavformat/avformat.h:312,
                 from media_object.cpp:30:
/usr/include/libavcodec/packet.h:538:6: note: declared here
  538 | void av_free_packet(AVPacket *pkt);
      |      ^~~~~~~~~~~~~~
make[4]: *** [Makefile:807: media_object.o] Error 1
make[4]: Leaving directory '/home/jose/tmp/bino-git/src/bino-git/src'

Environment: Arch Linux, x86_64, ffmpeg 2:4.3.2-5

marlam commented 3 years ago

Hi, this problem was fixed in 844a2413740464fe87e4f99e7c18090db7578ca8 in August 2018. The code that triggers this is deactivated since then. Please recheck if you have the latest version.

jose1711 commented 3 years ago

Thank you, looks PKGBUILD in AUR is for some reason using git on Savannah :frowning: