* config/obj-aout.c (obj_aout_type): Do not ignore for undefined
authorHans-Peter Nilsson <hp@axis.com>
Thu, 29 Jun 2000 23:04:29 +0000 (23:04 +0000)
committerHans-Peter Nilsson <hp@axis.com>
Thu, 29 Jun 2000 23:04:29 +0000 (23:04 +0000)
symbols; create them.

gas/ChangeLog
gas/config/obj-aout.c

index a0398577f5c16bb7e1bd6cd28064e4e996541dbf..0a8aa03585a68548edd6085be7d165dde50b1cdf 100644 (file)
@@ -1,3 +1,8 @@
+Thu Jun 29 21:30:00 2000  Hans-Peter Nilsson  <hp@axis.com>
+
+       * config/obj-aout.c (obj_aout_type): Do not ignore for undefined
+       symbols; create them.
+
 2000-06-29 Mark Elbrecht <snowball3@bigfoot.com>
 
        * write.c (set_segment_vma): New: Set vma and lma for a segment.
index 16090776b55f18077f316fab669357746aad444a..2c7f5dfd3a90b6d784cf0470e074edce4959d02c 100644 (file)
@@ -396,7 +396,7 @@ obj_aout_weak (ignore)
 
 /* Handle .type.  On {Net,Open}BSD, this is used to set the n_other field,
    which is then apparently used when doing dynamic linking.  Older
-   versions ogas ignored the .type pseudo-op, so we also ignore it if
+   versions ogas ignored the .type pseudo-op, so we also ignore it if
    we can't parse it.  */
 
 static void
@@ -409,31 +409,28 @@ obj_aout_type (ignore)
 
   name = input_line_pointer;
   c = get_symbol_end ();
-  sym = symbol_find (name);
+  sym = symbol_find_or_make (name);
   *input_line_pointer = c;
-  if (sym != NULL)
+  SKIP_WHITESPACE ();
+  if (*input_line_pointer == ',')
     {
+      ++input_line_pointer;
       SKIP_WHITESPACE ();
-      if (*input_line_pointer == ',')
+      if (*input_line_pointer == '@')
        {
          ++input_line_pointer;
-         SKIP_WHITESPACE ();
-         if (*input_line_pointer == '@')
-           {
-             ++input_line_pointer;
-             if (strncmp (input_line_pointer, "object", 6) == 0)
+         if (strncmp (input_line_pointer, "object", 6) == 0)
 #ifdef BFD_ASSEMBLER
-               aout_symbol (symbol_get_bfdsym (sym))->other = 1;
+           aout_symbol (symbol_get_bfdsym (sym))->other = 1;
 #else
-               S_SET_OTHER (sym, 1);
+         S_SET_OTHER (sym, 1);
 #endif
-             else if (strncmp (input_line_pointer, "function", 8) == 0)
+         else if (strncmp (input_line_pointer, "function", 8) == 0)
 #ifdef BFD_ASSEMBLER
-               aout_symbol (symbol_get_bfdsym (sym))->other = 2;
+           aout_symbol (symbol_get_bfdsym (sym))->other = 2;
 #else
-               S_SET_OTHER (sym, 2);
+         S_SET_OTHER (sym, 2);
 #endif
-           }
        }
     }
 
This page took 0.030546 seconds and 4 git commands to generate.