[Distutils] bdist_deb in stdeb

Gerry Reno greno at verizon.net
Tue Sep 29 18:28:35 CEST 2009

Andrew Straw wrote:
> Gerry Reno wrote:
>> I have attached a replacement 'bdist_deb.py' file that permits passing
>> arguments to bdist_deb which in turn passes them down to sdist_dsc.
>> and a util.py diff (made against the gerry-reno git branch) makes the
>> setup_env_vars work for both the line statements as well as the
>> subprocesses.
> OK, I committed these to the old-stable branch and merged in the
> bdist_deb changes to the master branch. I made some minor changes to
> your option to disable --single-version..., the most significant of
> which is the name, which is now "--disable..." instead of "--ignore...".
> The other is that I'm not using env vars in the debian/rules file -- it
> just clutters it up unnecessarily.
Even so, it would still be more flexible if you leave in the 'export' 
That allows you to use the env vars in both the line AND the 
subprocess.  I know you're not using them right now, but at least later 
people would have the option if they wanted.
And since you refactored the SVEM option you should make sure that there 
is at least ONE env var for the export statement and that can be 
anything, such as export HOME PATH DUMMY, etc. 
It's not absolutely critical but 'export' with no options will print all 
the exported env vars which might look strange in the log/output.

> I still wonder if the (now named) --disable-single-version... option
> actually solves your problem -- you _are_ importing setuptools in the
> same line, so I am mystified by this. 
Ok, here's what happens if I DON'T use the option (shown with the old 
code - same logic):

$ python setup.py  bdist_deb
running build_scripts
if test "2.5" = "2.5" -o "2.5" = "2.4"; then \
          export SVEMOPT="--single-version-externally-managed" ; 
python2.5 -c "import 
install \
            --no-compile ${SVEMOPT} \
error: option --single-version-externally-managed not recognized
<process stops on the error>

I can't explain it, but this is what happens.  This is on Ubuntu Hardy 
using python 2.5.2.

> But anyhow it's now in there and I
> don't think it'll cause anyone any harm because it's unlikely they'll
> use the option.
> I'll probably let this stuff settle for a day or two and then cut new
> stdeb releases (0.3.2 and 0.4.1).
> -Andrew


More information about the Distutils-SIG mailing list