LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Gentoo
User Name
Password
Gentoo This forum is for the discussion of Gentoo Linux.

Notices

Reply
 
Search this Thread
Old 01-06-2012, 11:25 AM   #1
nclinuxredneck
LQ Newbie
 
Registered: Dec 2011
Location: East of Charlotte, NC
Distribution: Gentoo/Sabayon
Posts: 7

Rep: Reputation: Disabled
Talking reducing emerge compile times


I was wondering if recompiling certaing programs incuded as binaries in a stage 3 install with optimized Cflags or anything similar would make a difference in compile times, or would that just be a complete tarbomb, stack-overflow, crashtastic, epic-fail/waste of time? What can I do to reduce compile times on older core2 or p4 systems per-say if anything at all? What are some simple (and safe) things that we can all do to reduce compile times (even if it only is by a small amount?) I know that you can distribute compiling to other systems on the LAN, but this isn't always an option, as we compile on different architectures and we dont all have 1000 node data-centers or large beowolf clusters in our homes or offices!

What do some of you guys do? Or do you just emerge and clock out or go to bed?

I have a feeling this thread will never end, sorry everyone.
 
Old 01-06-2012, 08:44 PM   #2
MS3FGX
Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 351Reputation: 351Reputation: 351Reputation: 351
Outside of a cluster, the only realistic improvement I can think of is faster storage. Upgrade your machine with an SSD drive if possible, but if that's out of your price range you could alternately load it up with as much RAM as the motherboard can handle and compile out of a tmpfs volume.

If you take the storage bottleneck out of the equation, you should see a decent improvement in system performance across the board.

Of course, with older hardware and a limited upgrade path/budget, sometimes you just have to wait for it to chug through...
 
Old 01-06-2012, 08:54 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 12,226

Rep: Reputation: 1019Reputation: 1019Reputation: 1019Reputation: 1019Reputation: 1019Reputation: 1019Reputation: 1019Reputation: 1019
On my P4 I used to kick off emerges and go to bed.
Architecture makes so much difference. On an old quad Xeon server in the office, kernel compiles (non-gentoo) took forever. On my trusty q6600 at home, trundled through in way less time (both 4 Gig, using -j 5).
Basically suck it up and wait ...

I want to know why ?. What does gentoo offer in that realm that Arch doesn't ?.
 
Old 01-07-2012, 02:41 AM   #4
nclinuxredneck
LQ Newbie
 
Registered: Dec 2011
Location: East of Charlotte, NC
Distribution: Gentoo/Sabayon
Posts: 7

Original Poster
Rep: Reputation: Disabled
compile times, Arch vs Gentoo

RAM disk! Wow, I really seem to be closed-minded these days. That would definitely eliminate almost all of the IO constraints, and nowadays we have at least a gigabyte of RAM in most boxes, and compiling anything from the command line only uses 100mb or so. Wonderful idea.

As for the question about Arch vs Gentoo, you are exactly right, Arch allows building from source and actually has a better system than Gentoo does in my opinion, especially when it comes to kernel configuration, and install time. But, for some bizzare reason I just prefer Gentoo for production work (servers, etc.) because most of the software in the repos is right in that "just old enough to be stable, but not ancient" zone, Debain and CentOS are too far behind version-wise and Arch tends to be too far on the bleeding edge. Arch will always grace my desktop at home (probably for the rest of eternity) and you really can't beat it for everyday use. But I prefer Gentoo for servers and production work.

There's just something about Gentoo....
 
Old 01-09-2012, 04:14 PM   #5
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,037

Rep: Reputation: 373Reputation: 373Reputation: 373Reputation: 373
Well, arch is arch and Gentoo is Gentoo.

Gentoo with binaries would be, mostly, arch. But to tell the truth, the focus of both distros is different, and so is the focus of Sabayon and other Gentoo based distros. This has already been discussed a lot of times around the net and particularly in the Gentoo forums.

If you truly intend to improve the compilation times, there's nothing that you can do but to look on better hardware, distributed compilation and ccache (and sane USE and CFLAGS settings to constrain your binaries to the features you need and to get the best from your cpu, and I really mean "best" in the most conservative sense of the word, and not on the crazier/racier meaning of it).

If you want to use precompiled stuff, then you are not really talking about improving compilation times at all.
 
Old 01-10-2012, 10:22 AM   #6
Ion Silverbolt
Member
 
Registered: Sep 2004
Distribution: Gentoo/Xfce, Manjaro/Xfce, SolydXK
Posts: 194

Rep: Reputation: 36
Arch makes for a quick install. Other than that, I prefer Gentoo. I like how easy it is to spin your own kernel. I can see why some would just want a complete and ready to go binary however. A matter of taste here. Also, if a package shows instability, it's very easy to try a different one. There is usually several versions to choose from in portage instead of just one. I use a combination of stable and unstable packages. I'm even using hard masked gcc-4.6.2. All on a fully working system. No other distro can give you that kind of flexibility other than maybe LFS.


As for your problem, setup a binhost. I compile all my packages and my kernel for my zacate netbook from my hex-core AMD desktop. I put it on a portable usb HD, so I can either plug it in the netbook, or mount it over sshfs. Much quicker method of installation.

There are Gentoo docs that tell you how to setup/install a binhost. It's worth the time if you want Gentoo but are tired of compile times. Especially if your desktop can compile Libreoffice in 20 minutes.
 
Old 01-12-2012, 02:46 PM   #7
alan_ri
Senior Member
 
Registered: Dec 2007
Location: Croatia
Distribution: Debian GNU/Linux
Posts: 1,733
Blog Entries: 5

Rep: Reputation: 127Reputation: 127
Quote:
Originally Posted by nclinuxredneck View Post
As for the question about Arch vs Gentoo, you are exactly right, Arch allows building from source and actually has a better system than Gentoo does in my opinion, especially when it comes to kernel configuration, and install time.
Well, I would not agree. Gentoo, oh, allows building from source and actually Gentoo has a better system than Arch in my opinion, especially when it comes to kernel configuration, and install time.

Anyhow, as something to start with, you may read this; http://www.gentoo.org/doc/en/handboo...?part=2&chap=3

BTW, I have a feeling that Gentoo has one lovely documentation.
 
Old 01-25-2012, 03:11 AM   #8
nclinuxredneck
LQ Newbie
 
Registered: Dec 2011
Location: East of Charlotte, NC
Distribution: Gentoo/Sabayon
Posts: 7

Original Poster
Rep: Reputation: Disabled
RE-Compile times

Gentoo does have wonderful docs. Honestly, I hate to contradict myself here, but for a while I was a bit of an Arch fanboy. It was a really fun toy for while. But Gentoo's quality and customization is unprecedented. I really began to appreciate it more when my Arch box kept seg-fauting and my Gentoo box had 2 weeks uptime! I have discovered that in the long run, the compile times are worth it. For something like an HTPC playing 1080p video, Gentoo's CFlags and custom options make a big difference in performance as well as stability. I own my own IT consulting company and also am a repair tech on the side, and I wouldn't trust my business to anything other than the superior quality and stability of Gentoo. I can read exotic filesystems (UFS, OS2, HP-AIX, etc.) have good video performance, and excellent security (via hardened profile.) All the guys I work with use XP, and while they're looking at registry keys, trying to get third-party software just to read a HFS disk, and attempting to install device drivers that don't exist, I'm actually working!

Compile times are worth it!!! But having enough RAM is critical, as not enough can turn a 48min LibreOffice build into a 48hr Libreoffice build! And, guys, not preaching here, I am registered a newbie, but things go so much better when you ACTUALLY LOOK AT EBUILD FILES before you hit enter! It can save so many headaches later.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Reducing Update Times 311Sam Ubuntu 2 03-13-2007 07:44 AM
Gentoo + KDE -> Emerge/Compile Errors bfloeagle Linux - Distributions 4 09-29-2005 11:54 AM
Getting a compile error running emerge --emptytree system jon_k Linux - Software 2 06-13-2005 09:52 PM
emerge compile options MrJoshua Linux - Software 0 06-07-2004 03:58 PM
kernel compile times danchan Linux - General 2 04-11-2004 06:33 PM


All times are GMT -5. The time now is 07:03 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration