Andy Salnikov added the comment:

Hi Éric,

I am attaching a patch that fixes the problem. The patch is tiny, basically 
1-line. This replaces the direct use of sys.executable with the 
symlink-resolved version of the same path. I made the change for linux/unix 
platforms and also for cygwin/atheos (I'm sure cygwin has symlinks, not sure if 
atheos does but resolving symlinks can't hurt in general). 

The patch was created from default hg branch (3.4.0a0 I guess), I have built it 
and tested in my simple setup. The problem that we have (in 2.7) is indeed 
reproducible without this patch and it is fixed with this patch applied. 

Concerning the unit test - I'm not sure how to write one but if you have 
suggestions I could try. The complications in this case are that python needs 
to be installed in its configured location and the symlink needs to be created 
outside python install directory which points to the installed interpreter. If 
unit test could handle this then it might be possible.

I did not update any documentation, could not find any place to mention this 
change. Sure you will know better what else is needed to be updated. I'd be 
happy to help you with whatever else is necessary to commit this patch.

Cheers,
Andy

----------
keywords: +patch
Added file: http://bugs.python.org/file27800/distutils-sysexecutable.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue16326>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to