dreamwho 发表于 2015-7-6 14:38:41

ubuntu 14.04 lnmp1.2 安装 memcached报错,跪求解决方法

ubuntu 14.04lnmp1.2 安装 memcached报错,跪求解决方法/usr/local/php/include/php/Zend/zend_API.h:302:14: note: expected ?.har *?.but argument is of type ?.onst char *?
ZEND_API int add_assoc_stringl_ex(zval *arg, char *key, uint key_len, char *str, uint length, int duplicate);
            ^
make: *** Error 1
Copy Memcached PHP Test file...
Restarting Apache......
restart apache...done
Starting Memcached...
Starting memcached:done
Memcached install failed!

licess 发表于 2015-7-6 17:39:06

phpmemcached需要比较多的依赖,信息有限,需要全部的安装日志才能确定

dreamwho 发表于 2015-7-6 19:02:33

日志已上传,请帮忙看下Ubuntu 14.04      lamp

licess 发表于 2015-7-6 21:14:49

回复 3# 的帖子

网上看到一个说是cd /root/lnmp1.2-full/src/memcached-2.2.0/
然后编辑php_libmemcached_compat.h 添加上typedef const struct memcached_server_st *memcached_server_instance_st;
然后再/usr/local/php/bin/phpize
    ./configure --with-php-config=/usr/local/php/bin/php-config --enable-memcached --with-libmemcached-dir=/usr/local/libmemcached
    make && make install
试试

dreamwho 发表于 2015-7-6 21:48:25

回复 4# 的帖子

/root/lnmp1.2-full/src/memcached-2.2.0/php_memcached.c: In function ?.hp_memc_do_result_callback?.
/root/lnmp1.2-full/src/memcached-2.2.0/php_memcached.c:3675:2: warning: passing argument 4 of ?.dd_assoc_stringl_ex?.discards ?.onst?.qualifier from pointer target type
add_assoc_stringl_ex(z_result, ZEND_STRS("key"), res_key, res_key_len, 1);
^
In file included from /usr/local/php/include/php/main/php.h:38:0,
               from /root/lnmp1.2-full/src/memcached-2.2.0/php_memcached.h:22,
               from /root/lnmp1.2-full/src/memcached-2.2.0/php_memcached.c:25:
/usr/local/php/include/php/Zend/zend_API.h:302:14: note: expected ?.har *?.but argument is of type ?.onst char *?
ZEND_API int add_assoc_stringl_ex(zval *arg, char *key, uint key_len, char *str, uint length, int duplicate);
            ^
make: *** Error 1

悲剧,....还是不行...:Q

licess 发表于 2015-7-7 08:35:41

那就无解了,只能找他们官方反馈看看什么原因
页: [1]
查看完整版本: ubuntu 14.04 lnmp1.2 安装 memcached报错,跪求解决方法