diff options
author | Alan Modra <amodra@gmail.com> | 2006-06-01 03:45:58 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2006-06-01 03:45:58 +0000 |
commit | 117ed4f8d5a9691c0bc1200d5d797e5211688c84 (patch) | |
tree | 4f57e1654f1a735dd6358ae27f0f705cbd49788e /bfd/aix5ppc-core.c | |
parent | 13d6194fb981e198cdf887374d8ed3a1737cca0e (diff) | |
download | binutils-gdb-117ed4f8d5a9691c0bc1200d5d797e5211688c84.tar.gz |
* stabs.c (_bfd_link_section_stabs): Use bfd_make_section*_with_flags
instead of bfd_make_section*.
* aix386-core.c: Likewise.
* aix5ppc-core.c: Likewise.
* aout-adobe.c: Likewise.
* aoutf1.h: Likewise.
* binary.c: Likewise.
* cisco-core.c: Likewise.
* coff-arm.c: Likewise.
* coff-h8300.c: Likewise.
* elf.c: Likewise.
* elf32-bfin.c: Likewise.
* elf32-m32c.c: Likewise.
* hppabsd-core.c: Likewise.
* hpux-core.c: Likewise.
* i386linux.c: Likewise.
* ieee.c: Likewise.
* ihex.c: Likewise.
* irix-core.c: Likewise.
* lynx-core.c: Likewise.
* m68klinux.c: Likewise.
* mach-o.c: Likewise.
* netbsd-core.c: Likewise.
* nlmcode.h: Likewise.
* opncls.c: Likewise.
* osf-core.c: Likewise.
* peXXigen.c: Likewise.
* ppcboot.c: Likewise.
* ptrace-core.c: Likewise.
* rs6000-core.c: Likewise.
* sco5-core.c: Likewise.
* sparclinux.c: Likewise.
* srec.c: Likewise.
* sunos.c: Likewise.
* trad-core.c: Likewise.
* xcofflink.c: Likewise.
* xsym.c: Likewise.
Diffstat (limited to 'bfd/aix5ppc-core.c')
-rw-r--r-- | bfd/aix5ppc-core.c | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/bfd/aix5ppc-core.c b/bfd/aix5ppc-core.c index ee2a223d9e5..62d11e20169 100644 --- a/bfd/aix5ppc-core.c +++ b/bfd/aix5ppc-core.c @@ -1,5 +1,5 @@ /* IBM RS/6000 "XCOFF" back-end for BFD. - Copyright 2001, 2002, 2003, 2004, 2005 + Copyright 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. Written by Tom Rix Contributed by Red Hat Inc. @@ -56,6 +56,7 @@ xcoff64_core_p (bfd *abfd) bfd_size_type i; struct vm_infox vminfo; const bfd_target *return_value = NULL; + flagword flags; /* Get the header. */ if (bfd_seek (abfd, 0, SEEK_SET) != 0) @@ -117,21 +118,21 @@ xcoff64_core_p (bfd *abfd) abfd->tdata.any = new_core_hdr; /* .stack section. */ - sec = bfd_make_section_anyway (abfd, ".stack"); + flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; + sec = bfd_make_section_anyway_with_flags (abfd, ".stack", flags); if (NULL == sec) return return_value; - sec->flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; sec->size = core.c_size; sec->vma = core.c_stackorg; sec->filepos = core.c_stack; /* .reg section for all registers. */ - sec = bfd_make_section_anyway (abfd, ".reg"); + flags = SEC_HAS_CONTENTS | SEC_IN_MEMORY; + sec = bfd_make_section_anyway_with_flags (abfd, ".reg", flags); if (NULL == sec) return return_value; - sec->flags = SEC_HAS_CONTENTS | SEC_IN_MEMORY; sec->size = sizeof (struct __context64); sec->vma = 0; sec->filepos = 0; @@ -141,11 +142,11 @@ xcoff64_core_p (bfd *abfd) To actually find out how long this section is in this particular core dump would require going down the whole list of struct ld_info's. See if we can just fake it. */ - sec = bfd_make_section_anyway (abfd, ".ldinfo"); + flags = SEC_HAS_CONTENTS; + sec = bfd_make_section_anyway_with_flags (abfd, ".ldinfo", flags); if (NULL == sec) return return_value; - sec->flags = SEC_HAS_CONTENTS; sec->size = core.c_lsize; sec->vma = 0; sec->filepos = core.c_loader; @@ -155,11 +156,11 @@ xcoff64_core_p (bfd *abfd) regions. */ /* .data section from executable. */ - sec = bfd_make_section_anyway (abfd, ".data"); + flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; + sec = bfd_make_section_anyway_with_flags (abfd, ".data", flags); if (NULL == sec) return return_value; - sec->flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; sec->size = core.c_datasize; sec->vma = core.c_dataorg; sec->filepos = core.c_data; @@ -178,11 +179,11 @@ xcoff64_core_p (bfd *abfd) if (ldinfo.ldinfo_core) { - sec = bfd_make_section_anyway (abfd, ".data"); + flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; + sec = bfd_make_section_anyway_with_flags (abfd, ".data", flags); if (NULL == sec) return return_value; - sec->flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; sec->size = ldinfo.ldinfo_datasize; sec->vma = ldinfo.ldinfo_dataorg; sec->filepos = ldinfo.ldinfo_core; @@ -206,11 +207,11 @@ xcoff64_core_p (bfd *abfd) if (vminfo.vminfo_offset) { - sec = bfd_make_section_anyway (abfd, ".vmdata"); + flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; + sec = bfd_make_section_anyway_with_flags (abfd, ".vmdata", flags); if (NULL == sec) return return_value; - sec->flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS; sec->size = vminfo.vminfo_size; sec->vma = vminfo.vminfo_addr; sec->filepos = vminfo.vminfo_offset; |