]>
Commit | Line | Data |
---|---|---|
144c8856 PS |
1 | H.J. |
2 | 2006-10-06 H.J. Lu <hongjiu.lu@intel.com> | |
3 | ||
4 | PR ld/3314 | |
5 | * elf.c (assign_file_positions_for_non_load_sections): Don't | |
6 | page align empty SHF_ALLOC sections. | |
7 | ||
8 | --- bfd/elf.c.empty 2006-09-29 09:00:21.000000000 -0700 | |
9 | +++ bfd/elf.c 2006-10-06 09:14:04.000000000 -0700 | |
10 | @@ -4663,11 +4663,12 @@ assign_file_positions_for_non_load_secti | |
11 | if (hdr->sh_size != 0) | |
12 | ((*_bfd_error_handler) | |
13 | (_("%B: warning: allocated section `%s' not in segment"), | |
14 | - abfd, | |
15 | - (hdr->bfd_section == NULL | |
16 | - ? "*unknown*" | |
17 | - : hdr->bfd_section->name))); | |
18 | - if ((abfd->flags & D_PAGED) != 0) | |
19 | + abfd, | |
20 | + (hdr->bfd_section == NULL | |
21 | + ? "*unknown*" | |
22 | + : hdr->bfd_section->name))); | |
23 | + /* We don't need to page align empty sections. */ | |
24 | + if ((abfd->flags & D_PAGED) != 0 && hdr->sh_size != 0) | |
25 | off += vma_page_aligned_bias (hdr->sh_addr, off, | |
26 | bed->maxpagesize); | |
27 | else |