Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Distcc & Crosscompiling for debianslug on gentoo box
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Alternative Architectures
View previous topic :: View next topic  
Author Message
Unclethommy
Guru
Guru


Joined: 24 Jul 2006
Posts: 407

PostPosted: Wed Aug 27, 2008 12:04 pm    Post subject: Distcc & Crosscompiling for debianslug on gentoo box Reply with quote

Hi there,

I have been unable to get gentooslug to work on my nslu2 and so gave up and installed debianslug which worked almost out of the box. I have everything on it setup the way I want but it would be really nice to compile from source.

I understand that it is best to run a distcc environment and allow my other (3) gentoo boxes to help with the compiliation.

I think I have set up distcc on the slug correctly but it doesn't seem to want to distrubute.

I presume I have to install crossdev and compile for the correct crossdev architecture (as mentioned in this link http://www.nslu2-linux.org/wiki/GentooSlug/HowToGentooSlugDistccCrossCompile)

I don't quite get what I need to do with /etc/make.profile either (if someone can enlighten me).

From what someone has told me , debian slug runs in Little endian and uses glibc and not ulibc. Would anyone know how to set up the proper environment to get my slug to start distributing?

Any help would be greatly appreciated
Back to top
View user's profile Send private message
armin76
Retired Dev
Retired Dev


Joined: 24 Apr 2006
Posts: 174

PostPosted: Thu Aug 28, 2008 8:13 pm    Post subject: Reply with quote

Uh...so what are you trying to compile and where did you read about make.profile?
Back to top
View user's profile Send private message
Unclethommy
Guru
Guru


Joined: 24 Jul 2006
Posts: 407

PostPosted: Thu Aug 28, 2008 9:37 pm    Post subject: Reply with quote

I am trying to recompile both samba and apache from source on my debianslug in the hope that I can get some extra performance rather than using binary files.

I read about the make.profile here:

http://gentoo-wiki.com/HOWTO_Cross_Compile
Back to top
View user's profile Send private message
armin76
Retired Dev
Retired Dev


Joined: 24 Apr 2006
Posts: 174

PostPosted: Sat Aug 30, 2008 3:39 pm    Post subject: Reply with quote

That guide is for cross-compiling on an arch that isn't the target, i.e. build packages on x86 for arm, without using arm. This gives some problems as well(stuff failing to compile and so).
Its described here: http://www.gentoo.org/proj/en/base/embedded/handbook/?part=1&chap=4

So the better way would be using the slug to compile, with other boxes helping. For that, the doc you mention ( http://www.nslu2-linux.org/wiki/GentooSlug/HowToGentooSlugDistccCrossCompile ) should be enough.
And you'll need to setup the compilers stuff on the slug: http://www.nslu2-linux.org/wiki/GentooSlug/DistccCrossCompileFixupScript.

What you really need is that all the compilers, gcc, g++ and etc, should call /usr/bin/distcc, or wherever the distcc binary is on debian. That is accomplished by exporting the PATH adding the distcc compilers before /usr/bin and /bin and that things, which is what the script from http://www.nslu2-linux.org/wiki/GentooSlug/DistccCrossCompileFixupScript does.
Back to top
View user's profile Send private message
Unclethommy
Guru
Guru


Joined: 24 Jul 2006
Posts: 407

PostPosted: Mon Sep 01, 2008 11:19 am    Post subject: Reply with quote

Thanks armin76, I will run this script when I get home. However, do I still not need to create a crossdev environment on my gentoo boxes so they know how to compile for my slug's arm architecture and the fact that it uses little endian and glibc? Previous instructions on the gentooslug website only mention creating a crossdev environment with ulibc...
Back to top
View user's profile Send private message
armin76
Retired Dev
Retired Dev


Joined: 24 Apr 2006
Posts: 174

PostPosted: Mon Sep 01, 2008 7:35 pm    Post subject: Reply with quote

You only need to run crossdev on the gentoo boxes with the exact CHOST as your slug.

So, what you need to do on the gentoo boxes is what the guide says in the Setup a distcc host (gentoo desktop) paragraph at http://www.nslu2-linux.org/wiki/GentooSlug/HowToGentooSlugDistccCrossCompile

You should change 'crossdev armeb-softfloat-linux-uclibc' by the CHOST of your slug, which you possibly can get by doing: gcc -v on the slug.
For example, on a x86, it says:
Target: i686-pc-linux-gnu
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Alternative Architectures All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum