Re: Help needed making a collection of fonts into a .deb
* Matt Chisholm (email@example.com) wrote:
> I have succesfully made a .deb which I can install & uninstall. Here is how I
> did it: By expanding the sharefont_0.10-7.deb package with dpkg -e and dpkg -x,
> I got directory with the contents of sharefont_0.10-7.deb. I used this
> directory as a model for setting up my own directory of fonts, complete with
> postinst, postrm, & control files. I then ran dpkg -b on this directory, which
> produced a deb file which I can install and uninstall. (and yes, the fonts work
> My question is:
> Is this an appropriate way to proceed (using another package as a model?)?
No, it's not. Using another package as a model is an excellent idea, but
you need to model the _source_ package, not the _binary_ package.
Debian's packaging system works like this: a source package contains all
the source code and instructions on how to build it (that's what the
rules file is -- instructions for how to build your package). A source
package consists of a .dsc (debian source control), a .tar.gz which
contains the upstream source, and a .diff.gz, which contains all the
debian-specific information and building instructions, as well as any
changes to the upstream source.
For you, this will mean that you should put all your fonts into a .tar.gz
file, and call this your upstream source. Then, modify the files in the
debian directory appropriately, using sharefont (or any other font
package) as a guide. When you're finished run 'debuild' (part of the
devscripts package), which will turn your source package into a binary
package (a .deb).
If you want to look at the source package for sharefont, type
'apt-get source sharefont' (making sure you have a deb-src line in
/etc/apt/sources.list). This will automatically download the .dsc, the
.tar.gz, and the .diff.gz, and unextract it all for you. You can go from
Joshua Haberman <firstname.lastname@example.org>