{"id":150818,"date":"2019-07-15T09:17:42","date_gmt":"2019-07-15T01:17:42","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=150818"},"modified":"2019-07-08T09:18:47","modified_gmt":"2019-07-08T01:18:47","slug":"python-setuptools","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/python-setuptools.html","title":{"rendered":"python\u5230setuptools\u3001pip\u5de5\u5177\u7684\u5b89\u88c5"},"content":{"rendered":"
\r\n\u3000\u3000apt-get install gcc\r\n\r\n\u3000\u3000apt-get install openssl libssl-dev\r\n<\/pre>\n\u5b89\u88c5\u6570\u636e\u5e93\u548c\u5f00\u53d1\u5e93<\/strong><\/span><\/div>\n\r\n\u3000\u3000apt-get install mysql-server libmysqld-dev\r\n<\/pre>\npython\u73af\u5883<\/strong><\/span><\/div>\n\r\n\u3000\u3000\u4e0b\u8f7d\u5730\u5740\uff1ahttps:\/\/www.python.org\/downloads\/\r\n\r\n\u3000\u3000tar -xvf Python-2.7.10.tar.xz\r\n\r\n\u3000\u3000cd Python-2.7.10\/\r\n\r\n\u3000\u3000.\/configure --prefix=\/opt\/python2.7\r\n\r\n\u3000\u3000make\r\n\r\n\u3000\u3000make install\r\n\r\n\u3000\u3000echo \"export PATH=\/opt\/python2.7\/bin:\\$PATH\" > \/etc\/profile.d\/python.sh\r\n\r\n\u3000\u3000echo $PATH\r\n\r\n\u3000\u3000which python\r\n\r\n\u3000\u3000mkdir ~\/.python-eggs\r\n\r\n\u3000\u3000chmod +w ~\/.python-eggs\r\n\r\n\u3000\u3000echo \"export PATH=\/opt\/python2.7\/bin:\\$PATH\" > \/etc\/profile.d\/python.sh\r\n\r\n\u3000\u3000export PATH=\/opt\/python2.7\/bin:$PATH\r\n<\/pre>\nsetuptools\u5b89\u88c5<\/strong><\/span><\/div>\n\u3000\u3000\u8981\u4f7f\u7528easy_install\u5de5\u5177\uff0c\u90a3\u4e48\u9700\u8981\u5b89\u88c5setuptools\uff0c\u65b9\u5f0f\u5982\u4e0b\uff1a<\/p>\n
\r\n\u3000\u3000\u4e0b\u8f7d\u5730\u5740\uff1a\r\n\r\n\u3000\u3000https:\/\/pypi.python.org\/pypi\/setuptools\r\n\r\n\u3000\u3000\u65b9\u5f0f\u5982\u4e0b\uff1a\r\n\r\n\u3000\u3000unzip setuptools-28.8.0.zip\r\n\r\n\u3000\u3000cd setuptools-28.8.0\/\r\n\r\n\u3000\u3000\/opt\/python2.7\/bin\/python .\/setup.py install\r\n<\/pre>\npip\u5b89\u88c5<\/strong><\/span><\/div>\n\r\n\u3000\u3000\/opt\/python2.7\/bin\/pip install -r .\/requirements.txt\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"\u3000\u3000apt-get install gcc \u3000\u3000apt-get install openssl libssl- […]<\/p>\n","protected":false},"author":1479,"featured_media":5927,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-150818","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/150818","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/1479"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=150818"}],"version-history":[{"count":3,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/150818\/revisions"}],"predecessor-version":[{"id":150935,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/150818\/revisions\/150935"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/5927"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=150818"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=150818"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=150818"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}