https://sourceware.org/bugzilla/show_bug.cgi?id=18847

--- Comment #2 from Johan Karlsson <johan.karlsson at enea dot com> ---
Created attachment 8534
  --> https://sourceware.org/bugzilla/attachment.cgi?id=8534&action=edit
Linker script

I was able to reproduce it easily with my toolchain, but when I tried the
toolchain on my local distro (Binutils 2.24) I got an additional error about
segments overlap(ld.gold: error: load segment overlap [0x1000000 -> 0x1000048]
and [0x100000b -> 0x1010000]
)

Reproduce like this using the attached linker script.
test.c:
main(){ return 0; }

gcc -c -o test.o test.c

ld.gold -T script.lcf test.o

ld.gold: error: address of section '.bss' moves backward from 0x1010000 to
0x100000b


If I remove ALIGN from .data no error is seen. Using the attached patch I get
no error when using section alignment or not. The patch might not be enough
since I did not look into the root cause for the this->address_ being set.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to