php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #58798 Doesn't compile with PHP 5.3.0
Submitted: 2009-08-11 03:00 UTC Modified: 2015-02-26 07:36 UTC
Votes:11
Avg. Score:4.2 ± 0.8
Reproduced:10 of 10 (100.0%)
Same Version:3 (30.0%)
Same OS:3 (30.0%)
From: omega13a at yahoo dot com Assigned:
Status: Suspended Package: apd (PECL)
PHP Version: 5.3.0RC4 OS: CentOS 5
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: omega13a at yahoo dot com
New email:
PHP Version: OS:

 

 [2009-08-11 03:00 UTC] omega13a at yahoo dot com
Description:
------------
When I went to go rebuild this extension for PHP 5.3.0, it failed to build.


Expected result:
----------------
The package to install with out errors.

Actual result:
--------------
[root@peeves ~]# pecl install apd
downloading apd-1.0.1.tgz ...
Starting to download apd-1.0.1.tgz (36,643 bytes)
..........done: 36,643 bytes
15 source files, building
running: phpize
Configuring for:
PHP Api Version:         20090626
Zend Module Api No:      20090626
Zend Extension Api No:   220090626
building in /var/tmp/pear-build-omega13a/apd-1.0.1
running: /tmp/pear/download/apd-1.0.1/configure
checking for egrep... 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 ANSI C... 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... i686-redhat-linux-gnu
checking host system type... i686-redhat-linux-gnu
checking target system type... i686-redhat-linux-gnu
checking for PHP prefix... /usr
checking for PHP includes... -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/include/php/ext/date/lib
checking for PHP extension directory... /usr/lib/php/modules
checking for PHP installed headers prefix... /usr/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 whether to enable apd support... yes, shared
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 recognise dependent libraries... pass_all
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 dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for g77... no
checking for f77... no
checking for xlf... no
checking for frt... no
checking for pgf77... no
checking for fort77... no
checking for fl32... no
checking for af77... no
checking for f90... no
checking for xlf90... no
checking for pgf90... no
checking for epcf90... no
checking for f95... f95
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether f95 accepts -g... yes
checking the maximum length of command line arguments... 32768
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) 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 libtool
appending configuration tag "CXX" to libtool
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for f95 option to produce PIC... -fPIC
checking if f95 PIC flag -fPIC works... yes
checking if f95 static flag -static works... yes
checking if f95 supports -c -o file.o... yes
checking whether the f95 linker (/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
configure: creating ./config.status
config.status: creating config.h
running: make
/bin/sh /var/tmp/pear-build-omega13a/apd-1.0.1/libtool --mode=compile cc  -I. -I/tmp/pear/download/apd-1.0.1 -DPHP_ATOM_INC -I/var/tmp/pear-build-omega13a/apd-1.0.1/include -I/var/tmp/pear-build-omega13a/apd-1.0.1/main -I/tmp/pear/download/apd-1.0.1 -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/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c /tmp/pear/download/apd-1.0.1/php_apd.c -o php_apd.lo
mkdir .libs
 cc -I. -I/tmp/pear/download/apd-1.0.1 -DPHP_ATOM_INC -I/var/tmp/pear-build-omega13a/apd-1.0.1/include -I/var/tmp/pear-build-omega13a/apd-1.0.1/main -I/tmp/pear/download/apd-1.0.1 -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/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/download/apd-1.0.1/php_apd.c  -fPIC -DPIC -o .libs/php_apd.o
/tmp/pear/download/apd-1.0.1/php_apd.c: In function 'zif_override_function':
/tmp/pear/download/apd-1.0.1/php_apd.c:615: warning: 'zend_get_parameters_ex' is deprecated (declared at /usr/include/php/Zend/zend_API.h:222)
/tmp/pear/download/apd-1.0.1/php_apd.c: In function 'zif_rename_function':
/tmp/pear/download/apd-1.0.1/php_apd.c:669: warning: 'zend_get_parameters_ex' is deprecated (declared at /usr/include/php/Zend/zend_API.h:222)
/tmp/pear/download/apd-1.0.1/php_apd.c: In function 'zif_apd_set_pprof_trace':
/tmp/pear/download/apd-1.0.1/php_apd.c:792: warning: 'zend_get_parameters_ex' is deprecated (declared at /usr/include/php/Zend/zend_API.h:222)
/tmp/pear/download/apd-1.0.1/php_apd.c: In function 'apd_zend_startup':
/tmp/pear/download/apd-1.0.1/php_apd.c:967: error: 'struct _zend_compiler_globals' has no member named 'extended_info'
make: *** [php_apd.lo] Error 1
ERROR: `make' failed


Patches

php.apd.c (last revision 2011-10-16 02:16 UTC by admin at flicker dot pk)

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-12-16 07:36 UTC] polycaster at polycast dot de
The same is true for Mac OS X 10.6.2.
 [2010-01-22 19:59 UTC] jlist at silentcow dot com
Did you take a look at the code that generates this error?  
The comment doesn't fill me with confidence :)

  CG(extended_info) = 1;  /* XXX: this is ridiculous */
 [2010-01-22 20:08 UTC] jlist at silentcow dot com
Btw, I just got this to install by just hacking on my own 
zend_globals.h to add in the extended_info member to the _zend_compiler_globals struct.

I'm on OSX and am using MacPorts, so for me it was in:
  /opt/local/include/php/Zend/zend_globals.h

But slocate is your friend :)
 [2010-05-11 11:54 UTC] linusnorton at gmail dot com
What type did you give the variable?
 [2010-09-01 21:13 UTC] the dot ramonester at gmail dot com
I just add add int type for extended_info and works =]
 [2010-09-22 08:58 UTC] paolopantaleo at gmail dot com
I added the int extended_info member. I was able to compile, but when running I got segmentation fault.
 [2011-01-15 02:48 UTC] omega13a at yahoo dot com
I made a patch that allowed me to compile it. The patch also correct the extension's version number that shows up in phpinfo().


diff -Naurp php-pecl-apd-1.0.1/apd-1.0.1/php_apd.c php-pecl-apd-1.0.1.patched/apd-1.0.1/php_apd.c
--- php-pecl-apd-1.0.1/apd-1.0.1/php_apd.c	2004-09-27 20:25:59.000000000 -0700
+++ php-pecl-apd-1.0.1.patched/apd-1.0.1/php_apd.c	2011-01-14 23:31:08.921523776 -0800
@@ -964,7 +964,7 @@ ZEND_DLEXPORT void onStatement(zend_op_a
 int apd_zend_startup(zend_extension *extension)
 {
 	TSRMLS_FETCH();
-	CG(extended_info) = 1;  /* XXX: this is ridiculous */
+	CG(compiler_options) |= ZEND_COMPILE_EXTENDED_INFO;
 	return zend_startup_module(&apd_module_entry);
 }
 
diff -Naurp php-pecl-apd-1.0.1/apd-1.0.1/php_apd.h php-pecl-apd-1.0.1.patched/apd-1.0.1/php_apd.h
--- php-pecl-apd-1.0.1/apd-1.0.1/php_apd.h	2004-09-27 20:25:42.000000000 -0700
+++ php-pecl-apd-1.0.1.patched/apd-1.0.1/php_apd.h	2011-01-14 23:32:14.791524297 -0800
@@ -89,7 +89,7 @@ void printUnsortedSummary(struct timeval
 extern zend_module_entry apd_module_entry;
 #define apd_module_ptr &apd_module_entry
 
-#define APD_VERSION "0.9"
+#define APD_VERSION "1.0.1"
 
 #define FUNCTION_TRACE 1
 #define ARGS_TRACE 2
 [2011-03-08 11:28 UTC] david dot neimeyer at cpanel dot net
patch submitted by omega13a worked for me.  Many Thanks 
omega13a!

===================
Mac 10.6.6
------------------
PHP 5.3.3 (cli) (built: Aug 22 2010 19:41:55) 
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend 
Technologies
    with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick 
Rethans
    with Advanced PHP Debugger (APD) v1.0.1, , by George 
Schlossnagle
 [2011-05-02 07:10 UTC] hfahimi at gmail dot com
thanx omega13a at yahoo dot com, your patch worked for me
 [2011-12-14 18:01 UTC] php at jamestandy dot com
thanks omega13a, your patch works.
suggest for inclusion in the next release.
 [2012-03-12 08:35 UTC] boborabit at gmail dot com
Thanks omega13a, you patch saved me a headache!
 [2013-01-31 23:48 UTC] paulschreiber at gmail dot com
Is someone going to accept this patch? The bug is 3.5 years old.
 [2013-07-09 10:20 UTC] ciho_mimo at yahoo dot com
I had this problem and omega13's patch worked.

It's useful to include some comments on how to run the patch and enable the extension for PHP, as not everyone visiting these pages are experts (myself!). So here's the steps I followed that worked for me:

save omega13's patch into a patch file (e.g. file.patch)

'cd' into downloaded module directory 

patch < file.patch
./configure
make
make install

the above will put apd.so into modules/ directory. copy that into PHP extensions directory (mine at /usr/lib/php5/20090626/ and then restart your web server.
 [2013-10-30 10:21 UTC] navin_ragul at yahoo dot com
im using IIS 7 server and trying install apd and its not working.

the message is the one im receiving from  **pecl install apd** command 

No releases available for package "pecl.php.net/apd"

do i missing something ??
 [2015-02-26 07:36 UTC] krakjoe@php.net
-Status: Open +Status: Suspended
 [2015-02-26 07:36 UTC] krakjoe@php.net
APD hasn't had a release in 10 years, this means it's source code is way out of sync with modern PHP.

I'm going to mark this bug as suspended, the report can still be found if a maintainer for APD comes forward.

Sorry about the wait.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Dec 05 11:01:29 2024 UTC