bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/948] Wrong LMA for section with empty input section.


From: fabrice_gautier at sdesigns dot com
Subject: [Bug ld/948] Wrong LMA for section with empty input section.
Date: 12 May 2005 19:55:33 -0000

------- Additional Comments From fabrice_gautier at sdesigns dot com  
2005-05-12 19:55 -------
Created an attachment (id=488)
 --> (http://sources.redhat.com/bugzilla/attachment.cgi?id=488&action=view)
linker script and sample c code.

This is a linker script and c code to reproduce the issue:

$ gcc -c test-lma.c
$ ld -T script.ld test-lma.o
$ objdump -h a.out

a.out:     file format elf32-i386

Sections:
Idx Name          Size      VMA       LMA       File off  Algn
  0 .text         00000021  20000000  00000000  00001000  2**2
                  CONTENTS, ALLOC, LOAD, READONLY, CODE
  1 .data         00000004  40000000  00001000  00002000  2**2
                  CONTENTS, ALLOC, LOAD, DATA
  2 .rodata       0000000c  40000004  40000004  00002004  2**0
                  CONTENTS, ALLOC, LOAD, DATA
  3 .bss          00000004  40000010  00001010  00002004  2**2
                  ALLOC
  4 .note.GNU-stack 00000000  00000000  00000000  00002004  2**0
                  CONTENTS, READONLY
  5 .comment      00000026  00000000  00000000  00002004  2**0
                  CONTENTS, READONLY


The problem is :
  2 .rodata       0000000c  40000004  40000004  00002004  2**0

It should be :
  2 .rodata       0000000c  40000004  00001004  00002004  2**0


-- Fabrice

-- 


http://sources.redhat.com/bugzilla/show_bug.cgi?id=948

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]