]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
authorAlan Modra <amodra@gmail.com>
Thu, 14 Feb 2002 04:12:45 +0000 (04:12 +0000)
committerAlan Modra <amodra@gmail.com>
Thu, 14 Feb 2002 04:12:45 +0000 (04:12 +0000)
bfd/ChangeLog
bfd/elf.c

index 63184757026477ab38b25f2fb7223e71a41a90b2..01727d8527969323cbdd8d9a98403c0cff5d3097 100644 (file)
@@ -1,3 +1,7 @@
+2002-02-14  Alan Modra  <amodra@bigpond.net.au>
+
+       * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
+
 2002-02-13  Hans-Peter Nilsson  <hp@bitrange.com>
 
        * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
index da4625842db75a1b8335412b15d837b1de8b908a..8c6da10f1bd640c9fd2600e1188c96a167f223ef 100644 (file)
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -2214,7 +2214,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;