+2004-08-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_gc_sweep): Keep non-alloc, non-load sections.
+
2004-08-17 Nick Clifton <nickc@redhat.com>
* (is_arm_mapping_symbol_name): New function - return true
for (o = sub->sections; o != NULL; o = o->next)
{
- /* Keep special sections. Keep .debug sections. */
- if ((o->flags & SEC_LINKER_CREATED)
- || (o->flags & SEC_DEBUGGING))
+ /* Keep debug and special sections. */
+ if ((o->flags & (SEC_DEBUGGING | SEC_LINKER_CREATED)) != 0
+ || (o->flags & (SEC_ALLOC | SEC_LOAD)) == 0)
o->gc_mark = 1;
if (o->gc_mark)