2010-03-03 159 views
3

嘗試使用Mac OSX 10.6安裝Scrapy此guide錯誤在Mac OS X上安裝scrapy 10.6

當從終端中運行以下命令:

cd libxml2-2.7.3/python 
sudo make install 

我收到以下錯誤:

Making install in . 
make[1]: *** No rule to make target `../libxslt/libxslt.la', needed by `libxsltmod.la'. Stop. 
make: *** [install-recursive] Error 1 

繼在Guide,其中涉及建築和安裝libxml2和包的libxslt的第一步似乎是事業有成1 ...

回答

1

感謝@Ned Deily

這些步驟看起來,如果你想在OS X 10.6上運行Scrapy 0.8工作。它使用Python 2.6的Macports安裝,而不是與OS捆綁在一起的。步驟假定Macports尚未安裝。

從這裏獲取最新的MacPorts安裝程序並安裝:

http://www.macports.org/install.php

sudo port install py26-libxml2 py26-twisted py26-openssl py26-simplejson py26-setuptools python_select 

sudo /opt/local/bin/easy_install-2.6 scrapy 

更改〜.profile文件到:

export  PATH=/opt/local/Library/Frameworks/Python.framework/Versions/2.6/bin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:$PATH 
+0

迄今爲止,這對我有效,但是我的〜.profile在哪裏/哪裏? – ian 2010-05-24 06:29:04

+0

您的.profile文件位於/ Users/的根目錄中......它隱藏在Finder中,因此通過Terminal進行導航更容易。您可以使用vi或eMacs對其進行編輯.. .profile基本上登錄shell的配置文件... – cit 2010-05-24 13:49:16