Hello i wanted to know how can get Ubuntu source code and compile it on my own .

Basically i wanted to give it a try so can some one help me regarding the steps to compile a full Ubuntu system .

Also would this be beneficial as compared to installing from per-compiled binary?


There would be little benefit compiling from source. If you are dead set on this then you would probably be better switching do a Linux distribution that is aimed at this sort of user, such as Gentoo. This is designed around the user compiling from source and therefore would suit you better.

Ubuntu is simply a collection of open source tools put together in a way that makes it a good OS for people to use. It is not a single piece of software to be compiled. If you wanted to compile an Ubuntu system from source code you would have to discover all the pieces of software (Kernel, X windows, all other software on top of that) that Ubuntu uses and compile it yourself. Then add all the package management software such as apt on top as well.

Unless there is a good reason to attempt this, I wouldn't bother. As I said before, switch to Gentoo if you want to compile everything yourself, Ubuntu wouldn't be the first choice.

  • Even the official Ubuntu doesn't do a full rebuild very often. Individual packages are rebuilt as and when they are updated. As far as I know, it's quite possible that there's a package in the latest release that is years old!
    – ams
    Nov 24 '11 at 14:01
  • @ams: I'm not so sure if what you say is true. I think the packages are rebuilt every time there's a new release. This helps since this checks if the package can be built from source (otherwise you have to file a bug tagged "FTBFS" - failed to build from source) [1] en.wikipedia.org/wiki/FTBFS [2] qa.ubuntuwire.org/ftbfs Dec 25 '11 at 15:24
  • @medigeek They're built, yes, but they're not re-released, and it's not a full bootstrap rebuild, as far as I know. That is to say, the new builds are discarded as soon as it been shown that they can be rebuilt.
    – ams
    Dec 29 '11 at 19:29
  • @ams: Do you have a reference for this? Compilers/optimizers are improved quite often (especially for performance). Recompiling allows all executables binaries to benefit from the improvements. Aug 22 '12 at 8:45
  • Here's an example package: launchpad.net/ubuntu/+source/xdot . The exact same package build, albeit copied, is used in Natty and Oneiric, and then it gets an upgrade, but again Precise and Quantal share the same package name, and if it has the same name it's the same package, or else apt-get upgrade wouldn't work.
    – ams
    Aug 23 '12 at 12:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.