]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - binutils/readelf.c
Properly implement STT_COMMON
[thirdparty/binutils-gdb.git] / binutils / readelf.c
index f33257bc04754bcac7ce233bb4ea136878c414f4..a40453d367fcc0d527857de28d94232f7b1001f6 100644 (file)
@@ -3996,6 +3996,7 @@ get_section_type_name (unsigned int sh_type)
            case EM_V850:
            case EM_CYGNUS_V850:
              result = get_v850_section_type_name (sh_type);
+             break;
            default:
              result = NULL;
              break;
@@ -11558,6 +11559,9 @@ is_32bit_pcrel_reloc (unsigned int reloc_type)
       return reloc_type == 6;
     case EM_ALPHA:
       return reloc_type == 10; /* R_ALPHA_SREL32.  */
+    case EM_ARC_COMPACT:
+    case EM_ARC_COMPACT2:
+      return reloc_type == 49; /* R_ARC_32_PCREL.  */
     case EM_ARM:
       return reloc_type == 3;  /* R_ARM_REL32 */
     case EM_MICROBLAZE:
@@ -11978,6 +11982,7 @@ apply_relocations (void *                     file,
             referencing a global array.  For an example of this see
             the _clz.o binary in libgcc.a.  */
          if (sym != symtab
+             && ELF_ST_TYPE (sym->st_info) != STT_COMMON
              && ELF_ST_TYPE (sym->st_info) > STT_SECTION)
            {
              warn (_("skipping unexpected symbol type %s in %ld'th relocation in section %s\n"),