[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Distributions upgrading to Python 3
From: |
Patrick McCarty |
Subject: |
Distributions upgrading to Python 3 |
Date: |
Sun, 17 Oct 2010 17:38:20 -0700 |
Hello,
Arch Linux will be migrating to Python 3 very soon, and I'm trying to
figure out what to do with regard to LilyPond's build system. I don't
know if Arch Linux is the first distribution upgrading to Python 3,
but this migration will be happening any day now.
The distribution-wide policy is as follows: Any applications that
still need Python 2 will depend on the "python2" package, which
provides a "python2" symlink to the currently installed Python 2
executable (in this case, soon to be "python2.7").
I know that LilyPond proper is not going to migrate yet,
understandably, so I will soon need to use the "python2" package.
There are two issues I am running into:
--) Two scripts still have "/usr/bin/python" lines
(python/auxiliar/manuals_definitions.py, and scripts/build/pytt.py).
Those should be changed to "@PYTHON@", right?
--) Some scripts use "/usr/bin/env python", which IIRC, is the best
solution for Mac OS X users. However, I would need "/usr/bin/env
python2" instead for these scripts to work.
The rest of the scripts use either "@PYTHON@" or "@TARGET_PYTHON@",
which are substituted early in the make process. This is just a
matter of detecting the appropriate Python at the configure stage.
Would it be feasible to use "#!/usr/bin/env @PYTHON@" or
"#!/usr/bin/env @TARGET_PYTHON@" for all Python scripts, using the
basename of the appropriate Python executable in place of the Make
variables?
Any thoughts about this?
Thanks,
Patrick
- Distributions upgrading to Python 3,
Patrick McCarty <=
Re: Distributions upgrading to Python 3, Benjamin Peterson, 2010/10/17