Bug 2424325 - FTBFS: gdb: new warnings when building with gcc 16 and glibc 2.42.9000
Summary: FTBFS: gdb: new warnings when building with gcc 16 and glibc 2.42.9000
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: gdb
Version: rawhide
Hardware: Unspecified
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Kevin Buettner
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: GCC16-Mass-Prebuild
TreeView+ depends on / blocked
 
Reported: 2025-12-22 16:26 UTC by Siddhesh Poyarekar
Modified: 2026-01-09 04:10 UTC (History)
9 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2026-01-09 04:10:14 UTC
Type: ---
Embargoed:
kevinb: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker FC-2894 0 None None None 2026-01-06 15:41:05 UTC

Description Siddhesh Poyarekar 2025-12-22 16:26:05 UTC
These are already fixed upstream in binutils, but the rawhide gdb appears to not have been updated to incorporate those.

Reproducible: Always

Steps to Reproduce:
Scratch build against the f44-build-side-124978 side tag to reproduce
Actual Results:
../../bfd/archive.c: In function ‘_bfd_compute_and_write_armap’:
../../bfd/archive.c:2307:12: error: variable ‘elt_no’ set but not used [-Werror=unused-but-set-variable=]
 2307 |   file_ptr elt_no = 0;
      |            ^~~~~~
cc1: all warnings being treated as errors


...


../../bfd/bfd.c: In function ‘_bfd_doprnt’:
../../bfd/bfd.c:1062:23: error: initialization discards ‘const’ qualifier from pointer target type [-Werror=discarded-qualifiers]
 1062 |           char *end = strchr (ptr, '%');
      |                       ^~~~~~
cc1: all warnings being treated as errors

Comment 1 Kevin Buettner 2026-01-06 03:32:38 UTC
I will take care of this while doing the GDB 17.1 rebase.

It seems that the change removing elt_no from bfd/archive.c is already in the GDB 17.1 sources.

However, the fix for the const problem is not.  So that change will have to be applied separately.

Comment 2 Kevin Buettner 2026-01-09 04:10:14 UTC
These problems plus several more have been fixed in the GDB 17.1 rebase plus backports for rawhide.  I'm closing this issue.


Note You need to log in before you can comment on or make changes to this bug.