Attempt at writing bdist_dpkg
I've found myself making a lot of Debian packages for various Python modules, so I've started working on a bdist_dpkg.py module for Distutils. Currently it's in nondist/sandbox/Lib/ in the Python CVS; you can download a copy from http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/python/python/nondist/sandbox... . When you run it, it creates a debian/ subdirectory containing a dummy changelog and default versions of control and rules. prerm and postinst are also created to compile .py files to .pyc and to remove them. Generated debian/ files contain a special marker and only files containing this marker will be overwritten, so if you have a custom rules or preinst file it won't be stomped on. Issues: * I can't figure out a way to put the marker in the 'control' and 'changelog' files, because their formats don't seem to support comments. * Right now the .deb for a packaged "foo" is named "foo"; it should be pythonX.Y-foo or whatever the Debian convention is. * The bdist_dpkg command needs to grow many options (e.g. setting the package name, using a particular file as the change log, etc.) Suggestions are welcome. If you have CVS access, feel free to modify the code and check in your changes. --amk
participants (1)
-
amk@amk.ca