我已经用自制软件安装了libmemcached,并试图用PIP安装pylibmc,但无济于事:
Downloading/unpacking pylibmc==1.2.2
Running setup.py egg_info for package pylibmc
Installing collected packages: pylibmc
Running setup.py install for pylibmc
building '_pylibmc' extension
clang -fno-strict-aliasing -fno-common -dynamic -I/usr/local/include -I/usr/local/opt/sqlite/include -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch x86_64 -DUSE_ZLIB -I/usr/local/Cellar/libmemcached/1.0.17/include -I/usr/local/Cellar/python/2.7.6/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c _pylibmcmodule.c -o build/temp.macosx-10.9-x86_64-2.7/_pylibmcmodule.o -fno-strict-aliasing
_pylibmcmodule.c:497:9: warning: variable 'res0' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized]
if (rc == MEMCACHED_SUCCESS) {
^~~~~~~~~~~~~~~~~~~~~~~
_pylibmcmodule.c:528:9: note: uninitialized use occurs here
if (res0 != NULL) {
^~~~
_pylibmcmodule.c:497:5: note: remove the 'if' if its condition is always true
if (rc == MEMCACHED_SUCCESS) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
_pylibmcmodule.c:474:36: note: initialize the variable 'res0' to silence this warning
memcached_result_st *res, *res0;
^
= NULL
_pylibmcmodule.c:1890:9: error: unknown type name 'memcached_server_instance_st'; did you mean 'memcached_server_list_st'?
memcached_server_instance_st svr = NULL;
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
memcached_server_list_st
/usr/local/Cellar/libmemcached/1.0.17/include/libmemcached-1.0/types.h:75:37: note: 'memcached_server_list_st' declared here
typedef struct memcached_server_st *memcached_server_list_st;
^
_pylibmcmodule.c:1892:13: warning: incompatible pointer types assigning to 'memcached_server_list_st' (aka 'struct memcached_server_st *') from 'const memcached_instance_st *' (aka 'const struct memcached_instance_st *') [-Wincompatible-pointer-types]
svr = memcached_server_by_key(mc, key, len, &rc);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings and 1 error generated.
error: command 'clang' failed with exit status 1
我找到了这个链接 - http://sendapatch.se/projects/pylibmc/install.html#requirements但是我不确定要把什么作为LIBMEMCACHED路径 - 因为我已经通过自制软件安装了 - 我尝试了一些路径,但是所有路径都给出了与上面相同的错误