Update of /cvsroot/wisp/wisp/users/dig
In directory sc8-pr-cvs1:/tmp/cvs-serv16831
Modified Files:
elf.py
Log Message:
made make_ELF32_object not call set_origin on the linkees
Index: elf.py
===================================================================
RCS file: /cvsroot/wisp/wisp/users/dig/elf.py,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -d -r1.53 -r1.54
--- elf.py 6 May 2003 16:22:58 -0000 1.53
+++ elf.py 12 May 2003 21:36:02 -0000 1.54
@@ -491,7 +491,7 @@
def make_ELF32_object (text = None, data = None, bss = None, flags = '',
memory_bottom = 0x08048000):
- # Will set given sections' origins.
+ # Will NOT set given sections' origins.
want_symbols = 's' in flags
want_relocatable = 'r' in flags
if bss <> None and bss.filesz() <> 0:
@@ -562,17 +562,17 @@
offset = binary.filesz()
if p_flags == 0:
- section.set_origin(0)
+ org = 0
binary.place_symbol('&' + name, 0)
elif want_relocatable:
- section.set_origin(0)
+ org = 0
else:
address = memory_boundary | (offset & 0xFFF)
# take into account alignments larger than a page
address = (address + alignment - 1) & ~(alignment - 1)
binary.place_symbol('#' + name + '/p_flags', p_flags)
binary.place_symbol('#' + name + '/p_type', guess_ELF32_ptype(name))
- section.set_origin(address)
+ org = address
binary.place_symbol('&' + name, address)
binary.place_symbol('#' + name + '/memsz', section.memsz())
@@ -599,7 +599,7 @@
# alignment has been processed already
binary.place_symbol('!' + name)
- binary.paste(-1, section, skip_addr = want_relocatable)
+ binary.glue(binary.memsz(), section, org)
if want_symbols:
symtab = sections['.symtab']
for symbol, value in section.get_symbols():
|