Inclusion of debian packaging info (was Re: [Flac-dev] libFLAC docs)

Matt Zimmerman mdz at
Thu Jun 14 18:33:24 PDT 2001

On Thu, Jun 14, 2001 at 05:59:53PM -0700, Josh Green wrote:

> It seems convenient to have a way to build packages (RPM, deb) from the
> source itself. Thats how I set it up with the Smurf Sound Font Editor
> (RPMs only). I usually only see this with RPMs though. If I knew how to
> automate this with .debs I would do that as well. Why do you think that
> is beyond the scope of the flac source distribution? Binary packages
> don't always work and a user often has to compile from source. Its nice
> to give them the option of doing so in their native package format.
> What options are available for users building debs themselves from
> source? I'm really only familiar with RPMs which you can do an "rpm -tb
> <package.tar.gz>" to build a binary package from a tar source file
> (looks for the RPM .spec file in the tar.gz) or "rpm --rebuild
> <package.src.rpm>" to rebuild a source RPM package. Lates..

This question comes up regularly on the Debian mailing lists, and there are
arguments for both approaches.  I am against the practice of including a
debian/ directory in upstream source distributions for the following

- The Debian development cycle is mostly orthogonal to the upstream development
  cycle.  Usually, several releases of a Debian package will be made for a
  single upstream release.  This is necessary for proper integration of a large
  number of software packages into Debian.  If the Debian packaging information
  is shipped with the upstream source, it will either be continually out of
  date (and perhaps even broken), or new releases will have to be made with no
  substantial changes for non-Debian users.

- For the same reason, the Debian maintainer would have to have write access to
  the upstream CVS repository.  This is often otherwise unnecessary or

- Debian tools make it very easy for the user to build their own .debs from
  source.  In fact, they don't even need to locate and download the upstream
  source, as this is managed by the Debian packaging system and archive mirror
  network.  For example, a simple recompile (taking into account, say, a local
  CFLAGS or DEB_BUILD_OPTIONS environment variable) can be done with a single

  # downloads, unpacks, patches and builds Debian packages
  apt-get source -b <package>

  Building a version with more extensive modifications is almost as easy:

  apt-get source <package> # downloads, unpacks and patches source
  cd <package>-<version>
  # Edit source files, change configuration, etc.
  dpkg-buildpackage # builds packages

- Debian source packages essentially consist of a copy of the upstream source
  tarball (intact, when possible, so that signature verification and the like
  can be performed) and a compressed diff which includes any debian-specific
  changes.  This makes it easy for the user to recognize what changes were made
  to the source code for the Debian package, and allows the user to selectively
  add or omit such changes.

As for the case where binary packages don't work, that would be indicative of a
bug which needs fixing.  For more information about Debian, see

 - mdz

More information about the Flac-dev mailing list