/usr/bin/pythonpoints to/usr/bin/python2.7, the old version 2.7.6 python used by my OS 14.04.For the old python, I wanted to install module
regex:$ sudo python -m pip install regex /usr/bin/python: No module named pipSo in synatpic, I installed
python-pipfor the old python. The above command now said:Python2/_regex.c:46:20: fatal error: Python.h: No such file or directorySo In synaptic, I installed
libpython2.7-dev. Now all works.I also installed a newer version 2.7.9 of Python to
/usr/bin/local/python2.7, by compiling its source.How can I install pip and then install
regexfor my new python?
THanks.
sudo apt-get install python pip?), and it installed for the default old python only, not for the new self-installed python. – Tim Mar 17 '15 at 15:01/usr/local/bin/python2.7 -m pip install regexreturns/usr/local/bin/python2.7: No module named pip./usr/local/bin/python2.7 --versionreturnsPython 2.7.9. Does my python 2.7.9 miss pip? – Tim Mar 17 '15 at 15:40Python.h: No such file or directoryerror when installingregexmodule usingpip? – Tim Mar 17 '15 at 15:42sudo apt-get install python-dev– 0x2b3bfa0 Mar 17 '15 at 15:45/usr/local/include/python2.7/? I found/usr/local/include/python2.7/Python.h– Tim Mar 17 '15 at 15:58ls /usr/local/bin/python2.7/– 0x2b3bfa0 Mar 17 '15 at 16:17