[Distutils] stdeb-0.3 error
greno at verizon.net
Sun Sep 20 22:55:19 CEST 2009
Andrew Straw wrote:
> Gerry Reno wrote:
>> How do I get stdeb 0.4?
> The easiest way:
> git clone git://github.com/astraw/stdeb.git
> cd stdeb
> sudo python setup.py install
> If you want a tarball, please look at my email 09/19/2009 09:36 PM -0700.
Ok, I'll install 0.4 using one of these methods.
What should I do about the easy_installed stdeb 0.3?
Should I try to "remove" 0.3 (I use that term loosely wrt
easy_install) using -m?
>> For bdist_rpm the way that you get pre and postpackage install scripts
>> to run during package install is by using
>> the following in the setup.cfg:
>> install_script = rpm_install_sh.txt
>> then rpm_install_sh.txt gets inserted into the rpm .spec file at the
>> %install marker. Now you can also add other sections into
>> rpm_install_sh.txt like %pre and %post which are sections of shell
>> scripts that run prepackage and postpackage install. As far as
>> 'python setup.py install' build type pre/postinstall, you can subclass
>> install class and just run some scripts either side of parent
>> "install" class.
> I think it would be straightforward to integrate something similar into
> I'm not too much in favor of piggybacking distutils' infrastructure to
> parse the setup.cfg file, though. Perhaps we could parse setup.cfg on
> our own (i.e. replace looking for stdeb.cfg with looking for setup.cfg
> and changing the section name appropriately). In the near term the
> easiest thing is to stick with the stdeb.cfg file for now and and a new
> field for each of pre/post install and pre/post remove.
My preference would be to see something like this maybe in setup.cfg:
pre_install_script = deb_pre_install.sh
post_install_script = deb_post_install.sh
pre_uninstall_script = deb_pre_uninstall.sh
post_uninstall_script = deb_post_uninstall.sh
This is what I was intending to do using the 'bdist_deb' command
extension to distutils.
And that way our users have only one config file they need to be
P.S.: Things that totally frustrate me wrt python:
distutils/setuptools and apt-get(or rpm)/easy_install
More information about the Distutils-SIG