Re: general explanation

Kerin Millar <[email protected]>
Newsgroups gmane.linux.gentoo.newbies
Message-ID <[email protected]>
On Fri, 4 Oct 2002 04:45:51 -0700
Pytr <[email protected]> wrote:

> Sorry to bUG. But I'm not grasping this version of Linux.It's 
> source-based...sure...nothing new there..but why does it take a whole
> day to 

In fact, there aren't that many Linux distros that are "source-based", I
can only think of Gentoo and Source Mage off the top of my head and they
are both relatively new in the Linux world. It depends what you mean by
source-based as well. All programs could be thought of as source-based
in one sense (binaries are born of source-code ... always), and
certainly you can get many distros where the source is provided. But
with those distros, you don't actually use the source. You just use the
pre-compiled binaries (compiled *from* the source code) which the
manufacturer of the distro already cooked up for you earlier.

Systems like Gentoo, Source Mage and the *BSDs differ in that few (or
none in the case of Gentoo) binaries are provided and you are expected
to compile your own. It goes further than that though. The Portage
system (which owes a lot to the Ports system in the *BSDs) can
automatically get the latest source code from the net (meaning you have
the latest and greatest) and vastly simplifies the compilation
procedure, ensuring that all dependencies are satisfied and so forth.
Ever tried to install an RPM on RedHat and been told you don't have
another package to satisfy the package you are trying to install? It
doesn't happen with a Ports like system. Furthermore, you can /easily/
optimise the code for your platform. Why compile for 386 if you have a
Pentium IV? You're not taking advantage of the instructions your chip
has to offer. And Gentoo works quite nicely with GCC 3.x, which is
shaping up to be a much better compiler than the ageing GCC 2.9.x
series. Most binary distro providers seem to be using ageing tools which
don't really leverage what we have today - in fact, you simply don't
know how they've chosen to compile it so you can't guarantee anything.
You can optimise to extreme (and dangerous) levels with Gentoo, or you
can optimise for stability/size. It's up to you.

Personally, I got tired of binary distros which you install then one
week later everything you've got is completely out of date or had later
security enhanced or bug fixed versions released; and they're getting
too easy - I actually want to see how a Linux system is put together and
control the process. With Gentoo you just "emerge rsync" then emerge the
package again and hey presto, you've got the latest version. Also, the
"ebuilds" in Portage will typically apply the latest patches if possible
to give you the very best possible. In fact, I'd never run a distro of
Linux before that didn't have bugs, quirks or issues and was never
satisfied with the performance of a typical desktop system until Gentoo
came along.

> install and complie basic interfaces and apps? My 500Mhz has been
> crunching since Thursday morning at 0100 and it's just finished the
> gnome-sources. Am I missing something? Or does it always take so long
> to compile a new install on Gentoo?

Well ... yes. The packages you typically have to install in the first
instance have many, many lines of source code. Unless you happen to have
a extremely high powered machine with multiple processors and 512Mb or
RAM upwards then you cannot expect such source code to be compiled in a
few minutes or even a few hours. Bootstrapping is lengthy (compiling
GCC, binutils and core system packages), XFree86 is enormous, Gnome is
enourmous etc. After you've got your base system ready, it gets better
because most of the user applications you will install will typically be
a lot smaller. There is no way to predict how long it will take but you
can get a rough idea by timing a build and comparing it to the size of
the distribution file containing the source code, which will be found in
/usr/portage/distfiles.

Furthermore, Portage allows you to build binary packages. You still
compile from source, but if you'll get a package meaning you can install
an identical copy extremely quickly in the future (like an RPM). E.g:

  emerge --buildpkg gnome

Then have a look for the package under /usr/portage/packages/All for the
relevant .tbz2 file. If that file is present on a system, then you could
install it later like this, provided it is in the designated packages
directory:

  emerge --usepkg gnome

Sooner or later I think binary packages will perhaps be shared amongst
Gentoo users, to help those who don't want to wait for the bigger
builds. The disadvantage is that you get no control over the compile
options. But if someone builds with safe options like "-march=686 -pipe
-O2" then that should work fine for everyone (at least with a Pentium II
or higher). There has been talk of providing a binary CD.

My opinion is that if you can't wait for these builds then perhaps you
shouldn't be using distributions which are innately based on the concept
of compiling from source. If the benefits are not important to you then
use a conventional distro. For most Gentoo users, the advantages far
outweigh the length of time it takes to get up and running.

--kerframil
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.