2014-03-24 24 views
0

這裏是安裝Pillow的錯誤。我正在使用OS X Mavericks。 我試圖通過PIP安裝安裝枕頭..爲什麼我不能在我的Mac上安裝枕頭?它給出了一些錯誤

_imaging.c:391:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
       int temp = PyInt_AsLong(op); 
        ~~~~ ^~~~~~~~~~~~~~~~ 
_imaging.c:397:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
       int temp = PyInt_AsLong(op); 
        ~~~~ ^~~~~~~~~~~~~~~~ 
_imaging.c:407:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
       int temp = PyInt_AsLong(op); 
        ~~~~ ^~~~~~~~~~~~~~~~ 
_imaging.c:413:28: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
       int temp = PyInt_AsLong(op); 
        ~~~~ ^~~~~~~~~~~~~~~~ 
_imaging.c:520:17: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
      r = PyInt_AsLong(color); 
       ~ ^~~~~~~~~~~~~~~~~~~ 
_imaging.c:533:25: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
        r = PyInt_AS_LONG(color); 
         ~ ^~~~~~~~~~~~~~~~~~~~ 
/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/intobject.h:52:51: note: expanded from macro 'PyInt_AS_LONG' 
#define PyInt_AS_LONG(op) (((PyIntObject *)(op))->ob_ival) 
          ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~ 
_imaging.c:561:13: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
     r = PyInt_AsLong(color); 
      ~ ^~~~~~~~~~~~~~~~~~~ 
_imaging.c:575:17: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
      r = PyInt_AsLong(color); 
       ~ ^~~~~~~~~~~~~~~~~~~ 
_imaging.c:969:14: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
     *x = PyInt_AS_LONG(value); 
      ~ ^~~~~~~~~~~~~~~~~~~~ 
/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/intobject.h:52:51: note: expanded from macro 'PyInt_AS_LONG' 
#define PyInt_AS_LONG(op) (((PyIntObject *)(op))->ob_ival) 
          ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~ 
_imaging.c:977:14: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
     *y = PyInt_AS_LONG(value); 
      ~ ^~~~~~~~~~~~~~~~~~~~ 
/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7/intobject.h:52:51: note: expanded from macro 'PyInt_AS_LONG' 
#define PyInt_AS_LONG(op) (((PyIntObject *)(op))->ob_ival) 
          ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~ 
_imaging.c:3102:15: warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32] 
     y = i/im->xsize; 
      ~ ~~^~~~~~~~~~~ 
12 warnings generated. 

事後上吊的終端。事情是我可以嘗試以其他方式安裝它,但我想知道爲什麼它不是工作

UPDATE已經哽咽我安裝的事情是,當我安裝WEBP。它一直掛在那裏..

+0

這些似乎都可以忽略*警告*。輸出中有任何錯誤? –

+0

很難從你提供的內容中知道 - 嘗試使用'python setup.py build_ext'構建Pillow,如果成功則使用'python setup.py build';然後回來併發布任何與點差不同的結果,因爲他們可能會說。 – fish2000

+0

@RobAgar它只是在pip安裝後掛起 – Leonid

回答

1

我知道了..我其實在這裏做的是通過

sudo ARCHFLAGS=-Wno-error=unused-command-line-argument-hard-error-in-future pip install pillow

裝枕頭,我意識到我有WEBP和小CMS的問題,所以我手動安裝他們通過下載包..

+0

你好Leonid。我用你的黑客,它似乎已成功安裝,但我不能在python shell中導入它,並且django runserver不能識別它的存在。任何想法可能發生了什麼? – mtndesign

相關問題