Gentoo Archives: gentoo-user

From: Danny YUE <sheepduke@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Questions on Raspberry Pi cross compiling
Date: Thu, 20 Jul 2017 06:33:32
Message-Id: 87k233ehxq.fsf@gmail.com
In Reply to: Re: [gentoo-user] Questions on Raspberry Pi cross compiling by R0b0t1
1 On 2017-07-20 06:25, R0b0t1 <r030t1@×××××.com> wrote:
2 > On Thu, Jul 20, 2017 at 1:20 AM, Danny YUE <sheepduke@×××××.com> wrote:
3 >>
4 >> On 2017-07-20 05:59, R0b0t1 <r030t1@×××××.com> wrote:
5 >>> On Thu, Jul 20, 2017 at 12:42 AM, Danny YUE <sheepduke@×××××.com> wrote:
6 >>>> Hi guys,
7 >>>>
8 >>>> I am setting up cross compiling environment for my newly bought
9 >>>> Raspberry Pi 3, under the guide of:
10 >>>> https://wiki.gentoo.org/wiki/Raspberry_Pi
11 >>>> https://wiki.gentoo.org/wiki/Raspberry_Pi/Quick_Install_Guide
12 >>>>
13 >>>> My original idea was to use crossdev to cross compile packages on my PC
14 >>>> and install binaries on RPI.
15 >>>> However I found it really nasty because it kept giving me the error
16 >>>> message about "libintl: no such file or directory" during compilation of
17 >>>> packages such as attr, python etc.
18 >>>>
19 >>>> And if some (even very few) packages fail to build on the PC, it is
20 >>>> hardly possible to keep PC and RPI 'consistent'.
21 >>>> (Yes, I did setup the 'make.profile' symlink to the right place.)
22 >>>>
23 >>>> So my question is:
24 >>>> 1) If some packages are *doomed* to fail, how do you keep the
25 >>>> emerge world environment consistency between PC and RPI?
26 >>>> Or is my understanding of this method incorrect?
27 >>>>
28 >>>
29 >>> Match compilation and USE flags.
30 >>>
31 >>>> 2) If it is not really a good idea to use crossdev, which one do you
32 >>>> recommend between distcc and chroot method?
33 >>>> (I googled but did not really get one answer about compilation speed.)
34 >>>>
35 >>>
36 >>> You should be able to mix crossdev compiled packages freely with
37 >>> device compiled ones. Incompatible packages will be ignored and it
38 >>> will try to recompile a package with matching flags, so pay attention.
39 >>> If you need to compile something on device then I suspect you want to
40 >>> use distcc if at all possible.
41 >>>
42 >> Thanks for your reply. :-)
43 >>
44 >> Well, yes. But do you know how is distcc compared with chroot referring
45 >> to compilation speed?
46 >>
47 >
48 > Using qemu-user to emulate the target architecture and hosting the
49 > system in a chroot is generally slower than compiling on device, if
50 > that is what you are referring to. I've read of people who tested this
51 > with the RPi3 and some Hardkernel devices.
52
53 Oops, really?
54 I have read of this point of view, too.
55 But the Wiki page says that it is faster than native compilation on RPI.
56
57 To be honest, I prefer to compile using crossdev...
58
59 Ok then, I will try re-setup crossdev on my PC and see if everything
60 compiles well. If not, I will post the error message here.
61
62 Thanks.

Replies

Subject Author
Re: [gentoo-user] Questions on Raspberry Pi cross compiling Danny YUE <sheepduke@×××××.com>