From: Alan Modra Date: Thu, 14 Feb 2002 04:12:24 +0000 (+0000) Subject: * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD. X-Git-Tag: gdb_5_2-2002-03-03-branchpoint~275 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=edd29cf912e93aa5cdea52c4c5e3a6e0da5b664c;p=thirdparty%2Fbinutils-gdb.git * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD. --- diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 7d55773a22a..bbea17db6c2 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,7 @@ +2002-02-14 Alan Modra + + * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD. + 2002-02-17 Matt Fredette * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize @@ -6,8 +10,8 @@ 2002-02-13 Nick Clifton * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on - non-zero physical addresses when adjusting the LMAs of new - sections. + non-zero physical addresses when adjusting the LMAs of new + sections. 2002-02-12 John David Anglin diff --git a/bfd/elf.c b/bfd/elf.c index f75eb8587d0..7f63b34adcc 100644 --- a/bfd/elf.c +++ b/bfd/elf.c @@ -2219,7 +2219,8 @@ elf_fake_sections (abfd, asect, failedptrarg) this_hdr->sh_entsize = 4; } else if ((asect->flags & SEC_ALLOC) != 0 - && ((asect->flags & (SEC_LOAD | SEC_HAS_CONTENTS)) == 0)) + && (((asect->flags & (SEC_LOAD | SEC_HAS_CONTENTS)) == 0) + || (asect->flags & SEC_NEVER_LOAD) != 0)) this_hdr->sh_type = SHT_NOBITS; else this_hdr->sh_type = SHT_PROGBITS;