LoginSignup
7
8

More than 5 years have passed since last update.

Ubuntu 15.10 で apt-get install python3-pip すると pip3はPython3.5にひもづくっぽい

Last updated at Posted at 2015-10-27

Ubuntu15.10環境のPython3.4にmysqlclientをインストールしようとしたところ、gccのエラーで中断されます。

どうやら、apt-getでpython3-pipをインストールすると、Python3.5に結びつく模様。python3.5-devがインストールされていなかったので、gccエラーになっていたようです。python3.5-devをインストールすれば、エラーは出ないんですけど、それではPython3.5用にしかならないので、今回の問題解決にはなりません。

ということで、easy_install3を利用すると、各バージョンごとのpipが入るようなので、そちらで対応。

# apt-get install python3-setuptools
# easy_install3 pip

Python3.4にmysqlclientインストールしたい場合は、

# pip3.4 install mysqlclient

ただ・・・
3.5と、dist-packagesのパスが同じっぽいけど・・・
とりあえず3.5使わないからいいやw

venv使えって話ですよね・・・

2015-12-21追記

本件、不具合として登録されているみたいですね。

ただ、先ほど新しくインストールした15.10に

# apt-get install python3-pip

したところ、ちゃんとpython3.4に紐付いたみたいですが・・・どうなってるんでしょうね?

7
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
7
8