Fix SPARC relocations generated for the .eh_frame section.
[external/binutils.git] / gas / config / tc-sparc.c
index 70f5bfb..d7b9a98 100644 (file)
@@ -4957,7 +4957,10 @@ cons_fix_new_sparc (fragS *frag,
          case 8: r = BFD_RELOC_SPARC_TLS_DTPOFF64; break;
          }
     }
-  else if (sparc_no_align_cons)
+  else if (sparc_no_align_cons
+          || /* PR 20803 - relocs in the .eh_frame section
+                need to support unaligned access.  */
+          strcmp (now_seg->name, ".eh_frame") == 0)
     {
       switch (nbytes)
        {