[Bf-blender-cvs] [1af722b8191] master: Deps builder: macOS/ ffmpeg: Fix linker warning

Ankit Meel noreply at git.blender.org
Tue Jul 6 17:44:06 CEST 2021


Commit: 1af722b819120312ac0e709635032005a31bcc28
Author: Ankit Meel
Date:   Tue Jul 6 21:13:31 2021 +0530
Branches: master
https://developer.blender.org/rB1af722b819120312ac0e709635032005a31bcc28

Deps builder: macOS/ ffmpeg: Fix linker warning

ld: warning: could not create compact unwind for _ff_rl_init_vlc: stack
subq instruction is too different from dwarf stack size
Similar to rB2de5de57c58521862e0fecc95fc474ea347b7468

Differential Revision: https://developer.blender.org/D11796

===================================================================

M	build_files/build_environment/patches/ffmpeg.diff

===================================================================

diff --git a/build_files/build_environment/patches/ffmpeg.diff b/build_files/build_environment/patches/ffmpeg.diff
index e195ca272de..5a50a3f8756 100644
--- a/build_files/build_environment/patches/ffmpeg.diff
+++ b/build_files/build_environment/patches/ffmpeg.diff
@@ -68,3 +68,32 @@
 +
      return ret;
  }
+--- a/libavcodec/rl.c
++++ b/libavcodec/rl.c
+@@ -71,7 +71,7 @@ av_cold void ff_rl_init(RLTable *rl,
+ av_cold void ff_rl_init_vlc(RLTable *rl, unsigned static_size)
+ {
+     int i, q;
+-    VLC_TYPE table[1500][2] = {{0}};
++    VLC_TYPE (*table)[2] = av_calloc(sizeof(VLC_TYPE), 1500 * 2);
+     VLC vlc = { .table = table, .table_allocated = static_size };
+     av_assert0(static_size <= FF_ARRAY_ELEMS(table));
+     init_vlc(&vlc, 9, rl->n + 1, &rl->table_vlc[0][1], 4, 2, &rl->table_vlc[0][0], 4, 2, INIT_VLC_USE_NEW_STATIC);
+@@ -80,8 +80,10 @@ av_cold void ff_rl_init_vlc(RLTable *rl, unsigned static_size)
+         int qmul = q * 2;
+         int qadd = (q - 1) | 1;
+ 
+-        if (!rl->rl_vlc[q])
++        if (!rl->rl_vlc[q]){
++            av_free(table);
+             return;
++        }
+ 
+         if (q == 0) {
+             qmul = 1;
+@@ -113,4 +115,5 @@ av_cold void ff_rl_init_vlc(RLTable *rl, unsigned static_size)
+             rl->rl_vlc[q][i].run   = run;
+         }
+     }
++    av_free(table);
+ }



More information about the Bf-blender-cvs mailing list