You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The "Building from Source" instructions on the github wiki page specify that the rust compiler requires
python 2.6 or later, however the ./configure script says that python 2.7 is required.
Our Python situation is really confusing. The configure script indicates that Python is needed for LLVM, but LLVM's docs say it only needs Python for its tests, and we (thankfully) don't run LLVM tests. Perhaps there is some flag that enables them, but by default that is not the case. Furthermore, configure seems to accept Python versions as old as 2.4 (or rather, rejects 2.3 because "LLVM requires Python 2.4-2.7") when provided with a --python=<path> argument, though as @tshepang found it will look for only 2.6/2.7 in the absence of this argument. But LLVM 2.8's docs state that Python ">=2.7" is required (from lurking on the llvm-dev mailing list, I recall that this does not include 3.x).
As if all that wasn't bad enough, we have a number of Python scripts in src/etc/ with no easy way to tell what Python version those require. Not all of those scripts are part of the normal build/development process (for example, some generate tables of precomputed constants). At a glance, I saw one use of the with statement in featurechk.pywhich gives us a lower bound of 2.6 for a normal process. It's also quite possibly that some 2.7 features have slipped in.
Honestly I would be in favor of just requiring 2.7 regardless of whether anything even needs it. Just to make all this confusion stop.
Here are the last few lines of output I get from the rust configure
script:
checking for python... user defined: /usr/bin/python2.6
checking for python >= 2.7... not found
configure: error: found python 2.6.6 (/usr/bin/python2.6); required >= 2.7
See `config.log' for more details.
configure: error: LLVM configure failed
Our Python situation is really confusing. The configure script indicates
that Python is needed for LLVM, but LLVM's docs say it only needs Python
for its tests, and we (thankfully) don't run LLVM tests. Perhaps there is
some flag that enables them, but by default that is not the case.
Furthermore, configure seems to accept Python versions as old as 2.4 (or
rather, rejects 2.3 because "LLVM requires Python 2.4-2.7") when provided
with a --python= argument, though as @tshepang https://github.com/tshepang found it will look for only 2.6/2.7 in the
absence of this argument. But LLVM 2.8's docs state that Python ">=2.7" is
required (from lurking on the llvm-dev mailing list, I recall that this
does not include 3.x).
As if all that wasn't bad enough, we have a number of Python scripts in
src/etc/ with no easy way to tell what Python version those require. At a
glance, I saw one use of the with statement which gives us a lower bound
of 2.6, and it's quite possibly that some 2.7 features have slipped in over
the years. Two scripts that I wrote explicitly require 2.7 but that's
unavoidable and those scripts are not part of the normal build process of
even most development work. The others, no idea.
Honestly I would be in favor of just requiring 2.7 regardless of whether
anything even needs it. Just to make all this confusion stop.
—
Reply to this email directly or view it on GitHub #30618 (comment).
Ah, this error is from LLVM's configure script, not from Rust's. Ours should be updated to correctly check for 2.7, since LLVM apparently requires it1. Someone could check if our LLVM build even requires Python (as mentioned before, the docs say it's only needed for tests, which we don't run). If not, maybe (if all of Rust's Python scripts work on 2.6) building with Python 2.6 could still be supported.
We do not have a github wiki anymore, where did you find this?
Just to be clear, is the github site no longer used for Rust? If not,
the wiki page should at least be updated to say that it's no longer
active, and point users at the current instructions for obtaining and
building the rust compiler.
There is a difference between the GitHub repository and the GitHub wiki. GitHub offers wikis for the projects it hosts, but Rust does not use that capability any more. Rust still uses and will continue to use GitHub for development, issue tracking, etc. — only the wiki is not used any more. For comparison, here is a random example of what GitHub wiki looks like: https://github.com/nim-lang/Nim/wiki
Activity
steveklabnik commentedon Dec 29, 2015
We do not have a github wiki anymore, where did you find this?
Slowhand5 commentedon Dec 29, 2015
Hi Steve,
I found the github wiki page at:
https://github.com/rust-lang/rust
On Tue, Dec 29, 2015 at 3:52 PM, Steve Klabnik notifications@github.com
wrote:
est31 commentedon Dec 29, 2015
I think @Slowhand5 refers to the README: https://github.com/rust-lang/rust/blob/master/README.md#building-from-source
steveklabnik commentedon Dec 29, 2015
Ah ha! Thanks, I will send a fix.
tshepang commentedon Dec 30, 2015
Where in ./configure is 2.7 required? It seems it accepts both 2.6 and 2.7.
hanna-kruppe commentedon Dec 30, 2015
Our Python situation is really confusing. The
configurescript indicates that Python is needed for LLVM, but LLVM's docs say it only needs Python for its tests, and we (thankfully) don't run LLVM tests. Perhaps there is some flag that enables them, but by default that is not the case. Furthermore,configureseems to accept Python versions as old as 2.4 (or rather, rejects 2.3 because "LLVM requires Python 2.4-2.7") when provided with a--python=<path>argument, though as @tshepang found it will look for only 2.6/2.7 in the absence of this argument. But LLVM 2.8's docs state that Python ">=2.7" is required (from lurking on the llvm-dev mailing list, I recall that this does not include 3.x).As if all that wasn't bad enough, we have a number of Python scripts in
src/etc/with no easy way to tell what Python version those require. Not all of those scripts are part of the normal build/development process (for example, some generate tables of precomputed constants). At a glance, I saw one use of thewithstatement infeaturechk.pywhich gives us a lower bound of 2.6 for a normal process. It's also quite possibly that some 2.7 features have slipped in.Honestly I would be in favor of just requiring 2.7 regardless of whether anything even needs it. Just to make all this confusion stop.
Slowhand5 commentedon Dec 30, 2015
presently:
CentOS 6.2 ships with Python 2.6.6 and depends on that specific version. Be
careful not to replace it or bad things will happen. If you need access to
a newer version of Python you must compile it yourself and install it
side-by-side with the system version.
source:
https://github.com/h2oai/h2o-2/wiki/Installing-python-2.7-on-centos-6.3.-Follow-this-sequence-exactly-for-centos-machine-only
script:
checking for python... user defined: /usr/bin/python2.6
checking for python >= 2.7... not found
configure: error: found python 2.6.6 (/usr/bin/python2.6); required >= 2.7
See `config.log' for more details.
configure: error: LLVM configure failed
On Wed, Dec 30, 2015 at 5:32 AM, rkruppe notifications@github.com wrote:
hanna-kruppe commentedon Dec 30, 2015
Ah, this error is from LLVM's configure script, not from Rust's. Ours should be updated to correctly check for 2.7, since LLVM apparently requires it1. Someone could check if our LLVM build even requires Python (as mentioned before, the docs say it's only needed for tests, which we don't run). If not, maybe (if all of Rust's Python scripts work on 2.6) building with Python 2.6 could still be supported.
Slowhand5 commentedon Dec 30, 2015
Just to be clear, is the github site no longer used for Rust? If not,
the wiki page should at least be updated to say that it's no longer
active, and point users at the current instructions for obtaining and
building the rust compiler.
On Tue, Dec 29, 2015 at 4:56 PM, est31 notifications@github.com wrote:
hanna-kruppe commentedon Dec 30, 2015
@Slowhand5
There is a difference between the GitHub repository and the GitHub wiki. GitHub offers wikis for the projects it hosts, but Rust does not use that capability any more. Rust still uses and will continue to use GitHub for development, issue tracking, etc. — only the wiki is not used any more. For comparison, here is a random example of what GitHub wiki looks like: https://github.com/nim-lang/Nim/wiki
frewsxcv commentedon Dec 31, 2015
👍 for not supporting Python 2.6 (which is no longer maintained by the PSF)