Bugs 553399 and 512590...

Simon Richter sjr at debian.org
Mon Feb 14 15:46:46 UTC 2011


Marco,

> 1) old asterisk-prompt-it contains only GSM format, so i've downloaded
> the file:
> 	http://voip.ammdomus.it/pub/asterisk-core-sounds-it-gsm-1.4.15-mm20090405.tar.gz
> from:
> 	http://voip.ammdomus.it/index.php?option=com_content&view=category&layout=blog&id=3&Itemid=4
> and unpacked:
>  eraldo:/usr/src/asterisk-1.6# mkdir asterisk-prompt-it-gsm-1.4.15-mm20090405
>  eraldo:/usr/src/asterisk-1.6# cd asterisk-prompt-it-gsm-1.4.15-mm20090405
>  eraldo:/usr/src/asterisk-1.6/asterisk-prompt-it-gsm-1.4.15-mm20090405# tar xvvzf ../asterisk-core-sounds-it-gsm-1.4.15-mm20090405.tar.gz
> 
> 2) copy debian/ folder from old package to the new one

These two steps can be done more easily with the "uupdate" program,
available in the "devscripts" package, provided the layout of the initial
source package is still the same.

> 3) alter debian/* files as my knowledge permit, Some note:
>  + renamed package asterisk-prompt-it-gsm, used
>    Provides/Conflicts/Replaces in control (see 5)

As this is a package that is typically explicitly installed, having an
empty package with the old name that depends on the new one is still a good
idea. Provides is mainly useful for satisfying a dependency declared by
another package, but normally users explicitly say "I need Italian voice
prompts" and install the package by name, so there should be something to
provide that name.

>  + tried to fix bug 544281 in control

Excellent.

>  + changed copyright (i've to translate in English?)

Yes and no.

The original copyright statement of the author is what is authoritative. If
there is no English translation available, then there ought to be a short
summary, but with a disclaimer that the translation is not authoritative.

>  + some documentation contain spaces, i've used '*.pdf' in docs...
>  + changed README.Debian
>  + remove all download code in rules
>  + watch not touched, but have to be (i don't know how).

Yes, this one is tricky.

> 4) build with a simple:
> 	debian/rules binary

That is the low-level interface to package building. If you use

   dpkg-buildpackage

instead, that will do the complete run for you (clean the source tree,
build the source package, build the binary packages).

> 5) clearly with a minimal effort i can produce packages with other file
>  formats (alaw, wav, sln16); i don't know if it is better to have 4
> sources package or a single one with more compex debian rules.

That depends on how they are distributed, and on how much effort one wants
to invest.

If there are four separate archives from upstream, you can either build
four source packages, or build a "meta" source package that includes all
the archives as subtrees. That is, however, a difficult thing to do, and
I've only done it once in my career. :)

If there is also a file containing all versions, then it is certainly
preferrable to have just a single source package.

> Or it is better to have a single binary package with all format within.

For binary packages, I think it is generally a good idea to have at least a
package with high quality sources (WAV), and optionally prepacked ones for
systems that have little space or computing power. Asterisk can
automatically recode voice prompts, but will happily use the one that
already has the correct format. GSM is really the worst choice, because
quality has already suffered, no phone network except GSM will use it
natively, and the compression assumes that one has a full-bandwidth
channel, which isn't always the case.

> As i don't know how to make a source package, you can find my work on:

> 	http://eraldo.lilliput.linux.it/~gaio/asterisk-prompt-it-gsm-1.4.15-mm20090405-deb.tgz

I've looked at the package, and it is actually quite good. The issues I've
found are:

 - It builds as a "native" package, that is, when building a source
   package, both the original sources and the Debian specific changes end
   in the same tarball. To build a regular package, you need a symlink from
   "asterisk-prompt-it-gsm_1.4.15-mm20090405.orig.tar.gz" to the original
   archive in the directory above the source tree, and the version number
   needs a packaging version suffix. Also, the layout of the packed and
   unpacked trees need to match, and due to the way dpkg-source handles
   unpacking, this means that everything below "it/" needs to be moved to
   the toplevel (dpkg-source generally thinks that if the first path
   component is the same across all files, then it should be removed).

 - The "debhelper compatibility version" is really low; version 4 has been
   deprecated a long time ago; just raising the number in debian/compat to
   7 has helped get rid of all those warnings.

There are a number of lintian warnings still, but these can be addressed
later (and most of them will vanish on their own).

Now the interesting question: would you be interested in taking care of the
package?

   Simon



More information about the Pkg-voip-maintainers mailing list