[CCC DEV] Building for Debian/Ubuntu simplified

Adam Sampson ats at offog.org
Tue Jul 6 23:17:34 BST 2010


On Tue, Jul 06, 2010 at 10:28:56AM -0400, Matt Jadud wrote:
> This is made with the Debian tools. I do a build, then move things
> into the appropriate places in a directory structure that gets bundled
> up with
> dpkg --build concurrency ./

Yes, that's how .deb files are generated, but you would never do that by
hand when building a Debian package -- there's infrastructure around it
that does all the hard work for you.

A Debian source package contains a "debian" directory with a "rules"
file in, which is a Makefile with a set of rules with standard names
(most of which are just calls to debhelper in any remotely standard
package). To build the package, you then do "dpkg-buildpackage" in the
source directory and it'll call the appropriate rules and generate the
.deb and associated files.

There's a good walk through how to build a simple package in the New
Maintainer's Manual:
  http://www.debian.org/doc/manuals/maint-guide/index.en.html

I've just gone through this for a native KRoC package, which requires no
customisation of the rules file at all -- the debhelper defaults do the
right thing. Obviously this won't be true for the AVR package, but it'll
basically need to do the same customisation as the .spec file did.
(I've put the result in distribution/debian, in case anybody wants to
fiddle further...)

In terms of stuff lintian complains about:

- several binaries without man pages (e.g. ilibr);
- kroc-setup.sh/csh being in bin but not really being binaries;
- liboccam_*.so don't have version numbers.

I'm not sure any of these are worth fixing for now...

> It is the RPM that is made with "alien".

D'oh! Sorry; I should have read that more carefully.

-- 
Adam Sampson <ats at offog.org>                         <http://offog.org/>




More information about the developers mailing list