* emultempl/sunos.em (gld${EMULATION_NAME}_before_allocation):
authorIan Lance Taylor <ian@airs.com>
Mon, 15 Jan 1996 22:38:22 +0000 (22:38 +0000)
committerIan Lance Taylor <ian@airs.com>
Mon, 15 Jan 1996 22:38:22 +0000 (22:38 +0000)
Don't make a shared library because of an undefined reference to
__GLOBAL_OFFSET_TABLE_.

ld/ChangeLog
ld/emultempl/sunos.em

index ee31948ce3440fe22dbb02f3f3441a84b0aa534f..0e6dfa751f63c1fc4fafee4ae5eb78241d3e0ae1 100644 (file)
@@ -1,5 +1,9 @@
 Mon Jan 15 15:07:19 1996  Ian Lance Taylor  <ian@cygnus.com>
 
+       * emultempl/sunos.em (gld${EMULATION_NAME}_before_allocation):
+       Don't make a shared library because of an undefined reference to
+       __GLOBAL_OFFSET_TABLE_.
+
        Add some Irix 5 support, mostly from Kazumoto Kojima
         <kkojima@info.kanagawa-u.ac.jp>:
        * emulparams/elf32bmip.sh (SCRIPT_NAME): Change to elfmips.
index a2eebc74f558509875fb3a941d232d6e5d13c08b..e1c698398d0d7399b8724f7417ebaa3cae5cf9d1 100644 (file)
@@ -617,7 +617,8 @@ gld${EMULATION_NAME}_before_allocation ()
          if (h->type == bfd_link_hash_undefined
              && h->u.undef.abfd != NULL
              && (h->u.undef.abfd->flags & DYNAMIC) == 0
-             && strcmp (h->root.string, "__DYNAMIC") != 0)
+             && strcmp (h->root.string, "__DYNAMIC") != 0
+             && strcmp (h->root.string, "__GLOBAL_OFFSET_TABLE_") != 0)
            {
              find_assign = h->root.string;
              found_assign = false;
@@ -800,7 +801,7 @@ gld${EMULATION_NAME}_find_exp_assignment (exp)
       break;
 
     case etree_trinary:
-      gld${EMULATION_NAME}_find_exp_assignment (exp->trinary.lhs);
+      gld${EMULATION_NAME}_find_exp_assignment (exp->trinary.cond);
       gld${EMULATION_NAME}_find_exp_assignment (exp->trinary.lhs);
       gld${EMULATION_NAME}_find_exp_assignment (exp->trinary.rhs);
       break;