How to create a debian file from a binary

This is a simple walk through on how to create a debian file from a binary. I take no responsibility for anything that may or may not happen.

Step 1: Download this files: Debian Packaging tools FE

Step 2: Create a folder called DEBIAN and put the folder into the working folder.

Step 3: Create a file called control

Step 4: Type in these into control:

Package:
Version:
Section:
Architecture:
Essential:
Maintainer:
Description:

Step 5: Save the file in the DEBIAN folder.

Step 6: Go back to the working folder.

Step 7: Create folder usr, go into usr, create folders share, local, and bin.

Step 8: Put the binary file in the bin folder.

Step 9: Go to the share folder. Create application and icons folders.

Step 10 in the application folder create a file called yourprogramsnamegoeshere.desktop (with your program name before the .desktop)

Step 11: Type this in your .desktop file:

[Desktop Entry]
Type=Application
Version=
Encoding=UTF-8
Name=
Exec=/usr/bin/yourprogramnamehere
Comment=
Icon=/usr/share/icons/hicolor/scalable/apps/
Terminal=false
Categories=Application;whereyourprogramshouldgoinapplicationsmenu;
StartupNotify=false
MimeType=

Step 12: Open the terminal: go to the folder holding your working folder. Then type in this command:

sudo dpkg -b workingfolder yourpackagesname.deb

When you get the .deb file you can install it by clicking on the yourpackagesnamehere.deb.

There you have it, now you can produce debian files.

Source: Full Circle Magazine #12 how to create debian files pages 8 to 10.


The Ubuntu Counter Project - user number # 26323

3 Responses to “How to create a debian file from a binary”

  1. Tutku Dalmaz Says:

    Nice topic, thank you so much.

  2. Mike Says:

    Just remember that this is ugly hack. It might be ok if you want to create packages for yourself, but not if you want to distribute something to others. If you really want to create proper Debian package I suggest you ignore this tutorial and read Debian new maintainer’s guide etc.

  3. Diazepan     » How to create a debian file from a binary Says:

    […] a binary in Ubuntu Hardy Heron. This is a step by step walk through of how to create a debian file.read more | digg […]

Leave a Reply