Ignore:
Timestamp:
Aug 16, 2003, 6:59:22 PM (22 years ago)
Author:
bird
Message:

binutils v2.14 - offical sources.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/binutils/ld/ldwrite.c

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r608 r609  
    11/* ldwrite.c -- write out the linked file
    2    Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000
     2   Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002
    33   Free Software Foundation, Inc.
    44   Written by Steve Chamberlain sac@cygnus.com
     
    3030#include "ldwrite.h"
    3131#include "ldmisc.h"
    32 #include "ldgram.h"
     32#include <ldgram.h>
    3333#include "ldmain.h"
    3434
     
    5050        struct bfd_link_order *link_order;
    5151        bfd_vma value;
    52         boolean big_endian = false;
     52        bfd_boolean big_endian = FALSE;
    5353
    5454        output_section = statement->data_statement.output_section;
     
    7171           input file is little endian.  */
    7272        if (bfd_big_endian (output_bfd))
    73           big_endian = true;
     73          big_endian = TRUE;
    7474        else if (bfd_little_endian (output_bfd))
    75           big_endian = false;
     75          big_endian = FALSE;
    7676        else
    7777          {
    78             boolean swap;
    79 
    80             swap = false;
     78            bfd_boolean swap;
     79
     80            swap = FALSE;
    8181            if (command_line.endian == ENDIAN_BIG)
    82               big_endian = true;
     82              big_endian = TRUE;
    8383            else if (command_line.endian == ENDIAN_LITTLE)
    8484              {
    85                 big_endian = false;
    86                 swap = true;
     85                big_endian = FALSE;
     86                swap = TRUE;
    8787              }
    8888            else if (command_line.endian == ENDIAN_UNSET)
    8989              {
    90                 big_endian = true;
     90                big_endian = TRUE;
    9191                {
    9292                  LANG_FOR_EACH_INPUT_STATEMENT (s)
     
    9696                          if (bfd_little_endian (s->the_bfd))
    9797                            {
    98                               big_endian = false;
    99                               swap = true;
     98                              big_endian = FALSE;
     99                              swap = TRUE;
    100100                            }
    101101                          break;
     
    227227      /* Create a new link_order in the output section with this
    228228         attached */
    229       if (statement->input_section.ifile->just_syms_flag == false)
     229      if (!statement->input_section.ifile->just_syms_flag)
    230230        {
    231231          asection *i = statement->input_section.section;
     
    234234          ASSERT (output_section->owner == output_bfd);
    235235
    236           if ((output_section->flags & SEC_HAS_CONTENTS) != 0)
     236          if ((output_section->flags & SEC_HAS_CONTENTS) != 0
     237              || ((output_section->flags & SEC_LOAD) != 0
     238                  && (output_section->flags & SEC_THREAD_LOCAL)))
    237239            {
    238240              struct bfd_link_order *link_order;
     
    244246                  /* We've got a never load section inside one which
    245247                     is going to be output, we'll change it into a
    246                      fill link_order */
    247                   link_order->type = bfd_fill_link_order;
    248                   link_order->u.fill.value = 0;
     248                     fill.  */
     249                  link_order->type = bfd_data_link_order;
     250                  link_order->u.data.contents = "";
     251                  link_order->u.data.size = 1;
    249252                }
    250253              else
     
    275278          {
    276279            link_order = bfd_new_link_order (output_bfd, output_section);
    277             link_order->type = bfd_fill_link_order;
     280            link_order->type = bfd_data_link_order;
    278281            link_order->size = statement->padding_statement.size;
    279282            link_order->offset = statement->padding_statement.output_offset;
    280             link_order->u.fill.value = statement->padding_statement.fill;
     283            link_order->u.data.contents = statement->padding_statement.fill->data;
     284            link_order->u.data.size = statement->padding_statement.fill->size;
    281285          }
    282286      }
     
    317321      || (n = bfd_make_section_anyway (abfd, sname)) == NULL
    318322      || (h = bfd_link_hash_lookup (link_info.hash,
    319                                     sname, true, true, false)) == NULL)
     323                                    sname, TRUE, TRUE, FALSE)) == NULL)
    320324    {
    321325      einfo (_("%F%P: clone section failed: %E\n"));
Note: See TracChangeset for help on using the changeset viewer.