尝试在我的 Mac OS 上使用 pip 安装 python-spidermonkey 失败,因为它缺少 nspr:
$ pip install python-spidermonkey
Downloading/unpacking python-spidermonkey
Running setup.py egg_info for package python-spidermonkey
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 186, in <module>
**platform_config()
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 143, in platform_config
return nspr_config(config=config)
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 87, in nspr_config
return pkg_config("nspr", config)
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 59, in pkg_config
raise RuntimeError("No package configuration found for: %s" % pkg_name)
RuntimeError: No package configuration found for: nspr
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/Users/shengjiemin/work/Ceilo-ENV/build/python-spidermonkey/setup.py", line 186, in <module>
**platform_config()
File "/Users/smin/rmonkey/setup.py", line 143, in platform_config
return nspr_config(config=config)
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 87, in nspr_config
return pkg_config("nspr", config)
File "/Users/smin/ENV/build/python-spidermonkey/setup.py", line 59, in pkg_config
raise RuntimeError("No package configuration found for: %s" % pkg_name)
RuntimeError: No package configuration found for: nspr
----------------------------------------
Command python setup.py egg_info failed with error code 1 in /Users/smin/ENV/build/python-spidermonkey
然后我尝试安装nspr:
sudo port install nspr
但它没有任何区别,仍然是同样的错误。有任何想法吗?