0
>>> import pylibmc

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/pylibmc.py", line 55, in <module>
    import _pylibmc
ImportError: dynamic module does not define init function (init_pylibmc)

试图导入pylibmc,它试图导入_pylibmc.so

我正在使用 Mac OSX 10.5.6

4

1 回答 1

2

That's very odd. I (the developer of pylibmc) use Mac OS X 10.6.3 to develop pylibmc, and libmemcached 0.38 should be fine.

Try downloading the actual tarball and unpacking it, then:

$ sudo python setup.py install --with-libmemcached=/path/to/libmemcached-0.38
(lots of output)
$ python -m pylibmc -v
于 2010-04-05T17:56:49.877 回答