https://sourceware.org/bugzilla/show_bug.cgi?id=20995

--- Comment #19 from Alan Modra <amodra at gmail dot com> ---
Created attachment 9855
  --> https://sourceware.org/bugzilla/attachment.cgi?id=9855&action=edit
possible nios2 fix

Sandra, looking over my patch again, I think it is most likely this hunk.

-      else if (CONST_STRNEQ (name, ".got"))
-       got = s->size != 0;
-      else if (strcmp (name, ".dynbss") != 0)
+      else if (s == htab->root.sgot
+              || s == htab->root.sgotplt)
+       {
+         if (s->size != 0)
+           got = TRUE;
+       }
+      else if (s != htab->root.sdynbss
+              && s != htab->root.sdynrelro)

The CONST_STRNEQ matches both .got and .got.plt and I thought it was a bug that
the "got" flag could be set on finding a non-zero size .got section present
then cleared the next time around the loop on finding a zero size .got.plt.  Or
vice versa.  My guess at the time was that you wanted "got" set (results in
DT_PLTGOT) for either section, but it's possible you only want it set for
.got.plt.  If so then it was indeed a bug that the name compare matched both
.got and .got.plt, but I fixed it the wrong way..

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to