I am using Ubuntu on a bespoke router and after seeing the latency drops capable with custom compiling on Gentoo, I would like to recompile all packages with CFLAGS="-march=atom". The guide for this and a helpful forum thread demonstrate the recompilation steps:

export CFLAGS="-march=nocona"
export CXXFLAGS="-march=nocona"
apt-get build-dep packagename
apt-get -b source packagename
dpkg -i *.deb

Is it possible to automate a complete system recompilation instead of specifying one package at a time and to automatically recompile new package updates before they are installed?


Have a look at apt-build (not installed by default)

  • apt-build has "issues" with Natty, but at least it is an established project to contribute to. If you are after a polished, well packaged solution that you can leave unattended, this most likely is not the tool for you. – Metalshark Jun 10 '11 at 6:13
  • apt-build is no longer maintained. is there another way? – Paul Tsai Aug 7 '19 at 2:16

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.