Installing simplejson issues

Diez B. Roggisch deets at nospam.web.de
Sat Mar 29 18:45:09 EDT 2008


Gabriel Genellina schrieb:
> En Fri, 28 Mar 2008 23:23:01 -0300, <blwatson at gmail.com> escribió:
> 
>> On Mar 28, 1:57 pm, "Gabriel Genellina" <gagsl-... at yahoo.com.ar>
>> wrote:
>>> En Fri, 28 Mar 2008 16:14:07 -0300, <blwat... at gmail.com> escribió:
>>>
>>> > I am trying to install the twitter python wrapper...I got that
>>> > installed just fine, but am having serious troubles getting the
>>> > simplejson package to install.  I need help diagnosing where this is
>>> > failing.  I am trying to use:
>>>
>>> >http://pypi.python.org/pypi/simplejson
>>>
>>> > and I run "python setup.py build" and then "python setup.py install",
>>> > which both seem to work just fine.
> 
> I tried to install the package but failed. Looks like the setup.py used 
> by simplejson is broken - doesn't handle well the case when the C 
> extension can't be compiled.
> When I run `python setup.py install` I got this message:
> 
> building 'simplejson._speedups' extension
> **********************************************************************
> WARNING: The C extension could not be compiled, speedups are not enabled.
> 
> Below is the output showing how the compilation failed:
> 
> Python was built with Visual Studio version 7.1, and extensions need to 
> be built
>  with the same version of the compiler, but it isn't installed.
> **********************************************************************
> 
> and later:
> removing simplejson.egg-info\native_libs.txt
> ...
> error: can't copy 'simplejson.egg-info\native_libs.txt': doesn't exist 
> or not a regular file
> 
> I suggest that you remove the simplejson-xxxxxx.egg file and delete the 
> simplejson entry in easy-install.pth (both in your site-packages directory)
> Then extract the simplejson directory from inside the original .tar.gz 
> archive into your site-packages directory (so you end up by example with 
> a .../site-packages/simplejson/decoder.py file, among others)
> That appears to be enough; import simplejson worked fine for me.
> 
> I hate those f****ng eggs. Ah, and I hate easy_install too.

This has nothing to do with setuptools or easy_install per se. The 
author of simplejson tried to create a library that works with or 
without a C-extension. And failed.

As your above approach fails to even *try* and compile the speedups.

Diez



More information about the Python-list mailing list