diff options
author | Ian Lance Taylor <iant@google.com> | 2007-12-07 06:44:01 +0000 |
---|---|---|
committer | Ian Lance Taylor <iant@google.com> | 2007-12-07 06:44:01 +0000 |
commit | 4117d76827b3768e9da6ef52f52a59c5ae92bed3 (patch) | |
tree | 0e922a8a56fb517fce40ab926e9d1bb98039818a /gold/layout.cc | |
parent | a20d5e98e51d91b66dfccc205d4d27e8850238b2 (diff) | |
download | gdb-4117d76827b3768e9da6ef52f52a59c5ae92bed3.zip gdb-4117d76827b3768e9da6ef52f52a59c5ae92bed3.tar.gz gdb-4117d76827b3768e9da6ef52f52a59c5ae92bed3.tar.bz2 |
Fix ehframe header handling for shared libraries.
Diffstat (limited to 'gold/layout.cc')
-rw-r--r-- | gold/layout.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gold/layout.cc b/gold/layout.cc index 68ebc6b..f5a1f67 100644 --- a/gold/layout.cc +++ b/gold/layout.cc @@ -992,7 +992,9 @@ Layout::set_segment_offsets(const Target* target, Output_segment* load_seg, // Find the PT_LOAD segments, and set their addresses and offsets // and their section's addresses and offsets. uint64_t addr; - if (options_.user_set_text_segment_address()) + if (parameters->output_is_shared()) + addr = 0; + else if (options_.user_set_text_segment_address()) addr = options_.text_segment_address(); else addr = target->default_text_segment_address(); |