From: Simon Marchi Date: Fri, 7 Nov 2025 16:42:35 +0000 (+0000) Subject: Revert "bfd/ELF: make is_debuginfo_file() static" X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6d30159f9a79d71e35078d5299dfcc606342a9d8;p=thirdparty%2Fbinutils-gdb.git Revert "bfd/ELF: make is_debuginfo_file() static" This reverts commit 5e648fc6a0a066fad38d99b72fb85f2710f2c098, since it breaks the GDB build: CXX elfread.o /home/smarchi/src/binutils-gdb/gdb/elfread.c: In function ‘symfile_segment_data_up elf_symfile_segments(bfd*)’: /home/smarchi/src/binutils-gdb/gdb/elfread.c:145:12: error: ‘is_debuginfo_file’ was not declared in this scope 145 | if (!is_debuginfo_file (abfd) | ^~~~~~~~~~~~~~~~~ Change-Id: I180a9f6936365c365a853c7dae2af01f5207a84e --- diff --git a/bfd/elf-bfd.h b/bfd/elf-bfd.h index cb708147ef3..41aee298b96 100644 --- a/bfd/elf-bfd.h +++ b/bfd/elf-bfd.h @@ -3187,6 +3187,9 @@ extern bfd_vma elf64_r_sym (bfd_vma); extern bfd_vma elf32_r_info (bfd_vma, bfd_vma); extern bfd_vma elf32_r_sym (bfd_vma); +extern bool is_debuginfo_file (bfd *); + + extern bool _bfd_elf_init_secondary_reloc_section (bfd *, Elf_Internal_Shdr *, const char *, unsigned int) ATTRIBUTE_HIDDEN; extern bool _bfd_elf_slurp_secondary_reloc_section diff --git a/bfd/elf.c b/bfd/elf.c index e2c02440612..1f4109ddf48 100644 --- a/bfd/elf.c +++ b/bfd/elf.c @@ -6568,7 +6568,7 @@ assign_file_positions_for_load_sections (bfd *abfd, is no defined method for detecting such files, so we have to use heuristics instead. */ -static bool +bool is_debuginfo_file (bfd *abfd) { if (abfd == NULL || bfd_get_flavour (abfd) != bfd_target_elf_flavour)