Does Gentoo really *have* to compile *everything* from source or is that just Gentoo's preferred way of doing things?
GentooThis forum is for the discussion of Gentoo Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Does Gentoo really *have* to compile *everything* from source or is that just Gentoo's preferred way of doing things?
I heard somewhere that the Gentoo package manager compiles *everything* from source, but seeing the firefox-bin package it looks like that is not the case. So does Portage really compile everything from source?
You pretty much answered your own question. While many packages are offered as binaries, yes, Portage primarily compiles from source. If you're interested in trying out a neat little Gentoo installation that can easily be changed from a binary-to-source pure Gentoo system, you might try CloverOS.
Some of the larger pkgs like libreoffice or FF are offered in binary form. everything else is compiled. it's why people choose Gentoo. If you want that much control over the software, you pretty much need to build it yourself. If it doesn't matter to you, use a binary distro.
Compiling libreoffice from source is very difficult because it takes days and some bits have to be downloaded "live". There's instructions for doing it in BLFS but I know people have had trouble with it. I'm not surprised Gentoo provides binaries; Crux does as well.
I seem to remember that when I briefly tried Gentoo several years ago, there was a restrictive license covering firefox-bin. You could only use it on the machine you downloaded it to, because use on other local machines constituted "distribution" and the build wasn't licensed by Mozilla.
I've never had an issue compiling any package, but then again my build machine is a monster (12 core xeon, 96gb ram). Actually for me, webkitgtk and compilers (llvm60, 70) take a long time (1+ hours). I am not using Linux though, but the build times on Linux were comparable.
For those folks with less horsepower, compiling doesn't make sense - the optimizations aren't THAT noticeable any more.Back in the days of pentium 1, 2, 3, it mattered!
Compiling everything from source is kind of the whole point of Gentoo.
There are lots of binary distros out there, some of them are offspring of Gentoo, such as Sabayon.
It's not about performance improvement (at least, for me, it never was) but about being able to swith on/off functionality in every single package, or being able to change every piece of the distro to your liking, without having to keep track of every single dep yourself (just like in Linux From Scratch, for example). This serves a number of purposes. For example, for critical things, having less code paths enabled usually means a lesser attack surface, and probably less bugs (though that's arguable). Size is also a concern in embedded devices, and Gentoo is a brilliant tool for developers of any kind, because you don't have to go around fishing and installing -dev(el) packages to compile whatever thing you need to compile. Maintaining your own set of patches for system packages is quite simple using portage, and the slotting mechanism is also nice.
There are some binary packages, this is for a number of reasons, not only because of package size, but also because of license issues. If you go purist, then there's (almost) no single distro that can be built without binary packages nowadays, because you will almost always depend on binary drivers, firmware blobs, closed source programs, etc.
I don't think Linux From Scratch is comparable. The build instructions in LFS are very rigid; they have to be to make everything work. The configure options that you use in each build are laid down and there is nothing like Gentoo's use flags. BLFS cuts you a bit more slack in that you can choose which packages to install, but you still need to respect the configure options provided and the dependencies that the book treats as required or recommended.
Gentoo gives you unrivalled freedom of choice but not everybody wants that.
I don't think Linux From Scratch is comparable. The build instructions in LFS are very rigid; they have to be to make everything work. The configure options that you use in each build are laid down and there is nothing like Gentoo's use flags. BLFS cuts you a bit more slack in that you can choose which packages to install, but you still need to respect the configure options provided and the dependencies that the book treats as required or recommended.
Absolutely, that's the true power of portage. In LFS, whatever you do, you gotta keep the pieces when it breaks, and you have to keep track of every single thing yourself. Included, but not limited to: deps, abi breakage, library versioning, etc.
Quote:
Gentoo gives you unrivalled freedom of choice but not everybody wants that.
Sure. But, if you want that, then Gentoo is the most safe and easy way to go, definitely.
It's not about performance improvement (at least, for me, it never was) but about being able to swith on/off functionality in every single package, or being able to change every piece of the distro to your liking, without having to keep track of every single dep yourself (just like in Linux From Scratch, for example). This serves a number of purposes. For example, for critical things, having less code paths enabled usually means a lesser attack surface, and probably less bugs (though that's arguable).
Same here. The performance is great, but the fine-grained control afforded by USE flags is the main benefit, for me.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.