Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Aug 2017 21:06:25 +0200
From:      Jan Beich <jbeich@FreeBSD.org>
To:        Andrea Venturoli <ml@netfence.it>
Cc:        freebsd-ports@freebsd.org
Subject:   Re: qemu-aarch64-static
Message-ID:  <k21v-a0cu-wny@FreeBSD.org>
In-Reply-To: <cc27572c-22c8-f5b2-6c2d-e563751d6423@netfence.it> (Andrea Venturoli's message of "Tue, 22 Aug 2017 07:40:33 +0200")
References:  <29906b14-8efa-ba65-985a-fd5b90c76b9b@netfence.it> <fucq-0zjk-wny@FreeBSD.org> <cc27572c-22c8-f5b2-6c2d-e563751d6423@netfence.it>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
Andrea Venturoli <ml@netfence.it> writes:

> On 08/17/17 21:22, Jan Beich wrote:
>> That page is a bit out of date. Nowadays building for aarch64 is as simple as
>>
>>    $ pkg install poudriere qemu-user-static
>>    $ service qemu_user_static onestart
>>    $ poudriere jail -cj 111aarch64 -a arm64.aarch64 -v 11.1-RELEASE
>>    $ poudriere bulk -j 111aarch64 category/port
>
> I can confirm this is working.

To upgrade above jail to native-xtools try

  $ svn co https://svn.freebsd.org/base/releng/11.1 /usr/src
  $ poudriere jail -uj 111aarch64 -x

or create a new jail e.g.,

  $ svn co https://svn.freebsd.org/base/releng/11.1 /usr/src
  $ poudriere jail -cj 111armv6 -x -a arm.armv6 -v releng/11.1 -m svn

>
>> To speed up port builds you may want to consider using native
>> cross-toolchain by creating a jail with -x flag.
>
> Do you have any more info on this?

Nah. native-xtools was briefly mentioned in poudriere-3.1 changelog and
a bit more on EuroBSDCon 2014. I didn't try -x myself until recently.

https://www.youtube.com/watch?v=2J9Lz3pgnbA
https://www.youtube.com/watch?v=JfZIoyQhly4

> Except from poudriere's man page's description I could find no other
> docs. Is there any more elaborate description on what this does and
> how?

poudriere builds native-xtools target under /usr/src, installs it under
/nxb-bin prefix then prepends it via PATH when building ports. For a living
example see armv6 and mips* builders on pkg-status.freebsd.org e.g.,

http://beefy8.nyi.freebsd.org/data/head-armv6-default/p448278_s322683/logs/nasm-2.13.01,1.log

> I built the jail with -x, but how do I check it's using "native-xtools"?

Check /nxb-bin exists and isn't empty e.g.,

  $ file /poudriere/jails/111aarch64/nxb-bin/usr/bin/cc
  /poudriere/jails/111aarch64/nxb-bin/usr/bin/cc: ELF 64-bit LSB executable, x86-64, version 1 (FreeBSD), statically linked, for FreeBSD 12.0 (1200040), FreeBSD-style, not stripped

  $ /poudriere/jails/111aarch64/nxb-bin/usr/bin/cc -v
  FreeBSD clang version 4.0.0 (tags/RELEASE_400/final 297347) (based on LLVM 4.0.0)
  Target: aarch64-unknown-freebsd11.1
  Thread model: posix
  InstalledDir: /poudriere/jails/111aarch64/nxb-bin/usr/bin



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?k21v-a0cu-wny>