Total confusion over toolchain/xdev behavior
Warner Losh
imp at bsdimp.com
Mon Jul 7 19:28:49 UTC 2014
On Jul 7, 2014, at 12:14 PM, Sean Bruno <sbruno at ignoranthack.me> wrote:
> On Mon, 2014-07-07 at 11:46 -0400, Benjamin Kaduk wrote:
>> On Sun, 6 Jul 2014, Sean Bruno wrote:
>>
>>> -----------------------------------------------------------------------
>>>
>>> Even attempting to do stuff for *clang* enabled architectures bails
>>> because its not respecting prefixes:
>>> MAKEOBJDIRPREFIX=/var/tmp make -s -j 8 xdev XDEV=arm XDEV_ARCH=armv6
>>> -- bails because it tries to:
>>> ===> usr.bin/clang/tblgen (all)
>>> mtree populating //usr/armv6-freebsd
>>> mtree: etc/ntp: Permission denied
>>> _xi-cross-tools
>>> ===> xdev gnu/usr.bin/binutils (install)
>>> ===> gnu/usr.bin/binutils/libiberty (install)
>>> ===> gnu/usr.bin/binutils/libbfd (install)
>>> ===> gnu/usr.bin/binutils/libopcodes (install)
>>> ===> gnu/usr.bin/binutils/libbinutils (install)
>>> ===> gnu/usr.bin/binutils/addr2line (install)
>>> ===> gnu/usr.bin/binutils/as (install)
>>> ===> gnu/usr.bin/binutils/ld (install)
>>> install: //usr/armv6-freebsd/usr/bin/ld: Permission denied
>>> *** Error code 71
>>
>> This seems to be "obviously a bug" that should not be too hard to make
>> progress on, especially if you already have make debug logs.
>>
>> -Ben
>
>
> Sure. I agree its a bug, if my usage of the XDEV target is supposed to
> be supported.
I built the xdev target years ago. There was no notion of it supporting root-less build, since FreeBSD src didn’t support it at all. The folks that added it to FreeBSD missed xdev.
> I don't know who owns this target, what its supposed to be used for, nor
> what its requirements are. All I know is that people tell me its
> supposed to meat my requirements from my original "Objective" statement.
Well, the folks that did clang didn’t update this target. Nor did the folks that did the cross build stuff. Nor the folks that did… Well, you get the idea. It has been an unloved target for some time now, or at least not a priority for people adding things to the system. I’ve done bits and pieces here and there over the years, but I’m sure that it is quite rough around the edges. I fear that your experience validates that assessment.
Having said that, though, the whole cross build ports thing is getting renewed interest after a decade of dormancy (I did xdev maybe 10 years ago to allow Timing Solutions to build some ports with the native arm compiler). Lately bugs have been fixed. You are quite likely the first person to try it without root ever. There will be bumps for that :).
> Is this even the right make target to use?
It is the only target we have that supports building outside the crazy build environment we have.
Just for grins, I did the following on a stock system (without your change to src.opts.mk from Bapt) and not as root:
% mkdir $HOME/D
% make DESTDIR=$HOME/D XDEV=mips XDEV_ARCH=mips xdev WITHOUT_CLANG=t WITHOUT_CLANG_BOOTSTRAP=t WITH_GCC=t WITH_GCC_BOOTSTRAP=t
%
and it hit the stdc++ bits not being defined. Please see above with the "clang folks didn’t properly integrate” Or possibly some other reason.
However, when I remove DESTDIR and build normally as root, it works. If I add DESTDIR to the root build, it works… So there’s definitely something wrong with the non-root build.
Warner
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freebsd.org/pipermail/freebsd-arch/attachments/20140707/c9cac544/attachment.sig>
More information about the freebsd-arch
mailing list