cygwin python.exe symlink breaks when called from .bat file

Jason Tishler jason at
Wed Dec 15 16:56:17 CET 2004

On Wed, Dec 15, 2004 at 07:21:31AM -0800, gry wrote:
> Under cygwin, the python executable is installed as python2.4.exe with
> a symbolic link to python.exe.  This is fine as long as one is
> operating only withing the cygwin world.  But I execute python from a
> foo.bat file, and windows barfs on the symbolic link.

You can always do the following as a workaround:

    C:\> bash -c python

> I replaced it with a hard link and all is well.

Note the above will only work as a true hard link under NTFS.  IMO, the
above is a better approach.

> Is there some reason this shouldn't be the standard installation under
> cygwin?

Because it would require (more) modification of the Unix build to
accommodate Windows.  IMO, it is not worth the effort.  If you feel
differently, then submit a patch for consideration:

BTW, many other Cygwin commands have this issue too:

    $ find /bin -type l -name '*.exe'


PGP/GPG Key: or key servers
Fingerprint: 7A73 1405 7F2B E669 C19D  8784 1AFD E4CC ECF4 8EF6

More information about the Python-list mailing list