Compilation failure with WITH_DTRACE_TESTS on mips/mips and powerpc/powerpc; it's trying to compile a host object on mips/powerpc because MAKEOBJDIRPREFIX is incorrect

From: NGie Cooper <yaneurabeya_at_gmail.com>
Date: Fri, 30 Oct 2015 13:57:10 -0700
Hi Bryan/Simon!
	I tried doing buildworld on powerpc/powerpc with -DWITH_DTRACE_TESTS and I ran into this linker issue below. I have no idea (yet) why it’s trying to compile an x64 object when I specify powerpc/powerpc — and more importantly, why is the object not being put in obj.powerpc?
	I ran into the same issue on ref11-amd64.freebsd.org when I ran “make tinderbox".
Thanks!
-NGie

% make buildworld TARGET=powerpc TARGET_ARCH=powerpc
…
===> cddl/usr.sbin/dtrace/tests/common/json (all)
(cd /usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json &&  DEPENDFILE=.depend.tst.usdt.exe  NO_SUBDIR=1 make -f /usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json/Makefile _RECURSING_PROGS=  PROG=tst.usdt.exe )
cc  -O2 -pipe -fno-strict-aliasing -O2 -pipe   -O0 -g -I/usr/obj/powerpc.powerpc/usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json -std=gnu99 -fstack-protector-strong    -c /usr/src/svn/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/json/tst.usdt.c -o tst.usdt.o
dtrace -C -x nolibs -G -o usdt.o -s /usr/src/svn/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/json/usdt.d tst.usdt.o
dtrace: failed to link script /usr/src/svn/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/json/usdt.d: incorrect ELF machine type for object file: tst.usdt.o
*** Error code 1
$ find /usr/obj/usr/src/svn/ -name tst.usdt.o
/usr/obj/usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json/tst.usdt.o
$ file /usr/obj/usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json/tst.usdt.o
/usr/obj/usr/src/svn/cddl/usr.sbin/dtrace/tests/common/json/tst.usdt.o: ELF 64-bit LSB relocatable, x86-64, version 1 (FreeBSD), not stripped
Received on Fri Oct 30 2015 - 19:57:12 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:00 UTC