Debian Planet

Welcome to Debian Planet


All your woody are (not quite, but very very very soon) belong to us.
Main Menu

  • Home

  • Topics

  • Web Links

  • Your Account

  • Submit News

  • Stats

  • Top 10

  • Debian

    These are important Debian sites one should not be without!

  • Official Debian site

  • Package search

  • Mailing list archives

  • Bug reports

  • Debian on CD

  • Unofficial woody CD ISOs

  • Unofficial APT sources

  • Developers' Corner

    Other great Debian news sources:

  • Debian Weekly News

  • Kernel Cousin Debian

    (Debian mailing lists digested)
  • Community Groups

    Need help? You're not alone on this planet.

  • debianHELP

    (User support site)

  • Debian International



  • EsDebian


  • DebianWorld


  • MaximumDebian


  • DebianUsers


  • Debian-BR


  • IRC

    The place to get help on a Debian problem (after reading docs) or to just chat and chill is #debian on

    Many of the Debian Planet staff live there so pop by and say hello.

    Wanna write?

    Got that latest or greatest scoop? Perhaps you have some important news for the Debian community? Submit a news item!

    Or perhaps you've written a rather ground breaking insight into some aspect of Debian and you feel compelled to share it with others? Knock up a longer editorial article and send it to the editors.


    DP is sponsored by Xinit Systems and

    Domains paid for and hosted by

    Buy your Debian merchandise at

    Who's Online

    There are currently, 71 guest(s) and 3 member(s) that are online.

    You are Anonymous user. You can register for free by clicking here.

    Debian from source
    Contributed by kvdb on Tuesday, May 21 @ 20:11:58 BST

    Ask Debianplanet
    The potato installer never asked me if I wanted to compile everything from source (ala gentoo). What is the best way to do this in Woody?
    Why is it that the precompiled packages are still the default? I can't think of any advantages but installation time savings...

    alp: Debian packages provide a list of build dependencies, stipulating which other packages which must be present for the package to be built. However, the standard Debian installer doesn't take advantage of this, so you'll have to take a different approach.

    Related Links

  • More about Ask Debianplanet
  • News by alp

    Most read story about Ask Debianplanet:
    XFree86 4.2.0

    Last news about Ask Debianplanet:

    Printer Friendly Page  Send this Story to a Friend
  • "Debian from source" | Login/Create Account | 70 comments

    The comments are owned by the poster. We aren't responsible for their content.

    Re: Debian from source (Score: 0, Flamebait)
    by Anonymous on Tuesday, May 21 @ 20:45:43 BST

    What do you see as the advantage to doing it this way other than beeing 3|33+ and all that ridiculous BS?

    [ Reply ]

    Some ideas on building from source (Score: 1)
    by alp (alp [at] debianplanet [dot] org) on Tuesday, May 21 @ 21:07:57 BST
    (User Info)

    This is a subject that's quite popular on the mailing lists, so I've been able to come up with some interesting resources:

    Policy proposal: Cpu extension code, this article and this one and this thread, and this thread.

    [ Reply ]

    Re: Debian from source (Score: 1, Funny)
    by Anonymous on Tuesday, May 21 @ 23:13:28 BST

    By the way, it's not "ala Gentoo", it's "à la Gentoo".

    My 2 eurocents 😉

    [ Reply ]

    Re: Debian from source (Score: 3, Interesting)
    by Stef on Tuesday, May 21 @ 23:40:53 BST
    (User Info)

    I've been using both Debian and OpenBSD for some time now.

    With OpenBSD's short list of pre-compiled software I have been forced to use the infamous ports tree. More then once have I sat in front of my PC waiting for a package to compile only to have a compile time error!! To boot, you always need to compile the majority of the package dependencies before compiling the actual package that you desire. This is very time consuming on an 550MHz Athlon with 288MB of RAM!!

    On the other hand I've never had the need to attemp to compile my own optimized version of any Debian package. Debian has a huge list of pre-compiled packages that are of the highest quality.

    However, I think that Debian should provide a means for freaks or power users (which ever you want to call them) to compile their own optimized packages. There is no need to have pre-compiled optimized packages when the majority of users will want to optimize further or compile for their specific system

    How about adding i586, p3, and k7 architectures support to the dpkg tools. This way the people who want optimizations can make their own packages with little ease and developpers need only to maintain the packages that they already do.

    Would this be a lot easier then creating an entire optimized distro when only a minority of the software can take advantages of CPU optimizations.


    [ Reply ]

    Re: Debian from source (Score: 3, Informative)
    by oyenstikker (ude.tir@7923bms) on Wednesday, May 22 @ 13:07:57 BST
    (User Info)

    I think I understand the question. He wants to install the system by compiling from source. Sounds reasonable. Most of the posts are about installing specific apps from source for performance increases (KDE, Gnome, X11). Isn't that what apt-get source -b is for? So why not add a choice to the installer to use the apt-get source?

    [ Reply ]

    Re: Debian from source (Score: 0)
    by Anonymous on Wednesday, May 22 @ 20:09:45 BST

    For the dutch speakers here: a script called 'cast' has been written on Search for 'cast valium' (valium is the nick of the author) on that site and download it. You just type 'cast package' and it downloads the package, starts compiling it with some optimizations if you want and installs the .deb and any needed dependencies, that can be source-built too. A good thing: it has resume-support too and features a hack to change the version number to make sure you don't loose your version when the mirrors have a newer release. It's small, but quite cool and way better than 'apt-get source -b' :).

    [ Reply ]

    The balance (Score: 3, Interesting)
    by grolschie on Thursday, May 23 @ 00:24:46 BST
    (User Info)

    There are two schools of thought on this. Both are polarized:

    1). everything needs to be cpu optimized for good performance.:

    2). cpu optimization is not worth the time and effort for such an insignificant performance increase.:

    Here is the balance:
    Although not every app would be noticably improved when optimized, the main stuff like base system, compilers, kernel, X, KDE, Gnome, Mozilla, Netscape, and a few others, would benefit greatly if cpu opitmized. Basically, if everything that is running on the machine at startup (incl lpd, xdm, etc) is optimized, that would be good.:

    The main workhorse apps, and the cpu hungry stuff should be optimized where possible, and for all other 3000+ misc apps can be left as is.:

    3D Games would also benefit from cpu optimization.:

    mc, pppconfig, more, would not be benefitted.:

    Perhaps certain apps that would benefit could be flagged as so, for when some new fangled clever Debian installer/compiler 'apt-get source' replacement is created.

    [ Reply ]

    Question on this subject: (Score: 1, Interesting)
    by Anonymous on Thursday, May 23 @ 12:55:32 BST

    If I use the apt-get source -b method, how do I make sure the compiled binaries are optimized for my Duron/K7 cpu?

    Does it detect the cpu auto-magically, or do I need to install a package or change some system settings somewhere?

    Thanks in advance!

    [ Reply ]

    Compiling from source (Score: 0)
    by Anonymous on Friday, May 24 @ 03:10:03 BST

    It would seem compilation method is not without problems. Build dependancies are not detected until after the source has been downloaded, and the compilation process has started. If one sets this up to download overnight, it can be annoying to find that it died halfway through because of this.

    [ Reply ]

    Re: Debian from source (Score: 1)
    by AnswerGuy on Friday, May 24 @ 03:26:07 BST
    (User Info)

    I have been playing with this process here at work (with a nice fast T1 and a big 40Gb HD).

    Here's a simple shell function:

    function bld () {

    apt-get -y build-dep "$@" &&

    apt-get -y -b source "$@"


    ... that will satisfy the build-deps for a given package or list of packages, and then build it.

    I then wrote a simple one line wrapper around that like:

    dpkg --get-selections | while read p x; do

    [ "$x" = "install" ] && bld $p


    ... which is now wildly building every package that I have installed on that system.

    Of course this is a 31334 exercise to show of my incredibly geeky studliness (Bow before me mere mortals!) --- but it does demonstrate the basic way that one could approach a BSD style make world under Debian.

    I should make some effort to detect if I've already built a given package in this directory (save some bandwidth and plenty of time and CPU).

    Here's a rough cut of a function that might do some of that:

    while read p x; do

    [ "$x" = "install" ]

    && f=$(apt-cache show $p

    | grep ^Filename:

    | { read x f; echo $f; } )


    [ -f "$f" ] || echo $p


    ... this uses apt-cache show to look up the details of the package, extracts the archive filespec for the .deb file, takes the basename of that and checks to see if such a file exists (in the current directory). Thus it acts as a filter to find packages for which I haven't got a local .deb file, which (if it's run in my /usr/local/src/debian directory; where I've run the previous commands) should give a list of packages that I have installed (dpkg --get-selections and find the "install" lines) and which I haven't built into my own .deb.

    In other words, using this script recursively I should be able to build a "self-hosted" Debian. (fetch and install ALL of the software that's needed to build ALL of the software that I have installed; and use that to fetch and build ALL of the sources for the whole shebang).

    Better than that I can do this for any starting set of Debian packages --- so long as it includes enough of the build tools to build anything. (I started this "project" using debootstrap to install Woody into a chroot directory. This starts with a very minimal (60Mb or so) initial package suite.

    [It's actually running as an independent subsystem on a Red Hat 7.1 with an XFS patched kernel --- and the directory in which all of this is running is actually an XFS over an md/soft RAID1 (mirror); though all of those details are irrelevant to the task at hand].

    This may seem like a pointless exercise; but it actually does serve a business need for my current client/customer. They're building a turnkey Linux system and I'm demonstrating the advantage of Debian's build system -- the fact that a little script and leverage Debian's work

    and insfrastructure to make sure that we have everything we need to self-host. (I'm trying to steer them away from Red Hat).

    Basically they have the situation where they are building some packages, and throwing in others as binaries (because resolving all the dependencies is a lot of work, and it increases the total build time). However, they find that the results of all this are somewhat vulnerable to differences among developer workstations (anyone who upgrades to RH7.2 breaks the build on their systems and might build stuff that doesn't run correctly on the target systems -- due to shared library conflicts).

    So part of what I'm doing is demonstrating that a chroot build environment can isolate their software from the local workstation's --- allowing the developers to run their favorite GUI tools upgrade GNOME components, etc; while d

    Read the rest of this comment...

    [ Reply ]

    Debian - Extra strength - Low tar 20's (Score: 1, Funny)
    by Anonymous on Friday, May 24 @ 23:58:50 BST

    Some people like pre-rolled Debian 'tailor-mades', whereas some prefer to 'roll their own'. Either choice will smoke the competition! However, the choice is what makes Linux so good.

    Governent Health Warning:

    Use of either method of Debian installation may damage your rose-colored view of Microsoft products. You will become like the boy who cried out "Look, the emperor is not wearing any clothes!"

    [ Reply ]

    Suggestion for APT (Score: 1, Interesting)
    by Anonymous on Saturday, May 25 @ 05:38:32 BST

    Something like apt-get dist-upgrade --make-from-source would be great. If it could handle all dependancy issues etc.

    [ Reply ]

    Question about 'apt-get source -b' (Score: 0)
    by Anonymous on Monday, May 27 @ 00:32:55 BST

    Why is it that when I use apt-get build-dep and apt-get source -b to download and compile X, KDE, gnome, etc.... that once I install these debs, apt-get upgrade gets confused and want to download and reinstall the binary versions of the packages?

    Kpackage is clever enough to see there are no upgraded packages. However, when I go apt-get upgrade --show-upgraded I see every package that I have compiled from source listed there.

    BTW, I am using Woody.

    [ Reply ]

    Based on: PHP-Nuke

    All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © 2000 by Debian Planet

    You can syndicate our news using the file backend.php.