Deb packages in Linux are a kind of alternative to the.msi format in Windows. The.deb file is a self-extracting archive of a program. The emergence of this file format greatly facilitated the installation of applications, which was previously carried out by building from source, which was sometimes quite difficult for both beginners and advanced Linux users.
Necessary
archive with the source code of the required application
Instructions
Step 1
First, check if the program you need is in the.deb format on the Internet. Many popular applications have had an automatic installer for a long time. If a deb package does not exist for your system, then you can safely download the sources of the required utility.
Step 2
Make sure you have installed all the programs you need to build. To do this, in Terminal (Menu - Programs - Accessories - Terminal) enter the following command: sudo apt-get install libtool autotools-dev dpkg-buildpackage fakeroot You can also install these libraries from the Synaptic package manager in Ubuntu.
Step 3
Prepare a working directory in which you will perform all operations. Create a folder convenient for you and unzip your downloaded program into it.
Step 4
Open Terminal and navigate to the appropriate directory. For example: cd / src / my_program / program_123Program_123 is the directory where all application files are located.
Step 5
Perform the initial build:./ configure && make Next, you need to "debianize". In the same directory, run the command: dh_make
Step 6
Next, you will need to select the type of package. The most commonly used is "single binary". To select it, simply enter the letter "s".
Step 7
Open the created "debian" directory and edit the "control" file. Enter a description for the program. These are the words the user will see when they look at the contents of the package in Synaptic.
Step 8
Open debian / rules. Uncomment the "dh_install" line by removing the "#" at the beginning.
Step 9
In Terminal enter: dpkg-buildpackage –rfakeroot And navigate to the directory one level up and view its contents: cd.. && ls
Step 10
Among the rest of the files, you will see the newly created deb package. You can install by double clicking on the file.