This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: Compiling GOLD with GCC 7 fails with compiler errors
- From: Alan Modra <amodra at gmail dot com>
- To: Tobias Burnus <tobias dot burnus at physik dot fu-berlin dot de>
- Cc: binutils at sourceware dot org
- Date: Thu, 9 Jun 2016 10:21:34 +0930
- Subject: Re: Compiling GOLD with GCC 7 fails with compiler errors
- Authentication-results: sourceware.org; auth=none
- References: <20160608083200 dot GB19567 at physik dot fu-berlin dot de>
On Wed, Jun 08, 2016 at 10:32:00AM +0200, Tobias Burnus wrote:
> ../../gold/mips.cc:6146:8: error: conversion from
>
> âstd::unordered_set<{anonymous}::Mips_symbol<64>*, {anonymous}::Mips_symbol_hash<64>, std::equal_to<{anonymous}::Mips_symbol<64>*>, std::allocator<{anonymous}::Mips_symbol<64>*> >::iterator {aka std::__detail::_Node_iterator<{anonymous}::Mips_symbol<64>*, true, true>}â
>
> to non-scalar type
>
> âstd::unordered_set<{anonymous}::Mips_symbol<64>*, std::hash<{anonymous}::Mips_symbol<64>*>, std::equal_to<{anonymous}::Mips_symbol<64>*>, std::allocator<{anonymous}::Mips_symbol<64>*> >::iterator {aka std::__detail::_Node_iterator<{anonymous}::Mips_symbol<64>*, true, false>}â
>
> requested
> ---------------------------------------------------------------
>
> I have not yet investigated since which binutils or GCC change it fails
> and whose fault it is.
I can't reproduce this with gcc rev 237240, but I wonder if using the
Global_got_entry_set typedef fixes the problem for you?
diff --git a/gold/mips.cc b/gold/mips.cc
index b8c74d0..c1c1ee1 100644
--- a/gold/mips.cc
+++ b/gold/mips.cc
@@ -6159,7 +6159,7 @@ Mips_output_data_got<size, big_endian>::do_write(Output_file* of)
}
// Add +1 to GGA_NONE nonzero MIPS16 and microMIPS entries.
- for (typename Unordered_set<Mips_symbol<size>*>::iterator
+ for (typename Unordered_set<Mips_symbol<size>*, Mips_symbol_hash<size> >::iterator
p = this->master_got_info_->global_got_symbols().begin();
p != this->master_got_info_->global_got_symbols().end();
++p)
--
Alan Modra
Australia Development Lab, IBM