Skip to content

Memcached 2.0.1 build failed #11

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
crisbarros opened this issue Mar 30, 2012 · 11 comments
Closed

Memcached 2.0.1 build failed #11

crisbarros opened this issue Mar 30, 2012 · 11 comments

Comments

@crisbarros
Copy link

The following error happens when executing make:

/bin/sh /root/build/memcached-2.0.1/libtool --mode=compile cc -I/opt/php-5.4.0/include/php -I/opt/php-5.4.0/include/php -I. -I/root/build/memcached-2.0.1 -DPHP_ATOM_INC -I/root/build/memcached-2.0.1/include -I/root/build/memcached-2.0.1/main -I/root/build/memcached-2.0.1 -I/opt/php-5.4.0/include/php -I/opt/php-5.4.0/include/php/main -I/opt/php-5.4.0/include/php/TSRM -I/opt/php-5.4.0/include/php/Zend -I/opt/php-5.4.0/include/php/ext -I/opt/php-5.4.0/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /root/build/memcached-2.0.1/php_memcached.c -o php_memcached.lo
mkdir .libs
cc -I/opt/php-5.4.0/include/php -I/opt/php-5.4.0/include/php -I. -I/root/build/memcached-2.0.1 -DPHP_ATOM_INC -I/root/build/memcached-2.0.1/include -I/root/build/memcached-2.0.1/main -I/root/build/memcached-2.0.1 -I/opt/php-5.4.0/include/php -I/opt/php-5.4.0/include/php/main -I/opt/php-5.4.0/include/php/TSRM -I/opt/php-5.4.0/include/php/Zend -I/opt/php-5.4.0/include/php/ext -I/opt/php-5.4.0/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /root/build/memcached-2.0.1/php_memcached.c -fPIC -DPIC -o .libs/php_memcached.o
/root/build/memcached-2.0.1/php_memcached.c: In function ‘zim_Memcached___construct’:
/root/build/memcached-2.0.1/php_memcached.c:415: warning: assignment makes pointer from integer without a cast
/root/build/memcached-2.0.1/php_memcached.c: In function ‘php_memc_get_impl’:
/root/build/memcached-2.0.1/php_memcached.c:554: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char *’ but argument is of type ‘const char *
/root/build/memcached-2.0.1/php_memcached.c:615: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char *’ but argument is of type ‘const char *
/root/build/memcached-2.0.1/php_memcached.c: In function ‘php_memc_getMulti_impl’:
/root/build/memcached-2.0.1/php_memcached.c:762: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char *’ but argument is of type ‘const char *
/root/build/memcached-2.0.1/php_memcached.c: In function ‘php_memc_getDelayed_impl’:
/root/build/memcached-2.0.1/php_memcached.c:936: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char *’ but argument is of type ‘const char *
/root/build/memcached-2.0.1/php_memcached.c: In function ‘zim_Memcached_getServerList’:
/root/build/memcached-2.0.1/php_memcached.c:1944: warning: assignment from incompatible pointer type
/root/build/memcached-2.0.1/php_memcached.c: In function ‘zim_Memcached_getStats’:
/root/build/memcached-2.0.1/php_memcached.c:2058: warning: assignment from incompatible pointer type
/root/build/memcached-2.0.1/php_memcached.c: In function ‘zim_Memcached_getVersion’:
/root/build/memcached-2.0.1/php_memcached.c:2091: warning: assignment from incompatible pointer type
/root/build/memcached-2.0.1/php_memcached.c: In function ‘zim_Memcached_getAllKeys’:
/root/build/memcached-2.0.1/php_memcached.c:2115: warning: assignment from incompatible pointer type
/root/build/memcached-2.0.1/php_memcached.c: In function ‘php_memc_do_serverlist_callback’:
/root/build/memcached-2.0.1/php_memcached.c:2585: warning: passing argument 4 of ‘add_assoc_string_ex’ discards qualifiers from pointer target type
/opt/php-5.4.0/include/php/Zend/zend_API.h:374: note: expected ‘char ’ but argument is of type ‘const char *’
/root/build/memcached-2.0.1/php_memcached.c: In function ‘php_memc_register_constants’:
/root/build/memcached-2.0.1/php_memcached.c:3680: error: ‘MEMCACHED_BEHAVIOR_TCP_KEEPALIVE’ undeclared (first use in this function)
/root/build/memcached-2.0.1/php_memcached.c:3680: error: (Each undeclared identifier is reported only once
/root/build/memcached-2.0.1/php_memcached.c:3680: error: for each function it appears in.)
make: *
* [php_memcached.lo] Error 1

I'm using libmemcached and libmemcached-devel versions 0.31-1.
Note: configure was executed with the "--enable-igbinary" option (igbinary installed from pecl).

@crisbarros
Copy link
Author

Now installed latest libmemcached (1.0.5) and it compiled properly. Probably libMemcached > 1.0 is required.

@symbiat
Copy link

symbiat commented May 2, 2012

Im having the same issue - are you running on CentOS? If so, did you install libmemcached 1.x from source or is there an RPM somewhere?

@wenslayer
Copy link

I'm experiencing the same issue with Ubuntu 10.04 LTS.

@aligentjim
Copy link

I have installed memcache from RPMs on a CentOS 6.2 server. The following memcache and libmemcached are installed:

memcached-1.4.4-3.el6.x86_64
libmemcached-devel-0.31-1.1.el6.x86_64
libmemcached-0.31-1.1.el6.x86_64

We have PHP 5.3.10 installed (of unknown origin, but likely nor RPM packages).

"pecl install memcaced" downloads "memcached-2.0.1.tgz", and begins compilation, but ultimately fails with the following errors:

/root/tmp/pear/memcached/php_memcached.c:3680: error: ‘MEMCACHED_BEHAVIOR_TCP_KEEPALIVE’ undeclared (first use in this function)
/root/tmp/pear/memcached/php_memcached.c:3680: error: (Each undeclared identifier is reported only once
/root/tmp/pear/memcached/php_memcached.c:3680: error: for each function it appears in.)

Full make output is as follows:

root@build [/etc/httpd/conf]# pecl install memcached
downloading memcached-2.0.1.tgz ...
Starting to download memcached-2.0.1.tgz (39,088 bytes)
..........done: 39,088 bytes
11 source files, building
running: phpize
Configuring for:
PHP Api Version:         20090626
Zend Module Api No:      20090626
Zend Extension Api No:   220090626
building in /root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1
running: /root/tmp/pear/memcached/configure
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking for cc... cc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether cc accepts -g... yes
checking for cc option to accept ISO C89... none needed
checking how to run the C preprocessor... cc -E
checking for icc... no
checking for suncc... no
checking whether cc understands -c and -o together... yes
checking for system library directory... lib
checking if compiler supports -R... no
checking if compiler supports -Wl,-rpath,... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for PHP prefix... /usr/local
checking for PHP includes... -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib
checking for PHP extension directory... /usr/local/lib/php/extensions/no-debug-non-zts-20090626
checking for PHP installed headers prefix... /usr/local/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... re2c
checking for re2c version... invalid
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... gawk
checking whether to enable memcached support... yes, shared
checking for libmemcached... yes, shared
checking whether to enable memcached session handler support... yes
checking whether to enable memcached igbinary serializer support... no
checking whether to enable memcached json serializer support... no
checking whether to disable memcached sasl support... no
checking for ZLIB... yes, shared
checking for zlib location... /usr
checking for session includes... /usr/local/include/php
checking for memcached session support... enabled
checking for memcached igbinary support... disabled
checking for libmemcached location... /usr
checking for ld used by cc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for /usr/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/nm -B
checking whether ln -s works... yes
checking how to recognize dependent libraries... pass_all
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking the maximum length of command line arguments... 98304
checking command to parse /usr/bin/nm -B output from cc object... ok
checking for objdir... .libs
checking for ar... ar
checking for ranlib... ranlib
checking for strip... strip
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC
checking if cc PIC flag -fPIC works... yes
checking if cc static flag -static works... yes
checking if cc supports -c -o file.o... yes
checking whether the cc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no

creating libtool
appending configuration tag "CXX" to libtool
configure: creating ./config.status
config.status: creating config.h
running: make
/bin/sh /root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1/libtool --mode=compile cc -I/usr/local/include/php  -I. -I/root/tmp/pear/memcached -DPHP_ATOM_INC -I/root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1/include -I/root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1/main -I/root/tmp/pear/memcached -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /root/tmp/pear/memcached/php_memcached.c -o php_memcached.lo
mkdir .libs
 cc -I/usr/local/include/php -I. -I/root/tmp/pear/memcached -DPHP_ATOM_INC -I/root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1/include -I/root/tmp/pear/pear-build-rootYvzXWz/memcached-2.0.1/main -I/root/tmp/pear/memcached -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /root/tmp/pear/memcached/php_memcached.c  -fPIC -DPIC -o .libs/php_memcached.o
/root/tmp/pear/memcached/php_memcached.c: In function ‘zim_Memcached___construct’:
/root/tmp/pear/memcached/php_memcached.c:415: warning: assignment makes pointer from integer without a cast
/root/tmp/pear/memcached/php_memcached.c: In function ‘php_memc_get_impl’:
/root/tmp/pear/memcached/php_memcached.c:554: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char **’ but argument is of type ‘const char **’
/root/tmp/pear/memcached/php_memcached.c:615: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char **’ but argument is of type ‘const char **’
/root/tmp/pear/memcached/php_memcached.c: In function ‘php_memc_getMulti_impl’:
/root/tmp/pear/memcached/php_memcached.c:762: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char **’ but argument is of type ‘const char **’
/root/tmp/pear/memcached/php_memcached.c: In function ‘php_memc_getDelayed_impl’:
/root/tmp/pear/memcached/php_memcached.c:936: warning: passing argument 4 of ‘memcached_mget_by_key’ from incompatible pointer type
/usr/include/libmemcached/memcached_get.h:38: note: expected ‘char **’ but argument is of type ‘const char **’
/root/tmp/pear/memcached/php_memcached.c: In function ‘zim_Memcached_getServerList’:
/root/tmp/pear/memcached/php_memcached.c:1944: warning: assignment from incompatible pointer type
/root/tmp/pear/memcached/php_memcached.c: In function ‘zim_Memcached_getStats’:
/root/tmp/pear/memcached/php_memcached.c:2058: warning: assignment from incompatible pointer type
/root/tmp/pear/memcached/php_memcached.c: In function ‘zim_Memcached_getVersion’:
/root/tmp/pear/memcached/php_memcached.c:2091: warning: assignment from incompatible pointer type
/root/tmp/pear/memcached/php_memcached.c: In function ‘zim_Memcached_getAllKeys’:
/root/tmp/pear/memcached/php_memcached.c:2115: warning: assignment from incompatible pointer type
/root/tmp/pear/memcached/php_memcached.c: In function ‘php_memc_do_serverlist_callback’:
/root/tmp/pear/memcached/php_memcached.c:2585: warning: passing argument 4 of ‘add_assoc_string_ex’ discards qualifiers from pointer target type
/usr/local/include/php/Zend/zend_API.h:362: note: expected ‘char *’ but argument is of type ‘const char *’
/root/tmp/pear/memcached/php_memcached.c: In function ‘php_memc_register_constants’:
/root/tmp/pear/memcached/php_memcached.c:3680: error: ‘MEMCACHED_BEHAVIOR_TCP_KEEPALIVE’ undeclared (first use in this function)
/root/tmp/pear/memcached/php_memcached.c:3680: error: (Each undeclared identifier is reported only once
/root/tmp/pear/memcached/php_memcached.c:3680: error: for each function it appears in.)
make: *** [php_memcached.lo] Error 1
ERROR: `make' failed
root@build [/etc/httpd/conf]# 

@TrafeX
Copy link

TrafeX commented Sep 26, 2012

Same here on Ubuntu Server 10.04.4 LTS.
Even after compiling the libmemcached (1.0.11) I get the same error as above when trying to install memcached-2.0.1.

But since I've compiled the latest libmemcached it's now possible to install memcached-2.1.0

@lwx2615
Copy link

lwx2615 commented Oct 17, 2012

I have the problem too! I have libmemcached-1.0.12.tar.gz and memcached-2.1.0
when i make , it happens:
/bin/sh /root/memcached-2.1.0/libtool --mode=compile cc -I/usr/local/php/include/php -I. -I/root/memcached-2.1.0 -DPHP_ATOM_INC -I/root/memcached-2.1.0/include -I/root/memcached-2.1.0/main -I/root/memcached-2.1.0 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -I/usr/local/libmemcached/include -DHAVE_CONFIG_H -g -O2 -c /root/memcached-2.1.0/php_memcached.c -o php_memcached.lo
cc -I/usr/local/php/include/php -I. -I/root/memcached-2.1.0 -DPHP_ATOM_INC -I/root/memcached-2.1.0/include -I/root/memcached-2.1.0/main -I/root/memcached-2.1.0 -I/usr/local/php/include/php -I/usr/local/php/include/php/main -I/usr/local/php/include/php/TSRM -I/usr/local/php/include/php/Zend -I/usr/local/php/include/php/ext -I/usr/local/php/include/php/ext/date/lib -I/usr/local/libmemcached/include -DHAVE_CONFIG_H -g -O2 -c /root/memcached-2.1.0/php_memcached.c -fPIC -DPIC -o .libs/php_memcached.o
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_get_impl’:
/root/memcached-2.1.0/php_memcached.c:599: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_getMulti_impl’:
/root/memcached-2.1.0/php_memcached.c:797: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:800: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zim_Memcached_fetch’:
/root/memcached-2.1.0/php_memcached.c:1014: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:1017: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zim_Memcached_fetchAll’:
/root/memcached-2.1.0/php_memcached.c:1068: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:1071: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:1121:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c: In function ‘zim_Memcached_getServerByKey’:
/root/memcached-2.1.0/php_memcached.c:1977: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:2178:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:2235:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:2246:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:2275:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_set_option’:
/root/memcached-2.1.0/php_memcached.c:2280: error: ‘memcached_st’ has no member named ‘hash’
/root/memcached-2.1.0/php_memcached.c:2321:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_do_serverlist_callback’:
/root/memcached-2.1.0/php_memcached.c:2583: warning: passing argument 4 of ‘add_assoc_string_ex’ discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:2677:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_handle_error’:
/root/memcached-2.1.0/php_memcached.c:2680: error: ‘memcached_st’ has no member named ‘cached_errno’
/root/memcached-2.1.0/php_memcached.c:2688:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:2691: error: ‘memcached_st’ has no member named ‘cached_errno’
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_do_result_callback’:
/root/memcached-2.1.0/php_memcached.c:3191: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:3194: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:3522:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:3680:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:3705:42: error: token "@" is not valid in preprocessor expressions
/root/memcached-2.1.0/php_memcached.c:3709:42: error: token "@" is not valid in preprocessor expressions
make: *** [php_memcached.lo] Error 1

any one who has some ideas?

@ecaron
Copy link

ecaron commented Oct 17, 2012

+1 for @lwx2615's issue.

Downgrading from libmemcached 1.0.12 to 1.0.10 fixed this for me. Problem seems to be, at least on my install, that 1.0.12 libmemcached's configure.h leaves

#define LIBMEMCACHED_VERSION_HEX @PANDORA_HEX_VERSION@

But on 1.0.10, it is

#define LIBMEMCACHED_VERSION_HEX 0x01000010

I'm outside my comfort zone now in debugging further - just suffice to say that going down from 1.0.12 to 1.0.10 fixed the issue for me. (Don't forgot to do a "make distclean" to get rid of 1.0.12)

@lwx2615
Copy link

lwx2615 commented Oct 18, 2012

It's that do with the php version? My php version
PHP 5.3.14 (cli) (built: Jul 9 2012 14:42:44)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
and the libevent version is libevent-1.4
I followed the advise, then used memcached-2.1.0 and libmemcached-1.0.10 for the memcached client ! It prints like bellow:
make test
/bin/sh /root/memcached-2.1.0/libtool --mode=compile gcc44 -I/usr/include/php -I. -I/root/memcached-2.1.0 -DPHP_ATOM_INC -I/root/memcached-2.1.0/include -I/root/memcached-2.1.0/main -I/root/memcached-2.1.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/local/libmemcached/include -DHAVE_CONFIG_H -g -O2 -c /root/memcached-2.1.0/php_memcached.c -o php_memcached.lo
gcc44 -I/usr/include/php -I. -I/root/memcached-2.1.0 -DPHP_ATOM_INC -I/root/memcached-2.1.0/include -I/root/memcached-2.1.0/main -I/root/memcached-2.1.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/local/libmemcached/include -DHAVE_CONFIG_H -g -O2 -c /root/memcached-2.1.0/php_memcached.c -fPIC -DPIC -o .libs/php_memcached.o
/root/memcached-2.1.0/php_memcached.c:289: error: ‘OnUpdateLongGEZero’ undeclared here (not in a function)
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_get_impl’:
/root/memcached-2.1.0/php_memcached.c:599: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_getMulti_impl’:
/root/memcached-2.1.0/php_memcached.c:743: warning: passing argument 2 of ‘add_assoc_null_ex’ discards qualifiers from pointer target type
/usr/include/php/Zend/zend_API.h:285: note: expected ‘char ’ but argument is of type ‘const char *’
/root/memcached-2.1.0/php_memcached.c:797: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:800: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zif_Memcached_fetch’:
/root/memcached-2.1.0/php_memcached.c:1014: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:1017: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zif_Memcached_fetchAll’:
/root/memcached-2.1.0/php_memcached.c:1068: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:1071: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zif_Memcached_getServerByKey’:
/root/memcached-2.1.0/php_memcached.c:1977: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘zif_Memcached_getResultMessage’:
/root/memcached-2.1.0/php_memcached.c:2465: warning: initialization discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_do_serverlist_callback’:
/root/memcached-2.1.0/php_memcached.c:2583: warning: passing argument 4 of ‘add_assoc_string_ex’ discards qualifiers from pointer target type
/usr/include/php/Zend/zend_API.h:289: note: expected ‘char *’ but argument is of type ‘const char *’
/root/memcached-2.1.0/php_memcached.c: In function ‘php_memc_do_result_callback’:
/root/memcached-2.1.0/php_memcached.c:3191: warning: assignment discards qualifiers from pointer target type
/root/memcached-2.1.0/php_memcached.c:3194: warning: assignment discards qualifiers from pointer target type
make: *
* [php_memcached.lo] Error 1

at last , I want to say : thank you man ! I try it on another server, and it get success !
this time I used : php-5.3.17.tar.gz libevent-2.0.20-stable.tar.gz libmemcached-1.0.10.tar.gz memcached-2.1.0.tgz
hope it will help some one who failed like me!
But it's still unknow whether the php version or the libevent version not compatible.

@nullday
Copy link

nullday commented Jun 3, 2013

CentOS 6
has the same problem, my fix is next: deinstalled libmemcached 1.0.16 from yum and installed 1.0.10 from sources.

@julienpa
Copy link

Had the same issue with the command "pecl install memcached", downgraded to libmemcached 1.0.10 and now it works fine (tried to install memcached 1.4.15 but finally went back to CentOS repository's default 1.4.4).
Thanks for the tip 👍

@mkoppanen
Copy link
Member

This has been fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants