Opened 6 years ago
Closed 5 years ago
#3738 closed enhancement (fixed)
Make python version configurable on compilation time
Reported by: | pmav99 | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.8.0 |
Component: | Compiling | Version: | git-releasebranch78 |
Keywords: | python3 | Cc: | |
CPU: | Unspecified | Platform: | All |
Description
Not sure how easy it would be to implement, but I think it would be a good idea to have a configuration option that would let us choose the python binary for the compilation and the GRASS session. E.g.
--with-python=/usr/bin/python2 # vs --with-python=/usr/bin/python3 # or even a virtualenv --with-python=/home/username/.venvs/grass/bin/python
Change History (3)
comment:1 by , 6 years ago
comment:2 by , 6 years ago
The shebangs issue is probably solvable with a find -exec sed
at the end of the compilation. Nevertheless, according to Guido van Rossum everything would be much much simpler if there was only "python2" and "python3". If anyone is interested:
comment:3 by , 5 years ago
Milestone: | → 7.8.0 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Version: | unspecified → git-releasebranch78 |
Meanwhile we have everywhere in G7.8+:
#!/usr/bin/env python3
Closing as fixed.
Note:
See TracTickets
for help on using tickets.
Probably it would make sense, at least for this hardcoded version (this fact is unfortunate since it doesn't even respect GRASS_PYTHON):
Though it would still not solve the problem of all shebangs (
#!/usr/bin/env python
) yet if onlypython3
exists on the system as a binary.