Automatic date update in version.in
[deliverable/binutils-gdb.git] / bfd / elf32-score.c
index 3d499ca07190adab387900cac7b5bc95634cacf4..d1a910f2795e9701fd96b291183bf9411164948f 100644 (file)
@@ -1,5 +1,5 @@
 /* 32-bit ELF support for S+core.
-   Copyright (C) 2006-2019 Free Software Foundation, Inc.
+   Copyright (C) 2006-2020 Free Software Foundation, Inc.
    Contributed by
    Brain.lin (brain.lin@sunplusct.com)
    Mei Ligang (ligang@sunnorth.com.cn)
@@ -1410,7 +1410,7 @@ score_elf_create_got_section (bfd *abfd,
   struct elf_link_hash_entry *h;
   struct bfd_link_hash_entry *bh;
   struct score_got_info *g;
-  bfd_size_type amt;
+  size_t amt;
 
   /* This function may be called more than once.  */
   s = score_elf_got_section (abfd, TRUE);
@@ -2669,13 +2669,14 @@ s3_bfd_score_elf_relocate_section (bfd *output_bfd,
            }
          else if (!bfd_link_relocatable (info))
            {
-             (*info->callbacks->undefined_symbol)
-               (info, h->root.root.root.string, input_bfd,
-                input_section, rel->r_offset,
-                (info->unresolved_syms_in_objects == RM_GENERATE_ERROR)
+              info->callbacks->undefined_symbol
+               (info, h->root.root.root.string, input_bfd, input_section,
+                rel->r_offset,
+                (info->unresolved_syms_in_objects == RM_DIAGNOSE
+                 && !info->warn_unresolved_syms)
                 || ELF_ST_VISIBILITY (h->root.other));
-             relocation = 0;
-           }
+              relocation = 0;
+            }
        }
 
       if (sec != NULL && discarded_section (sec))
@@ -4020,6 +4021,10 @@ s3_elf32_score_merge_private_bfd_data (bfd *ibfd, struct bfd_link_info *info)
   if (!_bfd_generic_verify_endian_match (ibfd, info))
     return FALSE;
 
+  /* FIXME: What should be checked when linking shared libraries?  */
+  if ((ibfd->flags & DYNAMIC) != 0)
+    return TRUE;
+
   in_flags  = elf_elfheader (ibfd)->e_flags;
   out_flags = elf_elfheader (obfd)->e_flags;
 
@@ -4057,7 +4062,7 @@ static bfd_boolean
 s3_elf32_score_new_section_hook (bfd *abfd, asection *sec)
 {
   struct _score_elf_section_data *sdata;
-  bfd_size_type amt = sizeof (*sdata);
+  size_t amt = sizeof (*sdata);
 
   sdata = bfd_zalloc (abfd, amt);
   if (sdata == NULL)
@@ -4359,7 +4364,7 @@ static struct bfd_link_hash_table *
 elf32_score_link_hash_table_create (bfd *abfd)
 {
   struct elf_link_hash_table *ret;
-  bfd_size_type amt = sizeof (struct elf_link_hash_table);
+  size_t amt = sizeof (struct elf_link_hash_table);
 
   ret = (struct elf_link_hash_table *) bfd_zmalloc (amt);
   if (ret == NULL)
This page took 0.025354 seconds and 4 git commands to generate.