Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Commit [63b569] Maximize Restore History

Tidy powerpc64 bfd target check

Testing for a bfd_target vector might (will!) break. See
https://sourceware.org/ml/binutils/2014-04/msg00283.html

It's safer to ask BFD for the target name. I left the direct target
vector checks in configure tests, and updated them, even though the
target vector is no longer used in oprofile code, because a run-time
configure test for powerpc64 support in bfd:
#include <bfd.h>
int main(void)
{ return !bfd_find_target("elf64-powerpc", (void *)0); }
unfortunately isn't possible when cross-compiling.

The bfd_target vector tests could be omitted if we aren't bothered by
the small runtime overhead of a strncmp on targets other than
powerpc64.

* libutil++/bfd_support.cpp (get_synth_symbols): Don't check for
ppc64 target vector, use bfd_get_target to return the target
name instead.
* m4/binutils.m4: Modernize bfd_get_synthetic_symtab checks to
use AC_LINK_IFELSE. Check for either powerpc_elf64_vec or
bfd_elf64_powerpc_vec.

Signed-off-by: Alan Modra <amodra@gmail.com>

Alan Modra Alan Modra 2014-05-02

Maynard Johnson Maynard Johnson 2014-05-02

changed libutil++
changed libutil++/bfd_support.cpp
changed m4
changed m4/binutils.m4
libutil++
Directory.
libutil++/bfd_support.cpp Diff Switch to side-by-side view
Loading...
m4
Directory.
m4/binutils.m4 Diff Switch to side-by-side view
Loading...