aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-ppc.c
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@ericsson.com>2017-10-14 09:28:07 -0400
committerSimon Marchi <simon.marchi@ericsson.com>2017-10-14 09:28:07 -0400
commit824dfcc311958af08c25d29956da2bab99e240c9 (patch)
tree8605aeda41093e81f7521a900b018b887ba96939 /bfd/elf32-ppc.c
parent9c80ecd646a604fadcc290fca23b34c9454f5feb (diff)
downloadgdb-824dfcc311958af08c25d29956da2bab99e240c9.zip
gdb-824dfcc311958af08c25d29956da2bab99e240c9.tar.gz
gdb-824dfcc311958af08c25d29956da2bab99e240c9.tar.bz2
Fix build failure in linux-osdata.c
Commit Use std::vector in linux_xfer_osdata_processgroups b129dcac882da87767cb863ad8b2572f90e9e5bc broke the build with older gcc (at least 4.7 and 4.8): In file included from /usr/include/c++/4.7/algorithm:63:0, from /home/emaisin/src/binutils-gdb/gdb/nat/linux-osdata.c:40: /usr/include/c++/4.7/bits/stl_algo.h: In instantiation of ‘_RandomAccessIterator std::__unguarded_partition(_RandomAccessIterator, _RandomAccessIterator, const _Tp&) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >; _Tp = pid_pgid_entry]’: /usr/include/c++/4.7/bits/stl_algo.h:2315:70: required from ‘_RandomAccessIterator std::__unguarded_partition_pivot(_RandomAccessIterator, _RandomAccessIterator) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >]’ /usr/include/c++/4.7/bits/stl_algo.h:2347:54: required from ‘void std::__introsort_loop(_RandomAccessIterator, _RandomAccessIterator, _Size) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >; _Size = long int]’ /usr/include/c++/4.7/bits/stl_algo.h:5483:4: required from ‘void std::sort(_RAIter, _RAIter) [with _RAIter = __gnu_cxx::__normal_iterator<pid_pgid_entry*, std::vector<pid_pgid_entry> >]’ /home/emaisin/src/binutils-gdb/gdb/nat/linux-osdata.c:480:57: required from here /usr/include/c++/4.7/bits/stl_algo.h:2277:4: error: passing ‘const pid_pgid_entry’ as ‘this’ argument of ‘bool pid_pgid_entry::operator<(const pid_pgid_entry&)’ discards qualifiers [-fpermissive] Making the operator< method const fixes it. gdb/ChangeLog: * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make const.
Diffstat (limited to 'bfd/elf32-ppc.c')
0 files changed, 0 insertions, 0 deletions