[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: P4 optimized Debian GNU/Linux?

Turbo Fredriksson <turbo@debian.org> writes:

> It's been discussed before, but I never bothered to look into that,
> since I didn't think I cared :)
> Now, a friend of mine took the time to (more or less) manually recompile/
> repackage/reinstall his Debian GNU/Linux woody box.
> His word was "it WAY faster!". No numbers, just those three words. Got'a
> mean something...

Of cause its faster when you optimize for _your_ system.

> If I remember correctly from the last time I saw this subject come up,
> the resolution was "no, we don't want that". I can't remember why, but
> I don't care (unless it's changed :).

The problem is the number of different systems out there. For people
to benefit you need a i486, i585, P1, P1-mmx, P2, P3, P4, Cyrix, Crusoe,
Via, K5, K6, K7, .... optimized flavour. The benefit is small and even
nonexisting if you don't have the exact right flavour. The time and
space wasteage is huge. Its just not feasable for Debian to invest that
much time, bandwith and mirror space into so little benefit.

> I've tried to install pbuilder, wanna-build and sbuild, but I can't figure
> out how to use them to recompile the whole dist. Wanna-build looks 'dangerous'
> (it seems to do DB lookups @ Debian GNU/Linux etc), and PBuilder can't even
> generate the CHROOTs (neither for sid nor woody!).

You have to feed wanna-build with quinn-diff output. Its a bit messy
and needs work to get to know it.

You don't need pbuilder at all but you need sbuild.

You most certainly want a chroot to build in, use cdebootstrap to make
one and then add the missing things like etc/apt/sources.list,
etc/passwd, etc/group, buildds home, apt-get install build-essential,

You also need buildd to actually build packages wanna-build has in

And then you need some upload queue and apt archive software
(e.g. mini-dinstall) so you can use apt on the new debs.

After all this, once you get it working, you only have the same debs
Debian builds. No optimization yet. For that you would have to hack
around. Most likely to succeed is to replace gcc/g++ with a wrapper
that selectively adds the right flags.

> So... Any ideas on how to do this in a more 'automatic' fashion for my own
> use?

If you are intrested in using a locally compiled Debian maybe you are
willing to sponsor sourcerer.

Sourcerer will setup a chroot for building packages, create an
apt-repository for locally build packages (with higher pin than the
official one) and keps track of packages getting installed by apt and
new sources being uploaded to debian.

When you run "apt-get install foobar" sourcerer will add foobar to its
list of packages that should be build. A cron job later fetches the
source, rebuilds the package locally and adds it to the local archive.
The next time you run "apt-get update; apt-get upgrade" the localy
compiled version will be installed. When a new debian version of
foobar is released Sourcerer will fetch the new source and also build
it locally. The pining of the local repository prevents the old
locally build version to be replaced by the new debian one until its
locally build, i.e. prevents downloading debs that will be rebuild

I have the setup running on my system successfully but the packaging
still needs work. Mainly automating the setup of the initial chroot
and providing a nice frontend to manage failed builds. And a nice,
configurable gcc/g++ wraper has to be written so people can specify
what kind of optimizations they would like.


Reply to: