Packaging for gNewSense


This page describes how to start working on gNewSense packages. That means either modifying Debian packages or creating new packages. The most common reasons for working on packages are

However, the difference with Debian should be kept minimal, because every change we do we have to maintain ourselves. That includes


Environment setup

Set some environment variables that are used by the development tools by adding the following lines to your ~/.bashrc:

export DEBEMAIL=""
export DEBFULLNAME="Joe Black"
export EDITOR=emacs

You should fill in your own email address, name and editor of choice. Then run

$ . ~/.bashrc

for these to take effect (or start a new terminal). Then install the necessary packages:

$ sudo aptitude install devscripts quilt

Add the upstream distribution to your package sources by creating /etc/apt/sources.list.d/debian.list with these lines (please replace the URLs with a mirror close to you:

deb squeeze main
deb-src squeeze main
deb squeeze/updates main
deb-src squeeze/updates main

To prevent any Debian packages being installed you must configure pinning in /etc/apt/preferences:

Package: *
Pin: release n=squeeze
Pin-Priority: -1

Now update your package indexes:

sudo aptitude update

Next, set the tags lintian should ignore for modified packages. Put the following in $HOME/.lintiantags.

# Lintian tags to be ignored for gNewSense packages that are derived from
# Debian packages.
# original-maintainer
# bzr://

Make a quilt helper script runnable:

sudo cp /usr/share/doc/quilt/examples/ /usr/local/bin
sudo chmod a+x /usr/local/bin/

Lastly, set the default options for quilt in the ~/.quiltrc file:

QUILT_REFRESH_ARGS="-p ab --no-timestamps --no-index"

Packaging types

New package

If you want to package software that is not yet available in Debian, then follow the guide to build a new package.

Changing a package

If you want to modify an existing package, you first have to know why you want to change it. If the package contains non-free code that needs to be removed, then you have to modify the original source.

On the other hand, if all the sources in the orig archive fall under a free license, but need to be changed anyway, then you follow the package patching tutorial.

CategoryDevelopment CategoryPackaging

Processes/Packaging (last edited 2014-02-01 00:46:45 by FelipeLopez)