summaryrefslogtreecommitdiff
path: root/gold/target.h
diff options
context:
space:
mode:
authorCary Coutant <ccoutant@google.com>2014-03-10 13:35:53 -0700
committerCary Coutant <ccoutant@google.com>2014-03-10 13:35:53 -0700
commit800d982336156359cad5f98ba26a249a94f13108 (patch)
treee7ff1c14daead3937a629a34ba91d2b53a047c53 /gold/target.h
parent918fc1f8d23c634227c871b67ccb4ed32d0df83c (diff)
downloadbinutils-gdb-800d982336156359cad5f98ba26a249a94f13108.tar.gz
Allow target to adjust dynamic symbol value.
2014-03-10 Sasa Stankovic <Sasa.Stankovic@imgtec.com> gold/ * symtab.cc (Symbol_table::sized_write_globals): Allow a target to adjust dynamic symbol value. * target.h (Target::adjust_dyn_symbol): New function. (Target::do_adjust_dyn_symbol): New function.
Diffstat (limited to 'gold/target.h')
-rw-r--r--gold/target.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/gold/target.h b/gold/target.h
index bd512501b8f..aaf4b1ccaab 100644
--- a/gold/target.h
+++ b/gold/target.h
@@ -475,6 +475,11 @@ class Target
dynamic_tag_custom_value(elfcpp::DT tag) const
{ return this->do_dynamic_tag_custom_value(tag); }
+ // Adjust the value written to the dynamic symbol table.
+ void
+ adjust_dyn_symbol(const Symbol* sym, unsigned char* view) const
+ { this->do_adjust_dyn_symbol(sym, view); }
+
protected:
// This struct holds the constant information for a child class. We
// use a struct to avoid the overhead of virtual function calls for
@@ -763,6 +768,11 @@ class Target
do_dynamic_tag_custom_value(elfcpp::DT) const
{ gold_unreachable(); }
+ // This may be overridden by the child class.
+ virtual void
+ do_adjust_dyn_symbol(const Symbol*, unsigned char*) const
+ { }
+
private:
// The implementations of the four do_make_elf_object virtual functions are
// almost identical except for their sizes and endianness. We use a template.