php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71329 Varnish extension does not compile with Varnish 4.1 lib
Submitted: 2016-01-10 16:35 UTC Modified: 2021-06-13 04:22 UTC
Votes:3
Avg. Score:5.0 ± 0.0
Reproduced:3 of 3 (100.0%)
Same Version:1 (33.3%)
Same OS:2 (66.7%)
From: wim at powerassist dot nl Assigned: cmb (profile)
Status: No Feedback Package: varnish (PECL)
PHP Version: 5.6.17 OS: Ubuntu 14.04-3 LTS
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: wim at powerassist dot nl
New email:
PHP Version: OS:

 

 [2016-01-10 16:35 UTC] wim at powerassist dot nl
Description:
------------
Trying to compile the Varnish 1.2.1 PHP extension with Varnish 4.1 dev lib (libvarnishapi-dev) on ubuntu. It fails to configure and exits.

Test script:
---------------
phpize
./configure


Actual result:
--------------
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... /php/php-5.6
checking for PHP includes... -I/php/php-5.6/include/php -I/php/php-5.6/include/php/main -I/php/php-5.6/include/php/TSRM -I/php/php-5.6/include/php/Zend -I/php/php-5.6/include/php/ext -I/php/php-5.6/include/php/ext/date/lib
checking for PHP extension directory... /php/php-5.6/lib/php/extensions/no-debug-non-zts-20131226
checking for PHP installed headers prefix... /php/php-5.6/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... gawk
checking for varnish support... yes, shared
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 fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking for sys/types.h... (cached) yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking for varnish files in default path... not found
configure: error: Please reinstall the varnish distribution
make: *** No targets specified and no makefile found.  Stop.
root@web01:/usr/local/src/ext/varnish-1.1.1# apt-get install libvarnishapi-dev
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libvarnishapi-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@web01:/usr/local/src/ext/varnish-1.1.1# cd ../varnish-1.2.1
root@web01:/usr/local/src/ext/varnish-1.2.1# /php/config/php-5.6/build-ext 
Configuring for:
PHP Api Version:         20131106
Zend Module Api No:      20131226
Zend Extension Api No:   220131226
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... /php/php-5.6
checking for PHP includes... -I/php/php-5.6/include/php -I/php/php-5.6/include/php/main -I/php/php-5.6/include/php/TSRM -I/php/php-5.6/include/php/Zend -I/php/php-5.6/include/php/ext -I/php/php-5.6/include/php/ext/date/lib
checking for PHP extension directory... /php/php-5.6/lib/php/extensions/no-debug-non-zts-20131226
checking for PHP installed headers prefix... /php/php-5.6/include/php
checking if debug is enabled... no
checking if zts is enabled... no
checking for re2c... no
configure: WARNING: You will need re2c 0.13.4 or later if you want to regenerate PHP parsers.
checking for gawk... gawk
checking for varnish support... yes, shared
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 fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking for sys/types.h... (cached) yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking netdb.h usability... yes
checking netdb.h presence... yes
checking for netdb.h... yes
checking for pkg-config... /usr/bin/pkg-config
checking varnish version... 4.1.0
checking for uintptr_t... yes
checking for uint64_t... yes
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... 1572864
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
config.status: config.h is unchanged
/bin/bash /usr/local/src/ext/varnish-1.2.1/libtool --mode=compile cc  -I. -I/usr/local/src/ext/varnish-1.2.1 -DPHP_ATOM_INC -I/usr/local/src/ext/varnish-1.2.1/include -I/usr/local/src/ext/varnish-1.2.1/main -I/usr/local/src/ext/varnish-1.2.1 -I/php/php-5.6/include/php -I/php/php-5.6/include/php/main -I/php/php-5.6/include/php/TSRM -I/php/php-5.6/include/php/Zend -I/php/php-5.6/include/php/ext -I/php/php-5.6/include/php/ext/date/lib -I/usr/include/varnish  -DHAVE_CONFIG_H  -g -O2   -c /usr/local/src/ext/varnish-1.2.1/varnish_lib.c -o varnish_lib.lo 
 cc -I. -I/usr/local/src/ext/varnish-1.2.1 -DPHP_ATOM_INC -I/usr/local/src/ext/varnish-1.2.1/include -I/usr/local/src/ext/varnish-1.2.1/main -I/usr/local/src/ext/varnish-1.2.1 -I/php/php-5.6/include/php -I/php/php-5.6/include/php/main -I/php/php-5.6/include/php/TSRM -I/php/php-5.6/include/php/Zend -I/php/php-5.6/include/php/ext -I/php/php-5.6/include/php/ext/date/lib -I/usr/include/varnish -DHAVE_CONFIG_H -g -O2 -c /usr/local/src/ext/varnish-1.2.1/varnish_lib.c  -fPIC -DPIC -o .libs/varnish_lib.o
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c: In function 'php_varnish_sock_ident':
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:352:20: error: storage size of 'vt' isn't known
  struct VSM_fantom vt;
                    ^
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:355:6: warning: assignment makes pointer from integer without a cast [enabled by default]
  vsd = VSM_New();
      ^
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:371:4: warning: passing argument 3 of 'zend_throw_exception_ex' makes pointer from integer without a cast [enabled by default]
    );
    ^
In file included from /usr/local/src/ext/varnish-1.2.1/varnish_lib.c:38:0:
/php/php-5.6/include/php/Zend/zend_exceptions.h:44:17: note: expected 'const char *' but argument is of type 'int'
 ZEND_API zval * zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, const char *format, ...);
                 ^
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:389:4: warning: passing argument 3 of 'zend_throw_exception_ex' makes pointer from integer without a cast [enabled by default]
    );
    ^
In file included from /usr/local/src/ext/varnish-1.2.1/varnish_lib.c:38:0:
/php/php-5.6/include/php/Zend/zend_exceptions.h:44:17: note: expected 'const char *' but argument is of type 'int'
 ZEND_API zval * zend_throw_exception_ex(zend_class_entry *exception_ce, long code TSRMLS_DC, const char *format, ...);
                 ^
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c: In function 'php_varnish_auth_ident':
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:532:20: error: storage size of 'vt' isn't known
  struct VSM_fantom vt;
                    ^
/usr/local/src/ext/varnish-1.2.1/varnish_lib.c:539:7: warning: assignment makes pointer from integer without a cast [enabled by default]
   vsd = VSM_New();
       ^
make: *** [varnish_lib.lo] Error 1


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-01-17 13:38 UTC] jonas dot s at webhelps dot de
My error is slightly different, same setup / scenario:

----------------------------------------------------
checking for VSM_New in -lvarnishapi... no
configure: error: wrong varnishapi lib version or lib not found
ERROR: `/tmp/pear/temp/varnish/configure --with-php-config=/usr/bin/php-config' failed
----------------------------------------------------
 [2021-06-02 16:21 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-06-02 16:21 UTC] cmb@php.net
Is this still an issue with any of the actively supported PHP
versions[1] and latest varnish (1.2.6)?

[1] <https://www.php.net/supported-versions.php>
 [2021-06-13 04:22 UTC] pecl-dev at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 06 17:01:27 2024 UTC