{"id":150,"date":"2014-03-31T06:19:26","date_gmt":"2014-03-31T04:19:26","guid":{"rendered":"http:\/\/andreikucharavy.com\/L3Cache\/?p=150"},"modified":"2014-04-01T03:56:40","modified_gmt":"2014-04-01T01:56:40","slug":"alt-install-of-python-on-ubuntu","status":"publish","type":"post","link":"https:\/\/andreikucharavy.com\/L3Cache\/alt-install-of-python-on-ubuntu\/","title":{"rendered":"Alt-install of Python on Ubuntu"},"content":{"rendered":"<p>Here is a very good link about how to do it:\u00a0http:\/\/www.rasadacrea.com\/en\/web-training-courses\/howto-install-python<\/p>\n<p>To sum it up:<\/p>\n<p><strong>1.<\/strong> Install the dependencies for python compilation on Ubuntu:<\/p>\n<pre>sudo apt-get install build-essential python-dev\r\nsudo apt-get install zlib1g-dev libbz2-dev libcurl4-openssl-dev \r\nsudo apt-get install libncurses5-dev libsqlite0-dev libreadline-dev \r\nsudo apt-get install libgdbm-dev libdb4.8-dev libpcap-dev tk-dev \r\nsudo apt-get -y build-dep python\r\nsudo apt-get -y install libreadline-dev<\/pre>\n<p><strong>2. <\/strong> Download and untar the relevant Python version (here 2.7.6):<\/p>\n<pre>wget https:\/\/www.python.org\/ftp\/python\/2.7.6\/Python-2.7.6.tgz\r\ntar xfz Python-2.7.6.tgz<\/pre>\n<p><strong>3.<\/strong> cd into the untared Python folder and run the configure and make scripts<\/p>\n<pre>cd Python-2.7.6\r\n.\/configure\r\nmake<\/pre>\n<p><strong>4. <\/strong>Make alt-install (it is important to make the alt-install and not install so that $python<br \/>\nreturns the systsem version (question of stability) )<\/p>\n<pre>sudo make altinstall<\/pre>\n<p><strong>5.<\/strong> Clean up<\/p>\n<pre>cd .. \r\nsudo rm -r Python-2.7.6*<\/pre>\n<p><strong>6.<\/strong> Now you can access to different version of python:<\/p>\n<ul>\n<li>the one that came originally:<\/li>\n<\/ul>\n<pre>which python\r\npython<\/pre>\n<ul>\n<li>and the one you need for your other needs<\/li>\n<\/ul>\n<pre>which python2.7\r\npython2.7<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Here is a very good link about how to do it:\u00a0http:\/\/www.rasadacrea.com\/en\/web-training-courses\/howto-install-python To sum it up: 1. Install the dependencies for python compilation on Ubuntu: sudo apt-get install build-essential python-dev sudo apt-get install zlib1g-dev libbz2-dev libcurl4-openssl-dev sudo apt-get install libncurses5-dev libsqlite0-dev libreadline-dev sudo apt-get install libgdbm-dev libdb4.8-dev libpcap-dev tk-dev sudo apt-get -y build-dep python sudo apt-get <a class=\"read-more\" href=\"https:\/\/andreikucharavy.com\/L3Cache\/alt-install-of-python-on-ubuntu\/\">[&hellip;]<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[24],"tags":[],"class_list":["post-150","post","type-post","status-publish","format-standard","hentry","category-prog"],"_links":{"self":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/150"}],"collection":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/comments?post=150"}],"version-history":[{"count":3,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/150\/revisions"}],"predecessor-version":[{"id":153,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/posts\/150\/revisions\/153"}],"wp:attachment":[{"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/media?parent=150"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/categories?post=150"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/andreikucharavy.com\/L3Cache\/wp-json\/wp\/v2\/tags?post=150"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}