From 6a4699867a44b59f726f108b489d4462d5ce9fa3 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 1 Dec 2006 16:58:12 +0000 Subject: [PATCH] gcc 3.2.2 portability hacks. --- gold/symtab.cc | 11 ++++++++--- gold/symtab.h | 3 ++- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/gold/symtab.cc b/gold/symtab.cc index 21192c1ec43..ededad3ed81 100644 --- a/gold/symtab.cc +++ b/gold/symtab.cc @@ -1275,7 +1275,9 @@ Symbol_table::sized_write_globals(const Target*, if (sym_index != -1U) { - this->sized_write_symbol(sym, shndx, sympool, ps); + this->sized_write_symbol SELECT_SIZE_ENDIAN_NAME(size, big_endian) ( + sym, shndx, sympool, ps + SELECT_SIZE_ENDIAN(size, big_endian)); ps += sym_size; } @@ -1284,7 +1286,9 @@ Symbol_table::sized_write_globals(const Target*, dynsym_index -= first_dynamic_global_index; gold_assert(dynsym_index < dynamic_count); unsigned char* pd = dynamic_view + (dynsym_index * sym_size); - this->sized_write_symbol(sym, shndx, dynpool, pd); + this->sized_write_symbol SELECT_SIZE_ENDIAN_NAME(size, big_endian) ( + sym, shndx, dynpool, pd + SELECT_SIZE_ENDIAN(size, big_endian)); } } @@ -1303,7 +1307,8 @@ void Symbol_table::sized_write_symbol(Sized_symbol* sym, unsigned int shndx, const Stringpool* pool, - unsigned char* p) const + unsigned char* p + ACCEPT_SIZE_ENDIAN) const { elfcpp::Sym_write osym(p); osym.put_st_name(pool->get_offset(sym->name())); diff --git a/gold/symtab.h b/gold/symtab.h index ee3b3a8e2d5..f7a5c4c6503 100644 --- a/gold/symtab.h +++ b/gold/symtab.h @@ -933,7 +933,8 @@ class Symbol_table template void sized_write_symbol(Sized_symbol*, unsigned int shndx, - const Stringpool*, unsigned char* p) const; + const Stringpool*, unsigned char* p + ACCEPT_SIZE_ENDIAN) const; // Write out a section symbol, specialized for size and endianness. template -- 2.30.2