|
|
Subscribe / Log in / New account

Fedora ponders the Python 2 end game

Fedora ponders the Python 2 end game

Posted Aug 1, 2017 16:55 UTC (Tue) by fratti (guest, #105722)
In reply to: Fedora ponders the Python 2 end game by josh
Parent article: Fedora ponders the Python 2 end game

As far as I know, all distributions aside from CentOS 5 (which is end of life) provide a python2 symlink. This may have been an argument years ago, but nowadays as far as I know, #!/usr/bin/env python2 is a safe bet.


to post comments

Fedora ponders the Python 2 end game

Posted Aug 1, 2017 17:10 UTC (Tue) by josh (subscriber, #17465) [Link] (2 responses)

Windows has the same problem: the current Python 2 installer for Windows doesn't include a "python2.exe", and as far as I know the Python 3 installer for Windows doesn't include "python3.exe" either.

Fedora ponders the Python 2 end game

Posted Aug 1, 2017 17:12 UTC (Tue) by fratti (guest, #105722) [Link] (1 responses)

Windows also doesn't have shebang lines from what I can tell, so this is a moot point.

Fedora ponders the Python 2 end game

Posted Aug 1, 2017 17:19 UTC (Tue) by josh (subscriber, #17465) [Link]

It still runs makefiles, build scripts, and other things that may need to invoke Python.

Fedora ponders the Python 2 end game

Posted Aug 2, 2017 12:50 UTC (Wed) by ballombe (subscriber, #9523) [Link] (4 responses)

Alas, it is not a safe bet. There are more and more systems where only /bin/env exists.

Fedora ponders the Python 2 end game

Posted Aug 2, 2017 14:55 UTC (Wed) by josh (subscriber, #17465) [Link] (3 responses)

Wait, what? Which systems install env in /bin?

Fedora ponders the Python 2 end game

Posted Aug 3, 2017 20:17 UTC (Thu) by hmh (subscriber, #3838) [Link] (2 responses)

The ones I know of have either /usr -> / or /usr/bin -> /bin symlinked, so /usr/bin/env will just work...

Fedora ponders the Python 2 end game

Posted Aug 3, 2017 20:38 UTC (Thu) by karkhaz (subscriber, #99844) [Link] (1 responses)

Arch does it the other way (/bin is a link to /usr/bin)

$ find / -maxdepth 1 -type l -exec ls -l {} \;
lrwxrwxrwx 1 root root 7 Mar 26 22:57 /lib64 -> usr/lib
lrwxrwxrwx 1 root root 7 Mar 26 22:57 /lib -> usr/lib
lrwxrwxrwx 1 root root 7 Mar 26 22:57 /sbin -> usr/bin
lrwxrwxrwx 1 root root 7 Mar 26 22:57 /bin -> usr/bin

Fedora ponders the Python 2 end game

Posted Aug 4, 2017 5:33 UTC (Fri) by josh (subscriber, #17465) [Link]

That's how many current distributions do it these days, including Fedora. And Debian has an option to do that, if you install the "usrmerge" package.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds