I'm writing a D application which I want to package as a Debian package.
Does anyone know of a tutorial, or a skeleton package, to show me how to to do this for a D application?
Do I need to use autotools to build it?
Thanks,
Chris.
I'm writing a D application which I want to package as a Debian package.
Does anyone know of a tutorial, or a skeleton package, to show me how to to do this for a D application?
Do I need to use autotools to build it?
Thanks,
Chris.
IIRC, by default, D programs are stand alone; i.e. aside from system level .so dependencies (that shouldn't be included in the .deb) they have no dependencies. There are ways to make this not true but they are the exception. Consequently, a D 'hello world' binary, particularly from that standpoint of installing it, will look a lot like a C one.
The upshot of this is that, unless you are doing something strange, a C 'hello world' Debian package should be good enough to get you started.
If you know of any packaged D application, you can get the package's source:
apt-get source the-package-name
Provided that you added a deb-src
entry in your sources.list.
The source language of your project is rather unimportant. If it already has a Makefile, all you do in debian/rules
is make install
with the target paths set up where the packaging scripts expect (you might want to hack the main Makefile to support the DESTDIR installation prefix). I would recommend Debhelper et al.; then your job is basically to fill in the debian/README.Debian and debian/copyright files, and comment out unnecessary stuff from debian/rules.