memo
virtualenvつくる
[13:15:21] → mkdir -p proj/python/pilTest [13:15:33] → cd proj/python/pilTest [13:15:36] → pyenv versions * system (set by /Users/otiai10/.pyenv/version) 3.3.3 [13:15:41] → pyenv virtualenv 3.3.3 pilTest # 略 Successfully installed pip Cleaning up... [13:16:06] → pyenv versions * system (set by /Users/otiai10/.pyenv/version) 3.3.3 pilTest [13:16:39] → pyenv local pilTest [13:16:47] → python --version Python 3.3.3 [13:16:52] → pyenv version pilTest (set by /Users/otiai10/proj/python/pilTest/.python-version) [13:16:57] →
PILをインストールしようとする
[13:17:52] → pip install PIL Downloading/unpacking PIL You are installing a potentially insecure and unverifiable file. Future versions of pip will default to disallowing insecure files. Downloading PIL-1.1.7.tar.gz (506kB): 506kB downloaded Running setup.py egg_info for package PIL Traceback (most recent call last): File "<string>", line 16, in <module> File "/private/var/folders/75/t48p6tk13b92yfcdqq5_sgjmwq8j2r/T/pip_build_otiai10/PIL/setup.py", line 182 print "--- using Tcl/Tk libraries at", TCL_ROOT ^ SyntaxError: invalid syntax Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 16, in <module> File "/private/var/folders/75/t48p6tk13b92yfcdqq5_sgjmwq8j2r/T/pip_build_otiai10/PIL/setup.py", line 182 print "--- using Tcl/Tk libraries at", TCL_ROOT ^ SyntaxError: invalid syntax ---------------------------------------- Cleaning up... Command python setup.py egg_info failed with error code 1 in /private/var/folders/75/t48p6tk13b92yfcdqq5_sgjmwq8j2r/T/pip_build_otiai10/PIL Storing complete log in /Users/otiai10/.pip/pip.log [13:18:04] →
pipの場所が怪しい
[13:21:59] → which pip /Users/otiai10/.pyenv/shims/pip [13:22:05] → ls ~/.pyenv/versions/pilTest/bin/pip /Users/otiai10/.pyenv/versions/pilTest/bin/pip [13:23:15] →
これ使うべきじゃね?
なんかbrewで入れる文化もあるみたいだ
[13:26:24] → brew search PIL closure-compiler If you meant "PIL" precisely: Instead of PIL, consider `pip install pillow` or `brew install samueljohn/python/pillow`. samueljohn/python/pillow [13:27:20] →
ふぁ?
[13:28:03] → pip search pillow Pillow - Python Imaging Library (Fork) pilbox - Pilbox is an image resizing application server built on the Tornado web framework using the Pillow Imaging Library pillowtop - A couchdbkit changes listener for doing backend processing eirx - Simple image manipulate based on Pillow. elaphe - Generates various barcodes using barcode.ps and PIL/Pillow pillowfluff - Map over CouchDB changes feed built to run on Pillowtop Pillow-PIL - Pillow wrapper for PIL compatibility [13:28:08] → pip install Pillow Downloading/unpacking Pillow Downloading Pillow-2.2.2.zip (2.2MB): 2.2MB downloaded Running setup.py egg_info for package Pillow # 略 Installing collected packages: Pillow Running setup.py install for Pillow Successfully installed Pillow Cleaning up... [13:28:30] →
いけたっぽい?(夕立)
[13:29:15] → python Python 3.3.3 (default, Dec 18 2013, 13:55:06) [GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.2.79)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from PIL import Image >>> >>> exit() [13:29:33] →
いけたっぽい