1 |
Hi Leho! |
2 |
Thanks for many links, Jude Pereira's work totally missed my search results. |
3 |
|
4 |
In fact I focused on playing with Qemu. First approach was to emulate whole |
5 |
board (using qemu-system-arm) which works so far best of all, but is |
6 |
painfully slow (but not more than other options). As for chrooted |
7 |
environment, I used armv5tel stage3 tarballs available at my university |
8 |
site: |
9 |
http://ftp.fi.muni.cz/pub/linux/gentoo/releases/arm/autobuilds/current-stage3-armv5tel/- |
10 |
it is one of official gentoo mirrors and stage3 tarball contains |
11 |
everything necessary already compiled, including fully operational perl |
12 |
5.12.3. I had no problems emerging any other packages, but as I said, |
13 |
compilation takes ages. |
14 |
|
15 |
Then I tried to move contents of my emulated folder to my ARM target machine |
16 |
and on the machine try to chroot inside it. No problem with |
17 |
compiling/emerging in chrooted environment directly on target machine, but |
18 |
speed is maybe even lower. |
19 |
|
20 |
The last approach I tried was using binfmt support to be able to run arm |
21 |
binaries on my x64 box without the necessity to emulate whole board - I |
22 |
hoped to have much better performance than when using qemu-system-arm. |
23 |
Unfortunately it seems that qemu-arm does not support some system calls or |
24 |
whatever. I untared stage3 on my x64 machine, chrooted into the folder and |
25 |
tried running emerge - simple arm binaries were running fine, but emerge |
26 |
ended with errors like "qemu: Unsupported syscall: 242"... |
27 |
|
28 |
And last of all, I started documenting my approach on google sites: |
29 |
https://sites.google.com/site/czernitko/cross-compilation/cross-compiling-perl-for-arm-architecture |
30 |
|
31 |
Peter |
32 |
|
33 |
2011/10/16 Leho Kraav <leho@×××××.com> |
34 |
|
35 |
> i have managed to cross-compile a pretty complete stage3 for arm i believe |
36 |
> with perl-5.10.1 from |
37 |
> http://git.overlays.gentoo.org/gitweb/?p=proj/embedded-cross.git;a=tree;f=dev-lang/perl |
38 |
> |
39 |
> overall the cross-compile experience was a nightmare, esp. re perl and |
40 |
> python. many packages obscurely fail, but not enough for you to immediately |
41 |
> give up. so it keeps sucking you back in and waste even more time. at the |
42 |
> time i discovered that embedded-cross overlay had mostly done all the |
43 |
> difficult work for me, but it seems it is no longer updated for recent |
44 |
> stuff. i think guys in #gentoo-embedded told me it is a lot of effort to |
45 |
> patch these large packages like perl and python to sanely cross-compile, and |
46 |
> since i think their product thing didn't work out too well, they weren't |
47 |
> going to sink any more time into maintaining for newer versions. |
48 |
> |
49 |
> but jude pereira i believe is doing something with arm stages at least |
50 |
> semi-actively |
51 |
> http://judepereira.com/blog/gentoo-linux-uclibc-stage3-2010-for-embedded/and it is definitely a lot of fun booting pretty much full blown gentoo on |
52 |
> things like Nokia N8x0 internet tablets |
53 |
> https://github.com/slonopotamus/n8x0-overlay |
54 |
> |
55 |
> |