[Distutils] easy_install execution question
Paul Ivanov
pivanov314 at gmail.com
Fri Oct 28 07:54:39 CEST 2011
Hi Chris,
On Thu, Oct 27, 2011 at 7:43 PM, Chris Jerdonek
<chris.jerdonek at gmail.com> wrote:
> Hi, I have one more question for the time being. This regards how the
> easy_install script works.
>
> I use Mac OSX, and my /usr/bin directory contains three versions of
> the easy_install script: easy_install, easy_install-2.5, and
> easy_install-2.6.
>
> Based on some debugging lines I tried inserting, when I execute the
> script called simply "easy_install", the script seems to execute just
> the first line (namely "#!/usr/bin/python"), and then seems to
> immediately jump to executing easy_install-2.6.
>
> I was curious about the mechanism that allows the Python interpreter
> to jump mysteriously from one file to another. This doesn't seem to
> be evident from the easy_install scripts themselves. What causes this
> behavior?
It appears to be this way, because your /usr/bin/python points to python2.6.
$ ls -l `which python`
lrwxrwxrwx 1 root root 9 2011-09-09 20:29 /usr/bin/python -> python2.6*
you can verify that no jumping occurs by printing a unique string in each of
`which easy_install` `which easy_install-2.6` `which easy_install-2.5`
--
Paul Ivanov
314 address only used for lists, off-list direct email at:
http://pirsquared.org | GPG/PGP key id: 0x0F3E28F7
More information about the Distutils-SIG
mailing list