Consider you wanted to compile program named ‘Foo’ on your computer then you will need to install build packages by running following code.
Code:
sudo apt-get install build-essential fakeroot dpkg-dev
create a new directory and CD into it.
Code:
mkdir foo-build
cd foo-build
you have to add needed ppa repository to the repository list and update
Code:
sudo add-apt-repository ppa:foo
sudo apt-get update
you have to download the source
it will download and extract source code tree. Once it is completed there would be new subdirectory in the build directory and cd to it.
you should see that you have installed all the dependencies.
Code:
sudo apt-get build-dep foo
dpkg-buildpackage -rfakeroot -b
if you are having multi-core machine then you will need to speed up the build by adding ‘jobs' flag.
Code:
dpkg-buildpackage -rfakeroot -b -j4
once the compilation is completed you back up to the build directory
you will see another deb files which you will need to install
Code:
sudo dpkg -i ./*.deb
Bookmarks