Skip to content

Conversation

@smanders
Copy link
Collaborator

smanders and others added 5 commits January 19, 2026 14:41
The alloc_size attribute is valid only on functions that return a
pointer.  GCC 9 (not yet released) warns about invalid usage:

./libavutil/mem.h:342:1: warning: 'alloc_size' attribute ignored on a function returning int' [-Wattributes]
  342 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size);
      | ^~~~~~~~~~~~~

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
@smanders
Copy link
Collaborator Author

smanders commented Jan 19, 2026

rocky10-gcc15 on amd64 build error

In file included from /__w/FFmpeg/FFmpeg/libavutil/common.h:426,
                 from /__w/FFmpeg/FFmpeg/libavutil/avutil.h:289,
                 from /__w/FFmpeg/FFmpeg/libavutil/log.h:25,
                 from /__w/FFmpeg/FFmpeg/libavdevice/avdevice.h:46,
                 from /__w/FFmpeg/FFmpeg/libavdevice/alldevices.c:22:
/__w/FFmpeg/FFmpeg/libavutil/mem.h:185:1: warning: 'alloc_size' attribute ignored on a function returning 'int' [-Wattributes]
  185 | av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size);
      | ^~~~~~~~~~~~~

git cherry-pick 4361293fcf
FFmpeg@4361293fcf

@smanders
Copy link
Collaborator Author

smanders commented Jan 19, 2026

additional rocky10-gcc15 on amd64 build issues

/__w/FFmpeg/FFmpeg/libavfilter/aeval.c: In function 'aeval_query_formats':
/__w/FFmpeg/FFmpeg/libavfilter/aeval.c:343:9: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
  343 |         if (!layouts)
      |         ^~
/__w/FFmpeg/FFmpeg/libavfilter/aeval.c:345:13: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
  345 |             ff_set_common_channel_layouts(ctx, layouts);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/audio.c: In function 'avfilter_get_audio_buffer_ref_from_arrays':
/__w/FFmpeg/FFmpeg/libavfilter/audio.c:166:5: warning: 'avfilter_get_audio_buffer_ref_from_arrays_channels' is deprecated [-Wdeprecated-declarations]
  166 |     return avfilter_get_audio_buffer_ref_from_arrays_channels(data, linesize, perms,
      |     ^~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/audio.c:84:20: note: declared here
   84 | AVFilterBufferRef* avfilter_get_audio_buffer_ref_from_arrays_channels(uint8_t **data,
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
CC	libavfilter/avcodec.o
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c: In function 'avfilter_get_video_buffer_ref_from_frame':
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:36:9: warning: 'avfilter_get_video_buffer_ref_from_arrays' is deprecated [-Wdeprecated-declarations]
   36 |         avfilter_get_video_buffer_ref_from_arrays(frame->data, frame->linesize, perms,
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /__w/FFmpeg/FFmpeg/libavfilter/avcodec.h:31,
                 from /__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:26:
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:914:1: note: declared here
  914 | avfilter_get_video_buffer_ref_from_arrays(uint8_t * const data[4], const int linesize[4], int perms,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:41:5: warning: 'avfilter_copy_frame_props' is deprecated [-Wdeprecated-declarations]
   41 |     if (avfilter_copy_frame_props(picref, frame) < 0) {
      |     ^~
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:1117:5: note: declared here
 1117 | int avfilter_copy_frame_props(AVFilterBufferRef *dst, const AVFrame *src);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:43:9: warning: 'avfilter_unref_bufferp' is deprecated [-Wdeprecated-declarations]
   43 |         avfilter_unref_bufferp(&picref);
      |         ^~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:236:6: note: declared here
  236 | void avfilter_unref_bufferp(AVFilterBufferRef **ref);
      |      ^~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c: In function 'avfilter_get_audio_buffer_ref_from_frame':
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:60:5: warning: 'avfilter_get_audio_buffer_ref_from_arrays_channels' is deprecated [-Wdeprecated-declarations]
   60 |     samplesref = avfilter_get_audio_buffer_ref_from_arrays_channels(
      |     ^~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:952:20: note: declared here
  952 | AVFilterBufferRef *avfilter_get_audio_buffer_ref_from_arrays_channels(uint8_t **data,
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:65:5: warning: 'avfilter_copy_frame_props' is deprecated [-Wdeprecated-declarations]
   65 |     if (avfilter_copy_frame_props(samplesref, frame) < 0) {
      |     ^~
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:1117:5: note: declared here
 1117 | int avfilter_copy_frame_props(AVFilterBufferRef *dst, const AVFrame *src);
      |     ^~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:67:9: warning: 'avfilter_unref_bufferp' is deprecated [-Wdeprecated-declarations]
   67 |         avfilter_unref_bufferp(&samplesref);
      |         ^~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfilter.h:236:6: note: declared here
  236 | void avfilter_unref_bufferp(AVFilterBufferRef **ref);
      |      ^~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c: In function 'avfilter_get_buffer_ref_from_frame':
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:78:9: warning: 'avfilter_get_video_buffer_ref_from_frame' is deprecated [-Wdeprecated-declarations]
   78 |         return avfilter_get_video_buffer_ref_from_frame(frame, perms);
      |         ^~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:32:20: note: declared here
   32 | AVFilterBufferRef *avfilter_get_video_buffer_ref_from_frame(const AVFrame *frame,
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:80:9: warning: 'avfilter_get_audio_buffer_ref_from_frame' is deprecated [-Wdeprecated-declarations]
   80 |         return avfilter_get_audio_buffer_ref_from_frame(frame, perms);
      |         ^~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avcodec.c:48:20: note: declared here
   48 | AVFilterBufferRef *avfilter_get_audio_buffer_ref_from_frame(const AVFrame *frame,
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c: In function 'query_formats':
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:529:82: warning: '%d' directive output may be truncated writing between 1 and 10 bytes into a region of size 9 [-Wformat-truncation=]
  529 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted scaler %d",
      |                                                                                  ^~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:529:60: note: directive argument in the range [0, 2147483647]
  529 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted scaler %d",
      |                                                            ^~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:529:21: note: 'snprintf' output between 23 and 32 bytes into a destination of size 30
  529 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted scaler %d",
      |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  530 |                              scaler_count++);
      |                              ~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:544:85: warning: '%d' directive output may be truncated writing between 1 and 10 bytes into a region of size 6 [-Wformat-truncation=]
  544 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted resampler %d",
      |                                                                                     ^~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:544:60: note: directive argument in the range [0, 2147483647]
  544 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted resampler %d",
      |                                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/avfiltergraph.c:544:21: note: 'snprintf' output between 26 and 35 bytes into a destination of size 30
  544 |                     snprintf(inst_name, sizeof(inst_name), "auto-inserted resampler %d",
      |                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  545 |                              resampler_count++);
      |                              ~~~~~~~~~~~~~~~~~~
/__w/FFmpeg/FFmpeg/libavfilter/drawutils.c: In function 'ff_draw_init':
/__w/FFmpeg/FFmpeg/libavfilter/drawutils.c:172:22: warning: comparison is always false due to limited range of data type [-Wtype-limits]
  172 |         if (c->plane >= MAX_PLANES)
      |                      ^~
/__w/FFmpeg/FFmpeg/libavfilter/vf_paletteuse.c: In function 'set_frame':
/__w/FFmpeg/FFmpeg/libavfilter/vf_paletteuse.c:441:21: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
  441 |                     if (left)       src[  src_linesize + x - 1] = dither_color(src[  src_linesize + x - 1], er, eg, eb, 2, 4);
      |                     ^~
/__w/FFmpeg/FFmpeg/libavfilter/vf_paletteuse.c:442:37: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
  442 |                                     src[  src_linesize + x    ] = dither_color(src[  src_linesize + x    ], er, eg, eb, 3, 4);
      |                                     ^~~
/__w/FFmpeg/FFmpeg/libavcodec/x86/mathops.h: Assembler messages:
/__w/FFmpeg/FFmpeg/libavcodec/x86/mathops.h:123: Error: operand type mismatch for `shr'
/__w/FFmpeg/FFmpeg/libavcodec/x86/mathops.h:123: Error: operand type mismatch for `shr'
/__w/FFmpeg/FFmpeg/libavcodec/x86/mathops.h:123: Error: operand type mismatch for `shr'
make: *** [/__w/FFmpeg/FFmpeg/common.mak:57: libavformat/adtsenc.o] Error 1

several of these are only warnings and some don't have clean commit to cherry-pick... so for now I will attempt to only address the failures

git cherry-pick effadce6c7
FFmpeg@effadce6c7

…in inline assembly

Fixes assembling with binutil as >= 2.41

Signed-off-by: James Almer <jamrial@gmail.com>
@smanders smanders merged commit a84fbd9 into dev Jan 19, 2026
21 checks passed
@smanders smanders deleted the manifestUpdate branch January 19, 2026 23:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants