[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Debianizing tarballs: a Big Deal or a routine skill?

> There have been a number of threads lately about where to find info
> about how to create a .deb package from source. What I'd like to hear
> from people who do this regularly is how complex and involved this is.
> In both cases, it makes most sense to maintain a system the Debian way,
> not partly by hand. I want dselect to remain happy whenever it touches
> my system! So rather than just compile and install the tarballs, I'd
> like to debianize them first.

Well, there already is any easy way to do this - apt-get source.
This command downloads the Debianized source of a package. To use
this command you probably want to do the following:

0. Make sure that you have apt-get and debhelper installed.

1. Add a deb-src line to your /etc/apt/sources.list - something like:
deb-src http://http.us.debian.org/debian stable main contrib non-free

2. Apt-get update

3. Download the source - apt-get source package_name (add a -b if
you want to build the source without making any changes).

4. Make changes to the source if you so desire. Take a look at
debian directory of the source, as well as the Makefile and
configure script.

5. Build the package (if you didn't put -b in step 3). 
dpkg-buildpackage -uc

6. Install the deb(s) that result.

Its really a pretty easy process, if your used to compile packages.
The list I gave above assumes that you have all of the libraries
install that you need.  Often you have to install a *-dev package
or two when trying to build a package from source.  This also
assumes that you want to compile the same version of the source that
the package maintainer has used.  If you want to build a different
version, you may be able to get away with copying the debian directory
from the Debianized source into the non-Debian source that you've

Anyway, that's the basic idea.  Take a look at the documentation
for apt-get and debhelper for more details.

Jim Crumley                  |
crumley@fields.space.umn.edu |
Work: 612 624-6804 or -0378  |

Reply to: