Created attachment 164411 [details] svnlite diff output for sys/boot/. . . [Note: I do not have a context for checking universal builds but the changes below are all in MACHINE_ARCH sections limited to powerpc64.] Based on errors I got trying to use devel/powerpc64-gcc for buidlworld activity I suggest the following patches to the LDFLAGS handling in sys/boot/ofw/Makfile.inc , sys/boot/powerpc/Makefile , and sys/boot/uboot/Makefile.inc for powerpc64 use: (Also as an attachment that should preserve tabs and such.) Index: /usr/src/sys/boot/ofw/Makefile.inc =================================================================== --- /usr/src/sys/boot/ofw/Makefile.inc (revision 292413) +++ /usr/src/sys/boot/ofw/Makefile.inc (working copy) @@ -2,7 +2,7 @@ .if ${MACHINE_ARCH} == "powerpc64" CFLAGS+= -m32 -mcpu=powerpc -LDFLAGS+= -m elf32ppc_fbsd +LDFLAGS+= -Wl,-m -Wl,elf32ppc_fbsd .endif .include "../Makefile.inc" Index: /usr/src/sys/boot/powerpc/Makefile.inc =================================================================== --- /usr/src/sys/boot/powerpc/Makefile.inc (revision 292413) +++ /usr/src/sys/boot/powerpc/Makefile.inc (working copy) @@ -2,6 +2,7 @@ .if ${MACHINE_ARCH} == "powerpc64" CFLAGS+= -m32 -mcpu=powerpc +LDFLAGS+= -Wl,-m -Wl,elf32ppc_fbsd .endif .include "../Makefile.inc" Index: /usr/src/sys/boot/uboot/Makefile.inc =================================================================== --- /usr/src/sys/boot/uboot/Makefile.inc (revision 292413) +++ /usr/src/sys/boot/uboot/Makefile.inc (working copy) @@ -2,7 +2,7 @@ .if ${MACHINE_ARCH} == "powerpc64" CFLAGS+= -m32 -mcpu=powerpc -LDFLAGS+= -m elf32ppc_fbsd +LDFLAGS+= -Wl,-m -Wl,elf32ppc_fbsd .endif .include "../Makefile.inc"
As of 11.0-BETA1 (-r302457) these changes are still needed to allow building a libc++ based powerpc64 environment via devel/powerpc64-gcc (and so devel/powerpc64-xtoolchain-gcc). Being that powerpc64 is tier 2 and devel/powerpc64-gcc is involved in what this helps: I'm not so sure that 11.0-RELEASE would pick these up but may be 11.1-RELEASE would (and 12-CURRENT before that).
Looks like I misclassified this as misc instead of kernel back on 2015-Dec-20. So set it to kernel now.
elf32ppc_fbsd is no longer used in such Makefile.inc files. This is based on the following grep not finding such in a head -r358510 context: # grep -r elf32ppc_fbsd /usr/src/* | more (There are occurrences in other contexts.)