]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
bfd/ELF: _bfd_elf_link_create_dynamic_sections() is exposed to ld
authorJan Beulich <jbeulich@suse.com>
Fri, 7 Nov 2025 14:00:51 +0000 (15:00 +0100)
committerJan Beulich <jbeulich@suse.com>
Fri, 7 Nov 2025 14:00:51 +0000 (15:00 +0100)
As a non-private function, it shouldn't have "_bfd_" prefixes, but merely
a "bfd_" one. Even if, sadly, it needs exposing just for the sake for
VxWorks.

bfd/elf-bfd.h
bfd/elf32-arc.c
bfd/elf32-tic6x.c
bfd/elf64-hppa.c
bfd/elflink.c
ld/emultempl/vxworks.em

index daad1a938f0401106795ea29b32f29acb40cabaa..cb708147ef3da0a5bef02ef9cccb9cbec766b224 100644 (file)
@@ -2625,7 +2625,7 @@ extern unsigned int _bfd_elf_default_action_discarded
 extern struct bfd_section *bfd_elf_tls_setup
   (bfd *, struct bfd_link_info *);
 
-extern bool _bfd_elf_link_create_dynamic_sections
+extern bool bfd_elf_link_create_dynamic_sections
   (bfd *, struct bfd_link_info *);
 extern bool _bfd_elf_omit_section_dynsym_default
   (bfd *, struct bfd_link_info *, asection *) ATTRIBUTE_HIDDEN;
index 6fa1a79ee87bc3af507d38b3e8e5c88b6749840a..5f6e9b4184127d1862836591b50b2516f41d55b1 100644 (file)
@@ -2071,7 +2071,7 @@ elf_arc_check_relocs (bfd *                        abfd,
                  {
                    if (info->dynamic
                        && ! htab->dynamic_sections_created
-                       && ! _bfd_elf_link_create_dynamic_sections (abfd, info))
+                       && ! bfd_elf_link_create_dynamic_sections (abfd, info))
                      return false;
                    sreloc = _bfd_elf_make_dynamic_reloc_section (sec, dynobj,
                                                                  2, abfd,
index a31c381531e4a1f09651e3cf75cff183613517bb..98b3a894ee52da12e038c8bc4234f3866774c926 100644 (file)
@@ -2694,7 +2694,7 @@ elf32_tic6x_check_relocs (bfd *abfd, struct bfd_link_info *info,
   if ((bfd_link_pic (info) || elf32_tic6x_using_dsbt (abfd))
       && ! htab->elf.dynamic_sections_created)
     {
-      if (! _bfd_elf_link_create_dynamic_sections (abfd, info))
+      if (! bfd_elf_link_create_dynamic_sections (abfd, info))
        return false;
     }
 
index 2d06396fb16827b5bb0bdd484e8f9d1a62195033..582c28f718f6a0fd98e148bbc2122e824a309dad 100644 (file)
@@ -507,7 +507,7 @@ elf64_hppa_check_relocs (bfd *abfd,
      the special sections required for dynamic linking.  */
   if (! elf_hash_table (info)->dynamic_sections_created)
     {
-      if (! _bfd_elf_link_create_dynamic_sections (abfd, info))
+      if (! bfd_elf_link_create_dynamic_sections (abfd, info))
        return false;
     }
 
index e2f5425ba3976e6e383b2045594942bd173bf9da..359d1c59248da9c4a76c89300901e14c5ae7c065 100644 (file)
@@ -332,7 +332,7 @@ _bfd_elf_link_create_dynstrtab (bfd *abfd, struct bfd_link_info *info)
    actual contents and size of these sections later.  */
 
 bool
-_bfd_elf_link_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
+bfd_elf_link_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
 {
   flagword flags;
   asection *s;
@@ -3960,7 +3960,7 @@ bfd_elf_add_dt_needed_tag (bfd *abfd, struct bfd_link_info *info)
          }
     }
 
-  if (!_bfd_elf_link_create_dynamic_sections (hash_table->dynobj, info))
+  if (!bfd_elf_link_create_dynamic_sections (hash_table->dynobj, info))
     return -1;
 
   if (!_bfd_elf_add_dynamic_entry (info, DT_NEEDED, strindex))
@@ -4577,7 +4577,7 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
          && info->output_bfd->xvec == abfd->xvec
          && !htab->dynamic_sections_created)
        {
-         if (! _bfd_elf_link_create_dynamic_sections (abfd, info))
+         if (!bfd_elf_link_create_dynamic_sections (abfd, info))
            goto error_return;
        }
     }
@@ -4798,7 +4798,7 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
       /* Create dynamic sections for backends that require that be done
         before setup_gnu_properties.  */
       if (add_needed
-         && !_bfd_elf_link_create_dynamic_sections (abfd, info))
+         && !bfd_elf_link_create_dynamic_sections (abfd, info))
        return false;
 
       /* Save the DT_AUDIT entry for the linker emulation code. */
@@ -5739,7 +5739,7 @@ elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
 
                  /* Create dynamic sections for backends that require
                     that be done before setup_gnu_properties.  */
-                 if (!_bfd_elf_link_create_dynamic_sections (abfd, info))
+                 if (!bfd_elf_link_create_dynamic_sections (abfd, info))
                    goto error_free_vers;
                  add_needed = true;
                }
@@ -11711,7 +11711,7 @@ elf_link_input_bfd (struct elf_final_link_info *flinfo, bfd *input_bfd)
 
       if ((o->flags & SEC_LINKER_CREATED) != 0)
        {
-         /* Section was created by _bfd_elf_link_create_dynamic_sections
+         /* Section was created by bfd_elf_link_create_dynamic_sections()
             or somesuch.  */
          continue;
        }
@@ -13778,7 +13778,7 @@ bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
          if ((o->flags & SEC_LINKER_CREATED) == 0)
            {
              /* At this point, we are only interested in sections
-                created by _bfd_elf_link_create_dynamic_sections.  */
+                created by bfd_elf_link_create_dynamic_sections().  */
              continue;
            }
          if (htab->stab_info.stabstr == o)
index cd2f6a5a0343726251bdebfce750c9b71fe02e14..61dcfabbae76a4d172318d859b24dfcec5f8dea9 100644 (file)
@@ -42,8 +42,8 @@ vxworks_after_open (void)
   if (force_dynamic
       && link_info.input_bfds
       && bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour
-      && !_bfd_elf_link_create_dynamic_sections (link_info.input_bfds,
-                                                &link_info))
+      && !bfd_elf_link_create_dynamic_sections (link_info.input_bfds,
+                                               &link_info))
     einfo (_("%X%P: cannot create dynamic sections %E\n"));
 
   if (!force_dynamic