Trying to install python-spidermonkey using pip on my Mac OS, failed to do so because it's missing 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
I then tried to install nspr:
sudo port install nspr
but it didn't make any difference, still the same error. Any ideas?
Finally I got this fixed by myself by following the thread here :
http://davisp.lighthouseapp.com/projects/26898/tickets/38-trouble-installing-on-mac-os-x-107
Two steps:
1.move the files from the Darwin-XXX folder inside spidermonkey to spider monkey/libjs to get through this error.
2.Make the change below in the file:
libjs/jsutil
from:
to: