[Distutils] setuptools: mishandles install of non-python scripts

Phillip J. Eby pje at telecommunity.com
Mon Jun 12 18:52:49 CEST 2006


At 05:22 PM 6/9/2006 -0700, Ned Deily wrote:
>In build_scripts.py in distutils.command, distuitils uses the results of
>first_line_re to decide whether to adjust the python value in the shbang
>line of the script: if no "python" is found, distutils installs the
>script without modification.  easy_install.py uses the first_line_re
>test from distutils but seems to unconditionally add a wrapper to the
>script during installation regardless of the script's type.

Who needs shell scripts when you have Python?  ;)

I can (sort of) fix this, but there are some potentially-significant 
limitations.  Notably, if the shell script runs some Python code, it's not 
guaranteed that the library version it accesses will be the same one that 
the script was installed with, or that it will be able to access the 
library at all (e.g., if the user installed it with --multi-version).  I'll 
have to add some kind of warning message when processing non-Python scripts 
in --multi-version mode.



More information about the Distutils-SIG mailing list