HomeFreeBSD

Fix binutils compilation error with Clang 8

Description

Fix binutils compilation error with Clang 8

Summary:
This change fixes the following compilation error when using clang 8 to cross
compile base to powerpc64:

/usr/src/gnu/usr.bin/binutils/libopcodes/../../../../contrib/binutils/opcodes/ppc-dis.c:100:35:
error: arithmetic on a null pointer treated as a cast from integer to pointer is
a GNU extension [-Werror,-Wnull-pointer-arithmetic]
  info->private_data = (char *) 0 + dialect;
		       ~~~~~~~~~~ ^
1 error generated.
*** [ppc-dis.o] Error code 1

make[6]: stopped in /usr/src/gnu/usr.bin/binutils/libopcodes
1 error

Test Plan:

  • buildworld for x86_64 (native)
  • buildworld for powerpc64 (cross)
  • buildworld for powerpc64 (native)

Submitted by: alfredo.junior_eldorado.org.br
Reviewed By: emaste, pfg, brooks
Differential Revision: https://reviews.freebsd.org/D19235

Details

Provenance
jhibbitsAuthored on
Reviewer
emaste
Differential Revision
D19235: Fix binutils compilation error with Clang 8
Parents
rS344790: Revert revision 254095
Branches
Unknown
Tags
Unknown