Your message dated Mon, 11 Jan 2016 17:41:17 +0000
with message-id <[email protected]>
and subject line Bug#803846: fixed in opal 3.10.10~dfsg2-2
has caused the Debian Bug report #803846,
regarding opal: FTBFS with FFmpeg 2.9
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
803846: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=803846
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: opal
Version: 3.10.10~dfsg2-1
Severity: important
Tags: patch
User: [email protected]
Usertags: ffmpeg2.9

Dear Maintainer,

your package fails to build with the upcoming ffmpeg 2.9.
This bug will become release-critical at some point when the
ffmpeg2.9 transition gets closer.

Attached is a patch replacing the deprecated functionality.
It also works with ffmpeg 2.8.
Please apply this patch and forward it upstream, if necessary.

These changes have little regression potential.

Best regards,
Andreas

diff --git a/debian/patches/ffmpeg_2.9.patch b/debian/patches/ffmpeg_2.9.patch
new file mode 100644
index 0000000..96c293b
--- /dev/null
+++ b/debian/patches/ffmpeg_2.9.patch
@@ -0,0 +1,171 @@
+Description: Replace deprecated FFmpeg API
+Author: Andreas Cadhalpun <[email protected]>
+Last-Update: <2015-11-02>
+
+--- opal-3.10.10~dfsg2.orig/plugins/video/H.263-1998/h263-1998.cxx
++++ opal-3.10.10~dfsg2/plugins/video/H.263-1998/h263-1998.cxx
+@@ -230,11 +230,10 @@ bool H263_Base_EncoderContext::Init(AVCo
+ 
+   m_context->opaque = this;
+ 
+-  m_context->flags = CODEC_FLAG_EMU_EDGE   // don't draw edges
+-                   | CODEC_FLAG_TRUNCATED  // Possible missing packets
++  m_context->flags = CODEC_FLAG_TRUNCATED  // Possible missing packets
+                    ;
+ 
+-  m_context->pix_fmt = PIX_FMT_YUV420P;
++  m_context->pix_fmt = AV_PIX_FMT_YUV420P;
+   m_context->gop_size = H263_KEY_FRAME_INTERVAL;
+ 
+   // X-Lite does not like Custom Picture frequency clocks... stick to 29.97Hz
+@@ -440,9 +439,6 @@ bool H263_Base_EncoderContext::OpenCodec
+   m_inputFrame->data[1] = m_inputFrame->data[0] + planeSize;
+   m_inputFrame->data[2] = m_inputFrame->data[1] + (planeSize / 4);
+ 
+-  if (m_context->width > 352)
+-    m_context->flags &= ~CODEC_FLAG_EMU_EDGE; // Totally bizarre! FFMPEG crashes if on for CIF4
+-
+   // Dump info
+   PTRACE(5, m_prefix, "Size is " << m_context->width << "x" << m_context->height);
+   PTRACE(5, m_prefix, "GOP is " << m_context->gop_size);
+@@ -456,7 +452,7 @@ bool H263_Base_EncoderContext::OpenCodec
+   PTRACE(5, m_prefix, "qmax set to " << m_context->qmax);
+   PTRACE(5, m_prefix, "payload size set to " << m_context->rtp_payload_size);
+ 
+-  return FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec) == 0;
++  return FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec, NULL) == 0;
+ }
+ 
+ void H263_Base_EncoderContext::CloseCodec()
+@@ -707,7 +703,7 @@ bool H263_Base_DecoderContext::OpenCodec
+     return 0;
+   }
+ 
+-  if (FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec) < 0) {
++  if (FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec, NULL) < 0) {
+     PTRACE(1, m_prefix, "Failed to open H.263 decoder");
+     return false;
+   }
+--- opal-3.10.10~dfsg2.orig/plugins/video/H.264/h264-x264.cxx
++++ opal-3.10.10~dfsg2/plugins/video/H.264/h264-x264.cxx
+@@ -1074,7 +1074,6 @@ class MyDecoder : public PluginCodec<MY_
+       m_context->workaround_bugs = FF_BUG_AUTODETECT;
+       m_context->idct_algo = FF_IDCT_AUTO;
+       m_context->error_concealment = FF_EC_GUESS_MVS | FF_EC_DEBLOCK;
+-      m_context->flags = CODEC_FLAG_INPUT_PRESERVED | CODEC_FLAG_EMU_EDGE;
+       m_context->flags2 = 
+ #ifdef CODEC_FLAG2_DROP_FRAME_TIMECODE
+                           CODEC_FLAG2_DROP_FRAME_TIMECODE |
+@@ -1084,7 +1083,7 @@ class MyDecoder : public PluginCodec<MY_
+       if ((m_picture = FFMPEGLibraryInstance.AvcodecAllocFrame()) == NULL)
+         return false;
+ 
+-      if (FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec) < 0)
++      if (FFMPEGLibraryInstance.AvcodecOpen(m_context, m_codec, NULL) < 0)
+         return false;
+ 
+       PTRACE(4, MY_CODEC_LOG, "Opened decoder (SVN $Revision: 28048 $)");
+--- opal-3.10.10~dfsg2.orig/plugins/video/MPEG4-ffmpeg/mpeg4.cxx
++++ opal-3.10.10~dfsg2/plugins/video/MPEG4-ffmpeg/mpeg4.cxx
+@@ -539,7 +539,7 @@ void MPEG4EncoderContext::ResetBitCounte
+ //
+ 
+ void MPEG4EncoderContext::SetStaticEncodingParams(){
+-    m_avcontext->pix_fmt = PIX_FMT_YUV420P;
++    m_avcontext->pix_fmt = AV_PIX_FMT_YUV420P;
+     m_avcontext->mb_decision = FF_MB_DECISION_SIMPLE;    // high quality off
+     m_avcontext->rtp_payload_size = 750;                 // ffh263 uses 750
+     m_avcontext->rtp_callback = &MPEG4EncoderContext::RtpCallback;
+@@ -595,7 +595,6 @@ void MPEG4EncoderContext::SetStaticEncod
+     m_avcontext->flags|=CODEC_FLAG_AC_PRED;
+     /*c->flags|=CODEC_FLAG_QPEL;*/ /*don't enable this one: this forces profile_level to advanced simple profile */
+     m_avcontext->flags|=CODEC_FLAG_4MV;
+-    m_avcontext->flags|=CODEC_FLAG_GMC;
+     m_avcontext->flags|=CODEC_FLAG_LOOP_FILTER;
+ #endif
+     m_avcontext->opaque = this;              // for use in RTP callback
+@@ -710,13 +709,15 @@ bool MPEG4EncoderContext::OpenCodec()
+   if (PTRACE_CHECK(4)) {
+     m_avcontext->debug |= FF_DEBUG_RC;
+     m_avcontext->debug |= FF_DEBUG_PICT_INFO;
+-    m_avcontext->debug |= FF_DEBUG_MV;
++//    m_avcontext->debug |= FF_DEBUG_MV;
+   }
+ #endif
+   
+   SetStaticEncodingParams();
+   SetDynamicEncodingParams(false);    // don't force a restart, it's not open
+-  if (FFMPEGLibraryInstance.AvcodecOpen(m_avcontext, m_avcodec) < 0)
++  AVDictionary *opts = NULL;
++  av_dict_set_int(&opts, "gmc", 1, 0);
++  if (FFMPEGLibraryInstance.AvcodecOpen(m_avcontext, m_avcodec, &opts) < 0)
+   {
+     PTRACE(1, "MPEG4", "Encoder could not be opened");
+     return false;
+@@ -1411,7 +1412,7 @@ bool MPEG4DecoderContext::OpenCodec()
+ 
+     SetStaticDecodingParams();
+     SetDynamicDecodingParams(false);    // don't force a restart, it's not open
+-    if (FFMPEGLibraryInstance.AvcodecOpen(m_avcontext, m_avcodec) < 0) {
++    if (FFMPEGLibraryInstance.AvcodecOpen(m_avcontext, m_avcodec, NULL) < 0) {
+         PTRACE(1, "MPEG4", "Decoder failed to open");
+         return false;
+     }
+--- opal-3.10.10~dfsg2.orig/plugins/video/common/dyna.cxx
++++ opal-3.10.10~dfsg2/plugins/video/common/dyna.cxx
+@@ -291,14 +291,14 @@ AVFrame *FFMPEGLibrary::AvcodecAllocFram
+ {
+   WaitAndSignal m(processLock);
+ 
+-  return avcodec_alloc_frame();
++  return av_frame_alloc();
+ }
+ 
+-int FFMPEGLibrary::AvcodecOpen(AVCodecContext *ctx, AVCodec *codec)
++int FFMPEGLibrary::AvcodecOpen(AVCodecContext *ctx, AVCodec *codec, AVDictionary **options)
+ {
+   WaitAndSignal m(processLock);
+ 
+-  return avcodec_open2(ctx, codec, NULL);
++  return avcodec_open2(ctx, codec, options);
+ }
+ 
+ int FFMPEGLibrary::AvcodecClose(AVCodecContext *ctx)
+@@ -344,7 +344,15 @@ void FFMPEGLibrary::AvSetDimensions(AVCo
+ {
+   WaitAndSignal m(processLock);
+ 
+-  avcodec_set_dimensions(s, width, height);
++  if (av_image_check_size(width, height, 0, s) < 0) {
++    av_log(s, AV_LOG_WARNING, "Failed to set dimensions %d %d\n", width, height);
++    width = height = 0;
++  }
++
++  s->coded_width  = width;
++  s->coded_height = height;
++  s->width        = (width + (1 << av_codec_get_lowres(s)) - 1) >> av_codec_get_lowres(s);
++  s->height       = (height + (1 << av_codec_get_lowres(s)) - 1) >> av_codec_get_lowres(s);
+ }
+ 
+ void FFMPEGLibrary::AvLogSetLevel(int level)
+--- opal-3.10.10~dfsg2.orig/plugins/video/common/dyna.h
++++ opal-3.10.10~dfsg2/plugins/video/common/dyna.h
+@@ -97,7 +97,7 @@ class FFMPEGLibrary
+     AVCodec *AvcodecFindDecoder(enum AVCodecID id);
+     AVCodecContext *AvcodecAllocContext(AVCodec*);
+     AVFrame *AvcodecAllocFrame(void);
+-    int AvcodecOpen(AVCodecContext *ctx, AVCodec *codec);
++    int AvcodecOpen(AVCodecContext *ctx, AVCodec *codec, AVDictionary **options);
+     int AvcodecClose(AVCodecContext *ctx);
+     int AvcodecEncodeVideo(AVCodecContext *ctx, BYTE *buf, int buf_size, const AVFrame *pict);
+     int AvcodecDecodeVideo(AVCodecContext *ctx, AVFrame *pict, int *got_picture_ptr, BYTE *buf, int buf_size);
+--- opal-3.10.10~dfsg2.orig/plugins/video/common/ffmpeg.h
++++ opal-3.10.10~dfsg2/plugins/video/common/ffmpeg.h
+@@ -47,6 +47,7 @@
+ 
+ extern "C" {
+ #include <libavcodec/avcodec.h>
++#include <libavutil/imgutils.h>
+ // AVPacket was declared in avformat.h before April 2009
+ #if LIBAVCODEC_VERSION_INT <= AV_VERSION_INT(52, 25, 0)
+ #include <libavformat/avformat.h>
diff --git a/debian/patches/series b/debian/patches/series
index 94f0b29..db4ef65 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -2,3 +2,4 @@ disable-samples-ftbfs.diff
 plugins_clean_target.patch
 libav9.patch
 libav10.patch
+ffmpeg_2.9.patch

--- End Message ---
--- Begin Message ---
Source: opal
Source-Version: 3.10.10~dfsg2-2

We believe that the bug you reported is fixed in the latest version of
opal, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Eugen Dedu <[email protected]> (supplier of updated opal package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Mon, 11 Jan 2016 15:51:57 +0100
Source: opal
Binary: libopal3.10.10 libopal-dev simpleopal libopal-dbg libopal-doc
Architecture: source amd64 all
Version: 3.10.10~dfsg2-2
Distribution: unstable
Urgency: low
Maintainer: Debian VoIP Team <[email protected]>
Changed-By: Eugen Dedu <[email protected]>
Description:
 libopal-dbg - OPAL library debug symbols
 libopal-dev - OPAL library header files
 libopal-doc - OPAL library documentation files
 libopal3.10.10 - Open Phone Abstraction Library - successor of OpenH323
 simpleopal - Simple example from the OPAL project
Closes: 803846
Changes:
 opal (3.10.10~dfsg2-2) unstable; urgency=low
 .
   * Fix FTBFS with upcoming ffmpeg 2.9, patch from A. Cadhalpun (Closes:
     #803846).
Checksums-Sha1:
 c37f4be98a883310d7f28ffa5aecd9cc22f6a424 2540 opal_3.10.10~dfsg2-2.dsc
 fcbd0763d38fdebd156c27cfefa39486cbd189ae 26408 
opal_3.10.10~dfsg2-2.debian.tar.xz
 5822b9b3e76ab642fedbe9d32563bcae21f63d17 779030 
libopal-dbg_3.10.10~dfsg2-2_amd64.deb
 65c68dc90fca35d1ebbdb76e3a36b3fa347c313d 4611352 
libopal-dev_3.10.10~dfsg2-2_amd64.deb
 70b23d4918b4446004736efa91ac0bab1d06ad14 3977332 
libopal-doc_3.10.10~dfsg2-2_all.deb
 0a347df5a95a0c7ba2893fb945459b6a1c3f7500 3411220 
libopal3.10.10_3.10.10~dfsg2-2_amd64.deb
 deec33ec4086d4e5454fe058fc52aeeb3ea85bea 67678 
simpleopal_3.10.10~dfsg2-2_amd64.deb
Checksums-Sha256:
 2455badb6781077da5de80cf4e491cfa67cfadfe7b901c51793d960d4220e0db 2540 
opal_3.10.10~dfsg2-2.dsc
 c0e5513f363b96334b402e684550c6820c2a73bc63649442962d995088fa4861 26408 
opal_3.10.10~dfsg2-2.debian.tar.xz
 2cf2fb6811b1df61eb02744a751e47e04a48697ae0d90a34fa00a763366627a0 779030 
libopal-dbg_3.10.10~dfsg2-2_amd64.deb
 ba580ab2a761a967473588432cc133d3273170adc936e11a6c7a09cd6eaf1d8b 4611352 
libopal-dev_3.10.10~dfsg2-2_amd64.deb
 1269519a837c07a08521d1f3b406db58e8dd0c3cc41a60013f51b053b77cea2d 3977332 
libopal-doc_3.10.10~dfsg2-2_all.deb
 6bd58b3db6ea0fe59ed008d69906df6cb09434acb076164432eec8ce419d6e51 3411220 
libopal3.10.10_3.10.10~dfsg2-2_amd64.deb
 8a04e6c9b6a66e6fe9bc5b0e1f380ae25f5f8c7a239481dd25105f49aedaae02 67678 
simpleopal_3.10.10~dfsg2-2_amd64.deb
Files:
 2f0c20b2b7dca49ef55c59964dab033a 2540 libs optional opal_3.10.10~dfsg2-2.dsc
 b08dc31c28fa8d5523ef01ba439d750e 26408 libs optional 
opal_3.10.10~dfsg2-2.debian.tar.xz
 c5e33c40f1bf24eda96aa379be92ad12 779030 debug extra 
libopal-dbg_3.10.10~dfsg2-2_amd64.deb
 3c3f5bcec51b0480c52748649f6f1741 4611352 libdevel optional 
libopal-dev_3.10.10~dfsg2-2_amd64.deb
 01fc535561c047f0591818b0278e7d17 3977332 doc extra 
libopal-doc_3.10.10~dfsg2-2_all.deb
 995e92f8c26844d39e8c65180cd31928 3411220 libs optional 
libopal3.10.10_3.10.10~dfsg2-2_amd64.deb
 fc08377c369bf21823ec5b1501461596 67678 comm optional 
simpleopal_3.10.10~dfsg2-2_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJWk9A+AAoJEACrBnrke3mkxicP/Rbv9Sr+BQrXPEGdDwi3MSiR
EcTtB8EJH1vXAemS2JCRff+oX2gzvqZoSEI3BK4+tPb+Xn74sKlOUfCbPZDEDpwx
TSRhhayf8rB33PaRfdT4E4v+jaAmq1lesSHVSsFzpWFuKnOnD5eOTd78U1e80rjz
tYsta3HQyzbhieObolPhEj1Eucmd//j95+plTMI7aq03Esm4N5grKR+CYuQsDiX7
sl7kfR3qi1HwKeUv6edZOQqGePdKIeG/C239I6IiN5+lBveP7e2KLTmzPXlzzxEJ
byNYuJFjtmaoFqSiMIdwnYSG9UJAlPcxpKGO8OrDDA7YFQEDHlkUBCYWKrSyJSa4
7s7/BKxeQbSYnKVR3BblNGcNye/0WpbkdBvRIAOuqyW3SjUsdB9pYCj8MktWhe7G
PRWrHl3xr8F6OkXL6Eu3Xi/KerG/P87exe3LKAB01epipvLFP7yQqlvtCiPlTShO
UVyWYdwC6OWD8s/i+pqUAIzjJN7b3NDZRGin4q3+nGxb7diSe3vfoNf0ByM+SKaM
mavHMdG2UulRqu9F2UgRue6/cXvv3TfmV91uJSBTjFI3rtzEZvpFgTj79z25qahh
PEyb2eQx5EgHpVF6430eErj0fcFdjFDLOiXmHA5sqTDM1UyhegTOOjU4zvyAlId7
qby7SNaedmi495TzvrkV
=8xiE
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to