nicolasff/phpredis — Issue #128: phpredis does not compile
Author: sztanpet
Created: 2012-01-30 16:27:30+00:00
State: open

I'm trying to compile a newer version as phpredis under php-fpm 5.3.9 (gentoo) segfaults *every*time

on commit ac11fab30066, gcc-4.4.5, libtool 2.4-r3
the usual issue with libtool still stands, dont know if you can do something about it, but I would guess so as other packages compile fine.

after phpize; ./configure; make:

[17:13](/home/sztanpet/phpredis)(master)# make
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis.c -o redis.lo
/home/sztanpet/phpredis/libtool: line 481: CDPATH: command not found
libtool: Version mismatch error. This is libtool 2.4, but the
libtool: definition of this LT_INIT comes from an older release.
libtool: You should recreate aclocal.m4 with macros from libtool 2.4
libtool: and run autoconf again.
make: *** [redis.lo] Error 63

so that didn't work, so I've gone for the manual method of

phpize
aclocal
libtoolize --force
autoheader
autoconf
./configure
make

and that produced this output:

[17:23](/home/sztanpet/phpredis)(master)# phpize
Configuring for:
PHP Api Version: 20090626
Zend Module Api No: 20090626
Zend Extension Api No: 220090626
configure.in:3: warning: prefer named diversions
configure.in:3: warning: prefer named diversions
[17:23](/home/sztanpet/phpredis)(master)# aclocal
configure.in:3: warning: prefer named diversions
[17:23](/home/sztanpet/phpredis)(master)# libtoolize --force
libtoolize: putting auxiliary files in `.'.
libtoolize: linking file `./ltmain.sh'
libtoolize: Consider adding `AC_CONFIG_MACRO_DIR([m4])' to configure.in and
libtoolize: rerunning libtoolize, to keep the correct libtool macros in-tree.
libtoolize: Consider adding `-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
[17:23](/home/sztanpet/phpredis)(master)# autoheader
configure.in:3: warning: prefer named diversions
[17:23](/home/sztanpet/phpredis)(master)# autoconf
configure.in:3: warning: prefer named diversions
[17:23](/home/sztanpet/phpredis)(master)# ./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 whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
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/lib64/php5.3
checking for PHP includes... -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib
checking for PHP extension directory... /usr/lib64/php5.3/lib/extensions/no-debug-zts-20090626
checking for PHP installed headers prefix... /usr/lib64/php5.3/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... re2c
checking for re2c version... 0.13.5 (ok)
checking for gawk... gawk
checking whether to enable redis support... yes, shared
checking whether to enable sessions... yes
checking how to print strings... printf
checking for a sed that does not truncate output... (cached) /bin/sed
checking for fgrep... /bin/grep -F
checking for ld used by cc... /usr/x86_64-pc-linux-gnu/bin/ld
checking if the linker (/usr/x86_64-pc-linux-gnu/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1966080
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to x86_64-unknown-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/x86_64-pc-linux-gnu/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking for gawk... (cached) gawk
checking command to parse /usr/bin/nm -B output from cc object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if cc supports -fno-rtti -fno-exceptions... no
checking for cc option to produce PIC... -fPIC -DPIC
checking if cc PIC flag -fPIC -DPIC works... yes
checking if cc static flag -static works... yes
checking if cc supports -c -o file.o... yes
checking if cc supports -c -o file.o... (cached) yes
checking whether the cc linker (/usr/x86_64-pc-linux-gnu/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
configure: creating ./config.status
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing libtool commands
[17:23](/home/sztanpet/phpredis)(master)# make
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis.c -o redis.lo
libtool: compile: cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis.c -fPIC -DPIC -o .libs/redis.o
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/library.c -o library.lo
libtool: compile: cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/library.c -fPIC -DPIC -o .libs/library.o
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_session.c -o redis_session.lo
libtool: compile: cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_session.c -fPIC -DPIC -o .libs/redis_session.o
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_array.c -o redis_array.lo
libtool: compile: cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_array.c -fPIC -DPIC -o .libs/redis_array.o
/bin/sh /home/sztanpet/phpredis/libtool --mode=compile cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_array_impl.c -o redis_array_impl.lo
libtool: compile: cc -I. -I/home/sztanpet/phpredis -DPHP_ATOM_INC -I/home/sztanpet/phpredis/include -I/home/sztanpet/phpredis/main -I/home/sztanpet/phpredis -I/usr/lib64/php5.3/include/php -I/usr/lib64/php5.3/include/php/main -I/usr/lib64/php5.3/include/php/TSRM -I/usr/lib64/php5.3/include/php/Zend -I/usr/lib64/php5.3/include/php/ext -I/usr/lib64/php5.3/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/sztanpet/phpredis/redis_array_impl.c -fPIC -DPIC -o .libs/redis_array_impl.o
/home/sztanpet/phpredis/redis_array_impl.c: In function ‘ra_move_zset’:
/home/sztanpet/phpredis/redis_array_impl.c:877: error: too few arguments to function ‘ra_expire_key’
/home/sztanpet/phpredis/redis_array_impl.c: In function ‘ra_move_hash’:
/home/sztanpet/phpredis/redis_array_impl.c:958: error: too few arguments to function ‘ra_expire_key’
/home/sztanpet/phpredis/redis_array_impl.c: In function ‘ra_move_collection’:
/home/sztanpet/phpredis/redis_array_impl.c:1026: error: too few arguments to function ‘ra_expire_key’
make: *** [redis_array_impl.lo] Error 1